Author: frankie
Date: 2007-05-18 12:29:17 +0000 (Fri, 18 May 2007)
New Revision: 837

[svn-inject] Applying Debian modifications to trunk

Added: packages/drawmap/trunk/debian/README.Debian
--- packages/drawmap/trunk/debian/README.Debian                         (rev 0)
+++ packages/drawmap/trunk/debian/README.Debian 2007-05-18 12:29:17 UTC (rev 
@@ -0,0 +1,10 @@
+drawmap for Debian
+Upstream has made major improvements in shading and has implemented
+color banded contours.  Upstream's method of doing this is better
+than drawmapcc, so drawmapcc is replaced by a script which calls
+drawmap.  drawmapcc will be removed in the next release.
+The man pages are very good.  Read them!
+ -- James W. Penny (Midway, Kentucky)  <[EMAIL PROTECTED]>

Added: packages/drawmap/trunk/debian/changelog
--- packages/drawmap/trunk/debian/changelog                             (rev 0)
+++ packages/drawmap/trunk/debian/changelog     2007-05-18 12:29:17 UTC (rev 
@@ -0,0 +1,68 @@
+drawmap (2.5-2) unstable; urgency=low
+  * QA Upload
+  * Set Maintainer to QA Group
+  * Integrate NMU Patches with dpatch (Closes: #327475)
+    + Build-Depend on Dpatch
+  * clean up debian/rules
+  * Upgrade Standards Version
+ -- Michael Ablassmeier <[EMAIL PROTECTED]>  Fri, 28 Apr 2006 09:40:19 +0200
+drawmap (2.5-1.1) unstable; urgency=low
+  * BSP NMU
+  * Fix FTBFS with gcc-4.0 due to source conflict with library functions
+    (drawmap.h) and labels at end of case statement (dlg.c).
+    (Closes: #258622). Thanks to Andreas Jochens for the patch.
+  * Upgrade from debhelper 2 to 4.
+ -- Hamish Moffatt <[EMAIL PROTECTED]>  Sat, 10 Sep 2005 21:51:47 +1000
+drawmap (2.5-1) unstable; urgency=low
+  * New upstream release                               closes: Bug#219081
+  * See /usr/share/doc/drawmap/WHATS_NEW for list of upstream modifications
+ -- James W. Penny <[EMAIL PROTECTED]>  Thu,  6 Nov 2003 22:43:00 -0500
+drawmap (2.3-1) unstable; urgency=low
+  * New upstream release
+  * See /usr/share/doc/drawmap/WHATS_NEW for list of upstream modifications
+  * drawmapcc is deprecated, upstream's solution is better
+ -- James W. Penny <[EMAIL PROTECTED]>  Mon, 12 Feb 2001 22:43:32 -0500
+drawmap (2.2-1) unstable; urgency=low
+  * New maintainer, new upstream version
+  * Added drawmapcc
+  * new documentation (/usr/share/doc/index.html)
+ -- James Penny (Midway, Kentucky) (No Comment) <[EMAIL PROTECTED]>  Tue,  2 
Jan 2001 23:58:17 -0500
+drawmap (1.7-1) unstable; urgency=low
+  * New upstream version
+ -- John Lapeyre <[EMAIL PROTECTED]>  Tue, 30 Mar 1999 16:06:39 -0700
+drawmap (1.3-2) unstable; urgency=low
+  * Remove hard coded egcc use.
+ -- John Lapeyre <[EMAIL PROTECTED]>  Tue, 22 Sep 1998 21:33:19 -0700
+drawmap (1.3-1) unstable; urgency=low
+  * Initial Release.
+ -- John Lapeyre <[EMAIL PROTECTED]>  Tue, 18 Aug 1998 04:01:47 -0700
+Local variables:
+mode: debian-changelog
+add-log-mailing-address "[EMAIL PROTECTED]"

Added: packages/drawmap/trunk/debian/control
--- packages/drawmap/trunk/debian/control                               (rev 0)
+++ packages/drawmap/trunk/debian/control       2007-05-18 12:29:17 UTC (rev 
@@ -0,0 +1,24 @@
+Source: drawmap
+Section: math
+Priority: optional
+Maintainer: Debian QA Group <[EMAIL PROTECTED]>
+Build-Depends: debhelper (>> 4), groff, dpatch
+Standards-Version: 3.6.2
+Package: drawmap
+Architecture: any
+Depends: ${shlibs:Depends}
+Description:  draws customized maps, using raw USGS data files
+ Drawmap reads data in the Digital Elevation Model (DEM),
+ Digital Line Graph (DLG), and Geographic Names Information
+ System (GNIS) formats.  Can also work with SDTS, NAD-83,
+ WGS-84, GTOPO30 data.
+ .
+ Using the data in these files, drawmap can produce various
+ kinds  of  customized  maps,  including shaded relief maps
+ (with or without roads, streams, place names, and  so  on)
+ and  topographic  maps  (again, with or without additional
+ features).
+ .
+ Outputs sun raster format, portable gray map, or pov format 
+ files.

Added: packages/drawmap/trunk/debian/copyright
--- packages/drawmap/trunk/debian/copyright                             (rev 0)
+++ packages/drawmap/trunk/debian/copyright     2007-05-18 12:29:17 UTC (rev 
@@ -0,0 +1,19 @@
+This package was debianized by James W. Penny <[EMAIL PROTECTED]>
+Tue,  2 Jan 2001 23:58:17 -0500.
+It was downloaded from:
+Upstream Author: Fred M. Erickson <[EMAIL PROTECTED]>
+(c) Copyright 2001 Fred M. Erickson. All Rights Reserved
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+Full text of the license may be found, on a Debian system, in the file

Added: packages/drawmap/trunk/debian/dirs
--- packages/drawmap/trunk/debian/dirs                          (rev 0)
+++ packages/drawmap/trunk/debian/dirs  2007-05-18 12:29:17 UTC (rev 837)
@@ -0,0 +1,2 @@

Added: packages/drawmap/trunk/debian/doc-base
--- packages/drawmap/trunk/debian/doc-base                              (rev 0)
+++ packages/drawmap/trunk/debian/doc-base      2007-05-18 12:29:17 UTC (rev 
@@ -0,0 +1,12 @@
+Document: drawmap
+Title: Drawmap Usage Hints
+Author: James Penny
+Abstract: This document provides some of the sources
+ for drawmap compatible data files and some hints on
+ using Gimp to post process and thereby improve
+ drawmap generated maps.
+Section: Math
+Format: HTML
+Index: /usr/share/doc/drawmap/html/index.html
+Files: /usr/share/doc/drawmap/html/*.html

Added: packages/drawmap/trunk/debian/docs
--- packages/drawmap/trunk/debian/docs                          (rev 0)
+++ packages/drawmap/trunk/debian/docs  2007-05-18 12:29:17 UTC (rev 837)
@@ -0,0 +1 @@

Added: packages/drawmap/trunk/debian/index.html
--- packages/drawmap/trunk/debian/index.html                            (rev 0)
+++ packages/drawmap/trunk/debian/index.html    2007-05-18 12:29:17 UTC (rev 
@@ -0,0 +1,270 @@
+<title>Drawmap Usage
+<h2>See the man page</h2>
+<p>Be sure to read <strong>man drawmap</strong>.  It is very good!</p>
+<h2>Why this document has no images</h2>
+The binary .deb is about 200 kilobytes.  Example data files that were
+used in testing and post processing were about 300 kilobytes.  Images
+come in at about 60 kiloytes each, and to do a thorough job, I need about
+ten such images.  Inclusion of test data and intermediary images would
+require about 900 kilobytes.  It seems wasteful to bloat the package
+this much!
+<h2>Sources of data files</h2>
+There are several types of input files that drawmap processes.  The
+primary ones are Digital Elevation Maps (DEM), and Digital Line Maps (DLG).
+DEM files contain topographical information.  DLG files contain information
+about features such as roads, streams, lakes and ponds.  Drawmap can also
+process Geographical Name Information Service (GNIS) files.  These files
+contain location of place name information.  Drawmap can in fact read
+several other input file types, see the man page.
+<p>The primary source of suitable DEM and DLG datafiles for the U.S.A. is 
+<a href=>
+</a>. Both the 1:250,000 and 1:24,000 are suitable for drawmap.
+If you are using acquiring data for the first time, you should
+look at the links labelled FTP by Graphics.  These show the rectangle
+that each data file describes and gives you a very quick way of judging
+just how much you will need to get.
+<p>These data files tend to be moderately large.  The 1:24,000 DEM file 
+describing Midway, Kentucky is 160 kilobytes, compressed.  The hydrology DLG
+file is 143 kilobytes, compressed.  </p>
+The primary download site for U.S. GNIS data is:
+<a href=>
+There are two formats for GNIS data on the USGS site, one is
+in Quote and Comma Delimited form, and one is in Columnar form.
+I have given examples in the Quote and Columnar form, because
+I find it easier to use standard tools like egrep and text editors
+in this form.  Quote and Comma Delimited files have _deci as part
+of their name.
+GNIS files are ordinary text files.  Each line is self contained,
+and so, it is perfectly safe to use grep to select the region you
+are working with, and then hand edit the output with your favorite
+text editor.  For example, I have been using the Midway section of Kentucky.
+To find only the Midway data, I can simply <br>
+egrep \"Midway$\" KY_deci &gt; KY_deci_Midway
+<p>These data files have two uses for us.  First, they mark place-names
+on the map, features like cities, villages, mountain names, rivers, isolated
+churches, etc.  They also allow us to mark features on our own.  For example,
+the low point of the Midway data is at 38.248N 84.7414 West.  By adding a
+line that reads:<br>
+to the GNIS data, the area's low point can be labelled.  Note that coordinates
+are repeated twice, once in a degrees/minutes/seconds format, and once in
+ decimal format.  (And that the data I show is not consistent!) Drawmap 
+uses the decimal format to place features.  East of the 0 meridian and 
+north of the equator are positive, west and south are negative.
+<h2>Limitations of the Program</h2>
+<p>DLG data and DEM data are not congruent.  DLG data produces an exactly
+rectangular patch. The projection produced by DEM data is more or less skewed,
+depending on how far from the equator you are.  
+This is really quite annoying when working with hydrology data on the
+1:24,000 scale.  Streams may show up on the sides of hills, rather than in
+flood plains!
+This can be repaired by post processing.
+<p>Fonts are not attractive.  Again, this is easily repaired by post 
+<p>See the new -C option to draw contour maps with color bands.
+<p>Political data, such as border lines are not available in a usable 
+format, as far as I know.
+<h2>Post processing</h2>
+<p>Here are some hints on using the GIMP as a drawmap postprocessor.
+I have previously obtained the Midway, Kentucky 1:24,000 DEM map,
+which is stored ~/maps/dem/midway/9780CELO.DDF (there are other items in
+the DEM data, but drawmap uses only the ...CEL.... file), the hydrology
+DLG map store in ~/maps/midway/hydrology/HY01LE01.DDF (again, there are
+multiple files in the directory, drawmap uses only the ....LE.... file), and
+the Kentucky GNIS data, stored in ~/maps/gnis/KY_deci.  I used <br>
+egrep "Midway\"$" ~/maps/gnis/KY_deci >~/maps/gnis/KY_deci.Midway<br>
+to select the portion of the GNIS data relevant to the Midway patch.
+<p>First, you want to draw many layers.  Drawmap will automatically
+overlay data for you.  Do not use this feature, especially if you are
+using a combination of DEM and DLG data!  Instead, use drawmap to build
+each layer separately and GIMP to manipulate and the combine the layers.
+<p>Because there are a lot of steps and I do not want to bloat this
+package by including a bunch of images, I am going to describe, rather
+than show,  the process
+of building a custom "3-d effect" contour map with hydrology and feature
+labels.  This should be enough for you to see how to use most of drawmap's
+capabilities to produce a good map.
+<p>First, produce the basic contour map.  I want color contours, but I don't
+want them so tight that they are jarring. This is a matter of taste, 
+rather than science.  For me, a 25 meter contour works well.  Use
+drawmap to build it by:<br>
+drawmap -C 25 -d ~/maps/dem/9780CEL0.DDF<br>
+<p>This builds file drawmap.sun in your current working directory.  Start up
+the GIMP.  Open this file.  Note that there is an information block at
+the top.  In my case, it reads:
+       MIDWAY, KY - 24000 --- 38.125N, 84.75W to 38.25N, 84.625W
+Elevations:  681m (2234ft) at 38.248N 84.7414W, 924m (3031ft) at 38.13N 
+This information will e needed in the next step.
+<p>But first, to complete this step, convert the image to RGB using 
+<p>Now start another drawmap run, to produce the depth data.  I used
+drawmap -h -d ~/maps/dem/9780CEL0.DDF
+Be sure to  note the pixel size
+this map produces, in my example x-width=376 and y-height=471 pixels.
+<p>This command should produce two files in your current working directory,
+drawmap.pgm and drawmap.pov.  Drawmap.pov is suitable for input to the point
+of view ray tracer (povray).  Usage of this file is beyond the scope of this
+document.  Drawmap.pgm is a portable graymap file.  Regions of lower elevation
+are deeper gray than those of higher elevation.  This is just what is needed
+for the GIMP bump-map tool!
+<p>Open drawmap.pgm in another GIMP window.  Select all (cntl-a), and copy
+(cntl-c).  Go back to your GIMP window containing drawmap.sun.  Right click
+and select Layers/Layers, Channels & Paths.  In the Layer, Channels & Paths
+window right-click and select New Layer (or press cntl-n).  The layer size
+is fine, but make sure that you select Transparent Layer Fill Type.  Now 
+return to your drawmap.sun window and paste the drawmap.pgm data into this
+new layer (cntl-v).  You will find that the pasted map does not quite overlay
+the drawmap.sun image.  Drag it until it exactly overlays the older image.
+<p>Now anchor the drawmap.pgm image (cntl-h).   Finally, you are ready to
+give texture to your map.  Right-click, select Filters/Map/Bump Map.  You
+want Linear Map, and probably Compensate for Darkening.  Azimuth controls
+the source of the virtual sun, with 0 corresponding to due East, 180 to due
+West.    You should experiment with Elevation and Depth to get  a satisfactory
+illusion of depth.
+<p>Back in the Layers, Channels & Colors box, select Mode Value or Mode 
Overlay.Either should
+result in a nice colored contour map, the colors coming from the bottom layer,
+and the illusion of depth coming from the bump-mapped layer.  Value will
+emphasize the bump-map layer, and overlay will emphasize the contour.
+<p>Now we go back to drawmap to build a line graph map.  The only one available
+from USGS for Midway is the hydrology map, which shows stream and ponds.
+drawmap needs either a DEM map or explicit boundaries to work with DLG
+maps.  As mentioned earlier, if you use a DLG map directly on a DEM map,
+the result is inaccurate due to coordinate issues.  So, we are forced to
+give direct coordinates, in my example, I run 
+drawmap -x 376 -y 471 -l 38.125,-84.75,38.25,-84.625 ~/maps/dlg/HY01LE01.DDF 
-o hydro.sun
+The x and y dimensions came from the drawmap's report on the pgm file, the
+other dimensions come from the information block in the original drawmap.sun
+file, with North and East positive.
+<p>Open hydro.sun, copy it and paste it into a new layer of our composite 
+drawing.  If you look carefully, you will see a  cut marks that frame the
+map we just produced.  Drag guide lines to the inside of these cut marks.
+Once the guide lines are in place, use the Rectangular Selection tool to
+select the rectangle formed by these guide lines.  Invert the region
+(cntl-i) and clear it (cntl-k).  At his point, I am going to clear the rest 
+of the white pixels of this layer away using right-click, Select/Select
+by Color, selecting any white pixel and pressing cntl-k.  I find it easier 
+to shear before scaling.  Both vertical shear and horizontal shear are needed.
+It is easier to see what you are doing if you first select the rectangle
+delimited by the guide lines placed earlier.  You may shear either horizontally
+or vertically first, just to make this paragraph easier to write, I will
+assume you shear horizontally first,  To do this, 
+select the Rotation, shearing, scaling,
+perspective tool, and click on the shearing radio-button in the Tool Option 
+Now in our picture click on any point of the selected rectangle.  You should
+now get a grid with the four corners contained in small boxes.  Select one of
+the corners and drag it left or right until the vertical lines of the grid are
+parallel to the edges of the DEM data.  Press Shear.  Then do the same for
+the vertical dimension by choosing one of the boxes and moving it up or down.
+<p>The GIMP shears about the center point of the selected area.  This moves
+the corners of the sheared area away from the corners of the original 
+rectangle.  You need to Select by Color the sheared data, and then move it
+so that one corner of the sheared data lies on a corner of the DEM data.
+<p>Now, you will find that the sheared data is too large.  Use the Rotation,
+shearing, scaling and perspective tool again, this time in scaling mode.
+Drag the corner opposite the one that you chose in the previous step onto
+the corresponding DEM data.  You maps should now be congruent to within
+a pixel or two.
+<p>This sounds really complicated, but in practice, can be done in two or
+three minutes, and it results in a vast improvement in the map!
+<p>Finally, we will use the GNIS data to label some place names on the map.
+Do you need to go through all of the rigamarole of the previous step to
+place the markers?  In principle, yes.  Realistically, this data is marking
+locales, and if you do not have any hydrological or transportation data
+on your map, then you can probably avoid it.  Since this example does have
+such data, it is necessary to go through the distortion process again.
+<p>In one particular, this is actually a bit harder to do than the previous
+example indicated.  Earlier, a Select By Color was done to highlight the
+rectangle being affected.  Also, we had to align a point of the DLG data
+with a point of the DEM data.  In this case, the reference points will 
+probably not exist, and so must be added before processing proceeds.
+<p>For my map, the common points are the upper left hand and lower
+right hand corners.  Use the cut marks to place guidelines around the 
+figure.  Select a 1-pixel brush and use the Draw Tool to build a little
+mark for the upper left and lower right corners.  Select and clear so
+you can see underlying elements.  Do the Shear, Shear, Move,
+Scale shuffle, as before.
+<p>This will distort both the text and the some of the markers.  The text 
+is no particular loss, GIMP fonts are much better than drawmap fonts anyway!
+Simply erase the current labels and replace them with nice GIMP Text Tool
+supplied ones.  Because the markers are small, they will mostly remain
+undistorted, and any distortion is probably only one pixel.  Either ignore
+it, or fix it using the draw tool.
+<p>Now, you should have a really accurate, colorful map.  I would provide
+a screen shot, but since the image of the map is about the same size as the
+entire binary package, it seems wasteful to do so.
+<h2>Concluding Remarks</h2>
+<p>If you find any of this confusing, have corrections, or other requests,
+email me at [EMAIL PROTECTED] 
+<p>If you find other sources for data that work with drawmap, especially non-US
+data, please let me know so that I can give appropriate links.
+Jim Penny

Added: packages/drawmap/trunk/debian/install
--- packages/drawmap/trunk/debian/install                               (rev 0)
+++ packages/drawmap/trunk/debian/install       2007-05-18 12:29:17 UTC (rev 
@@ -0,0 +1,8 @@
+drawmap usr/bin/
+ll2utm  usr/bin/
+unblock_dlg usr/bin/
+unblock_dem usr/bin/
+llsearch usr/bin/
+sdts2dem usr/bin/
+sdts2dlg usr/bin/
+debian/index.html /usr/share/doc/drawmap/html

Added: packages/drawmap/trunk/debian/patches/00list
--- packages/drawmap/trunk/debian/patches/00list                                
(rev 0)
+++ packages/drawmap/trunk/debian/patches/00list        2007-05-18 12:29:17 UTC 
(rev 837)
@@ -0,0 +1,2 @@

Added: packages/drawmap/trunk/debian/patches/01_drawmap.h.dpatch
--- packages/drawmap/trunk/debian/patches/01_drawmap.h.dpatch                   
        (rev 0)
+++ packages/drawmap/trunk/debian/patches/01_drawmap.h.dpatch   2007-05-18 
12:29:17 UTC (rev 837)
@@ -0,0 +1,17 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 01_drawmap.dpatch 
+## DP: Fix build issue
+--- drawmap-2.5.orig/drawmap.h
++++ drawmap-2.5/drawmap.h
+@@ -196,6 +196,7 @@
++#define round(x) lround(x) /* avoid type conflict with built-in function */
+ long round(double);
+ long max(long, long);
+ double max3(double, double, double);

Property changes on: packages/drawmap/trunk/debian/patches/01_drawmap.h.dpatch
Name: svn:executable
   + *

Added: packages/drawmap/trunk/debian/patches/02_dlg.c.dpatch
--- packages/drawmap/trunk/debian/patches/02_dlg.c.dpatch                       
        (rev 0)
+++ packages/drawmap/trunk/debian/patches/02_dlg.c.dpatch       2007-05-18 
12:29:17 UTC (rev 837)
@@ -0,0 +1,37 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 01_drawmap.dpatch 
+## DP: Fix build issue
+--- drawmap-2.5.orig/dlg.c
++++ drawmap-2.5/dlg.c
+@@ -1156,25 +1156,17 @@
+                               if (pointflags & 1)  {
+                                       latitude2 = p_lat1;
+                                       longitude2 = image_corners->sw_long;
+-                                      goto DONE2;
+-                              }
+-                              if (pointflags & 2)  {
++                              } else if (pointflags & 2)  {
+                                       latitude2 = p_lat2;
+                                       longitude2 = image_corners->ne_long;
+-                                      goto DONE2;
+-                              }
+-                              if (pointflags & 4)  {
++                              } else if (pointflags & 4)  {
+                                       latitude2 = image_corners->sw_lat;
+                                       longitude2 = p_long1;
+-                                      goto DONE2;
+-                              }
+-                              if (pointflags & 8)  {
++                              } else if (pointflags & 8)  {
+                                       latitude2 = image_corners->ne_lat;
+                                       longitude2 = p_long2;
+-                                      goto DONE2;
+                               }
+                       }
+               }

Property changes on: packages/drawmap/trunk/debian/patches/02_dlg.c.dpatch
Name: svn:executable
   + *

Added: packages/drawmap/trunk/debian/rules
--- packages/drawmap/trunk/debian/rules                         (rev 0)
+++ packages/drawmap/trunk/debian/rules 2007-05-18 12:29:17 UTC (rev 837)
@@ -0,0 +1,67 @@
+#!/usr/bin/make -f
+# Sample debian/rules that uses debhelper.
+# GNU copyright 1997 to 1999 by Joey Hess.
+# Uncomment this to turn on verbose mode.
+# export DH_VERBOSE=1
+# This is the debhelper compatability version to use.
+export DH_COMPAT=4
+include /usr/share/dpatch/dpatch.make
+build: build-stamp
+build-stamp: patch-stamp
+       dh_testdir
+       $(MAKE)
+       touch build-stamp
+clean: clean1 unpatch
+       dh_testdir
+       dh_testroot
+       rm -f build-stamp 
+       -$(MAKE) clean
+       dh_clean
+install: build-stamp
+       dh_testdir
+       dh_testroot
+       dh_clean -k
+       dh_installdirs
+# Build architecture-independent files here.
+binary-indep: build install
+# We have nothing to do by default.
+# Build architecture-dependent files here.
+binary-arch: build install
+       dh_installdirs
+       dh_testdir
+       dh_testroot
+       dh_installdeb
+       dh_installdocs
+       dh_installexamples
+       dh_install
+       dh_installmenu
+       dh_installcron
+       dh_installman *.1n
+       dh_installinfo
+       dh_installchangelogs 
+       dh_link
+       dh_strip
+       dh_compress
+       dh_fixperms
+       dh_installdeb
+       dh_shlibdeps
+       dh_gencontrol
+       dh_md5sums
+       dh_builddeb
+binary: binary-indep binary-arch
+.PHONY: build clean clean1 binary-indep binary-arch binary install \
+               patch unpatch 

Property changes on: packages/drawmap/trunk/debian/rules
Name: svn:executable
   + *

Pkg-grass-devel mailing list

Reply via email to