The following commit has been merged in the master branch:
commit 6a343f039530617cab5ef4e53c600275b50be668
Author: Arto Jantunen <vi...@debian.org>
Date:   Fri Sep 6 13:28:25 2013 +0300

    Update build system patches (0003-0005) to match new Makefile

diff --git a/debian/patches/0003-Properly-use-libtool.patch 
b/debian/patches/0003-Properly-use-libtool.patch
index 4616282..3732d7f 100644
--- a/debian/patches/0003-Properly-use-libtool.patch
+++ b/debian/patches/0003-Properly-use-libtool.patch
@@ -1,59 +1,81 @@
 From: Riku Voipio <riku.voi...@iki.fi>
 Date: Tue, 4 Nov 2008 14:46:56 +0200
-Subject: [PATCH] Properly use libtool
+Subject: Properly use libtool
 
 The problem is that shapelib throws away a seemingly good libtool linked
 library and replaces it with something hacks in together almost right.
 
 Bug-Debian: http://bugs.debian.org/497160
 ---
- Makefile |   32 +++++---------------------------
- 1 files changed, 5 insertions(+), 27 deletions(-)
+ Makefile |   42 ++++++++++++++++++++++++++++++++----------
+ 1 file changed, 32 insertions(+), 10 deletions(-)
 
-Index: shapelib-1.2.10/Makefile
-===================================================================
---- shapelib-1.2.10.orig/Makefile      2012-05-11 11:23:01.000000000 +0200
-+++ shapelib-1.2.10/Makefile   2012-05-11 11:23:05.000000000 +0200
-@@ -99,37 +99,15 @@
- LIBSHP_VERSION=1.0.1 # still once to be changed manually (see for 1:1:0), 
sorry
- 
- lib:
--      /bin/sh ./libtool --mode=compile gcc -DPACKAGE=\"libshp\" 
-DVERSION=\"$(SHPLIB_VERSION)\" -DSTDC_HEADERS=1  -I. -I. -I/usr/local/include  
  -g -O2 -c shpopen.c
--      gcc -DPACKAGE=\"libshp\" -DVERSION=\"$(SHPLIB_VERSION)\" 
-DSTDC_HEADERS=1 -I. -I. -I/usr/local/include -g -O2 -c  -fPIC -DPIC shpopen.c 
-o .libs/shpopen.lo
--      gcc -DPACKAGE=\"libshp\" -DVERSION=\"$(SHPLIB_VERSION)\" 
-DSTDC_HEADERS=1 -I. -I. -I/usr/local/include -g -O2 -c shpopen.c -o shpopen.o 
>/dev/null 2>&1
--      mv -f .libs/shpopen.lo shpopen.lo
--      /bin/sh ./libtool --mode=compile gcc -DPACKAGE=\"libshp\" 
-DVERSION=\"$(SHPLIB_VERSION)\" -DSTDC_HEADERS=1  -I. -I. -I/usr/local/include  
  -g -O2 -c shptree.c
--      rm -f .libs/shptree.lo
--      gcc -DPACKAGE=\"libshp\" -DVERSION=\"$(SHPLIB_VERSION)\" 
-DSTDC_HEADERS=1 -I. -I. -I/usr/local/include -g -O2 -c  -fPIC -DPIC shptree.c 
-o .libs/shptree.lo
--      gcc -DPACKAGE=\"libshp\" -DVERSION=\"$(SHPLIB_VERSION)\" 
-DSTDC_HEADERS=1 -I. -I. -I/usr/local/include -g -O2 -c shptree.c -o shptree.o 
>/dev/null 2>&1
--      mv -f .libs/shptree.lo shptree.lo
--      /bin/sh ./libtool --mode=compile gcc -DPACKAGE=\"libshp\" 
-DVERSION=\"$(SHPLIB_VERSION)\" -DSTDC_HEADERS=1  -I. -I. -I/usr/local/include  
  -g -O2 -c dbfopen.c
--      rm -f .libs/dbfopen.lo
--      gcc -DPACKAGE=\"libshp\" -DVERSION=\"$(SHPLIB_VERSION)\" 
-DSTDC_HEADERS=1 -I. -I. -I/usr/local/include -g -O2 -c  -fPIC -DPIC dbfopen.c 
-o .libs/dbfopen.lo
--      gcc -DPACKAGE=\"libshp\" -DVERSION=\"$(SHPLIB_VERSION)\" 
-DSTDC_HEADERS=1 -I. -I. -I/usr/local/include -g -O2 -c dbfopen.c -o dbfopen.o 
>/dev/null 2>&1
--      mv -f .libs/dbfopen.lo dbfopen.lo
--      /bin/sh ./libtool --mode=link gcc  -g -O2  -o libshp.la -rpath 
/usr/local/lib -version-info 1:1:0 shpopen.lo shptree.lo dbfopen.lo  
--      rm -fr .libs/libshp.la .libs/libshp.* .libs/libshp.*
--      rm -fr .libs/libshp.lax
--      mkdir .libs/libshp.lax
--      /usr/bin/ld -G -h libshp.so.1 -o .libs/libshp.so.$(LIBSHP_VERSION)  
shpopen.lo shptree.lo dbfopen.lo  -lc
+diff --git a/Makefile b/Makefile
+index 0c41d8a..8073f9c 100644
+--- a/Makefile
++++ b/Makefile
+@@ -21,7 +21,7 @@ shptree.o:   shptree.c shapefil.h
+ dbfopen.o:    dbfopen.c shapefil.h
+       $(CC) $(CFLAGS) -c dbfopen.c
+ 
+-safileio.o:   safileio.c shapefil.h
++safileio.o:    shapefil.h
+       $(CC) $(CFLAGS) -c safileio.c
+ 
+ shpcreate:    shpcreate.c shpopen.o safileio.o 
+@@ -57,6 +57,7 @@ shptreedump: shptreedump.c shptree.o shpopen.o safileio.o
+ 
+ clean:
+       rm -f *.o shptest $(SHPBIN) libshp.a 
++      rm -rf *.lo *.la .libs
+ 
+ test: test2 test3
+ 
+@@ -97,17 +98,38 @@ test3:
+       fi
+ 
+ 
+-lib:  libshp.a
+-
+-libshp.a:     $(LIBOBJ)
+-      ar r libshp.a $(LIBOBJ)
+-
+-lib_install:  libshp.a
+-      cp libshp.a $(PREFIX)/lib
+-      cp shapefil.h $(PREFIX)/include
 -
--      (cd .libs && rm -f libshp.so.1 && ln -s libshp.so.$(LIBSHP_VERSION) 
libshp.so.1)
--      (cd .libs && rm -f libshp.so && ln -s libshp.so.$(LIBSHP_VERSION) 
libshp.so)
--      ar cru .libs/libshp.a  shpopen.o shptree.o dbfopen.o 
--      ranlib .libs/libshp.a
--      rm -fr .libs/libshp.lax
--      (cd .libs && rm -f libshp.la && ln -s ../libshp.la libshp.la)
+ bin_install:  $(SHPBIN)
+       cp $(SHPBIN) $(PREFIX)/bin
+ 
+ install:      lib_install bin_install
+ 
++# 
-----------------------------------------------------------------------------
++# The following is contributed by Jan-Oliver Wagner, and should allow for
++# creating shared libraries on most platforms with gcc, and libtool installed.
++
++SHPLIB_VERSION=1.2.9
++LIBSHP_VERSION=1.0.1 # still once to be changed manually (see for 1:1:0), 
sorry
++
++lib: .libs/libshp.so
++
++.libs/libshp.so:
 +      libtool --mode=compile gcc -DPACKAGE=\"libshp\" 
-DVERSION=\"$(SHPLIB_VERSION)\" -DSTDC_HEADERS=1  -I. $(CPPFLAGS) $(CFLAGS) -c 
shpopen.c
 +      libtool --mode=compile gcc -DPACKAGE=\"libshp\" 
-DVERSION=\"$(SHPLIB_VERSION)\" -DSTDC_HEADERS=1  -I. $(CPPFLAGS) $(CFLAGS) -c 
shptree.c
 +      libtool --mode=compile gcc -DPACKAGE=\"libshp\" 
-DVERSION=\"$(SHPLIB_VERSION)\" -DSTDC_HEADERS=1  -I. $(CPPFLAGS) $(CFLAGS) -c 
dbfopen.c
-+      libtool --mode=link gcc $(CFLAGS) $(LDFLAGS) -o libshp.la -rpath 
/usr/lib -version-info 1:1:0 shpopen.lo shptree.lo dbfopen.lo
- 
- lib_install:
-       cp .libs/libshp.la .libs/libshp.lai
-       /bin/sh ./mkinstalldirs /usr/local/lib
--      /bin/sh ./libtool  --mode=install /usr/bin/install -c libshp.la 
/usr/local/lib/libshp.la
++      libtool --mode=compile gcc -DPACKAGE=\"libshp\" 
-DVERSION=\"$(SHPLIB_VERSION)\" -DSTDC_HEADERS=1  -I. $(CPPFLAGS) $(CFLAGS) -c 
safileio.c
++      libtool --mode=link gcc $(CFLAGS) $(LDFLAGS) -o libshp.la -rpath 
/usr/lib -version-info 1:1:0 shpopen.lo shptree.lo dbfopen.lo safileio.lo
++
++lib_install:
++      cp .libs/libshp.la .libs/libshp.lai
++      /bin/sh ./mkinstalldirs /usr/local/lib
 +      libtool  --mode=install /usr/bin/install -c libshp.la 
/usr/local/lib/libshp.la
-       /usr/bin/install -c .libs/libshp.so.$(LIBSHP_VERSION) 
/usr/local/lib/libshp.so.$(LIBSHP_VERSION)
-       (cd /usr/local/lib && rm -f libshp.so.1 && ln -s 
libshp.so.$(LIBSHP_VERSION) libshp.so.1)
-       (cd /usr/local/lib && rm -f libshp.so && ln -s 
libshp.so.$(LIBSHP_VERSION) libshp.so)
++      /usr/bin/install -c .libs/libshp.so.$(LIBSHP_VERSION) 
/usr/local/lib/libshp.so.$(LIBSHP_VERSION)
++      (cd /usr/local/lib && rm -f libshp.so.1 && ln -s 
libshp.so.$(LIBSHP_VERSION) libshp.so.1)
++      (cd /usr/local/lib && rm -f libshp.so && ln -s 
libshp.so.$(LIBSHP_VERSION) libshp.so)
++      chmod +x /usr/local/lib/libshp.so.$(LIBSHP_VERSION)
++      /usr/bin/install -c .libs/libshp.la /usr/local/lib/libshp.la
++      /usr/bin/install -c .libs/libshp.a /usr/local/lib/libshp.a
++      ranlib /usr/local/lib/libshp.a
++      chmod 644 /usr/local/lib/libshp.a
++      /bin/sh ./mkinstalldirs /usr/local/include/libshp
++      /usr/bin/install -c -m 644 shapefil.h 
/usr/local/include/libshp/shapefil.h
diff --git 
a/debian/patches/0004-Dynamically-link-the-shp-binaries-to-libshp.patch 
b/debian/patches/0004-Dynamically-link-the-shp-binaries-to-libshp.patch
index e2b9843..0ef30e8 100644
--- a/debian/patches/0004-Dynamically-link-the-shp-binaries-to-libshp.patch
+++ b/debian/patches/0004-Dynamically-link-the-shp-binaries-to-libshp.patch
@@ -1,92 +1,71 @@
 From: Arto Jantunen <vi...@debian.org>
 Date: Tue, 8 May 2012 14:19:20 +0300
-Subject: [PATCH] Dynamically link the shp* binaries to libshp
+Subject: Dynamically link the shp* binaries to libshp
 
 Also use CPPFLAGS and LDFLAGS, necessary for hardening flags.
-
 ---
- Makefile |   55 ++++++++++++++++++++++++-------------------------------
- 1 files changed, 24 insertions(+), 31 deletions(-)
+ Makefile |   42 +++++++++++++++++++++---------------------
+ 1 file changed, 21 insertions(+), 21 deletions(-)
 
-Index: shapelib-1.2.10/Makefile
-===================================================================
---- shapelib-1.2.10.orig/Makefile      2012-05-11 11:23:05.000000000 +0200
-+++ shapelib-1.2.10/Makefile   2012-05-11 11:23:09.000000000 +0200
-@@ -6,45 +6,36 @@
- 
- all:  shpcreate shpadd shpdump shprewind dbfcreate dbfadd dbfdump shptest
+diff --git a/Makefile b/Makefile
+index 8073f9c..6eb74a1 100644
+--- a/Makefile
++++ b/Makefile
+@@ -24,36 +24,36 @@ dbfopen.o: dbfopen.c shapefil.h
+ safileio.o:    shapefil.h
+       $(CC) $(CFLAGS) -c safileio.c
  
--shpopen.o:    shpopen.c shapefil.h
--      $(CC) $(CFLAGS) -c shpopen.c
+-shpcreate:    shpcreate.c shpopen.o safileio.o 
+-      $(CC) $(CFLAGS) shpcreate.c shpopen.o safileio.o $(LINKOPT) -o shpcreate
 +shpcreate:    shpcreate.c .libs/libshp.so
 +      $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) shpcreate.c $(LINKOPT) -o 
shpcreate .libs/libshp.so
  
--shptree.o:    shptree.c shapefil.h
--      $(CC) $(CFLAGS) -c shptree.c
+-shpadd:               shpadd.c shpopen.o safileio.o
+-      $(CC) $(CFLAGS) shpadd.c shpopen.o safileio.o $(LINKOPT) -o shpadd
 +shpadd:               shpadd.c .libs/libshp.so
 +      $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) shpadd.c $(LINKOPT) -o shpadd 
.libs/libshp.so
  
--dbfopen.o:    dbfopen.c shapefil.h
--      $(CC) $(CFLAGS) -c dbfopen.c
+-shpdump:      shpdump.c shpopen.o safileio.o
+-      $(CC) $(CFLAGS) shpdump.c shpopen.o safileio.o $(LINKOPT) -o shpdump
 +shpdump:      shpdump.c .libs/libshp.so
 +      $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) shpdump.c $(LINKOPT) -o shpdump 
.libs/libshp.so
  
--shpcreate:    shpcreate.c shpopen.o
--      $(CC) $(CFLAGS) shpcreate.c shpopen.o $(LINKOPT) -o shpcreate
+-shprewind:    shprewind.c shpopen.o safileio.o
+-      $(CC) $(CFLAGS) shprewind.c shpopen.o safileio.o $(LINKOPT) -o shprewind
 +shprewind:    shprewind.c .libs/libshp.so
 +      $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) shprewind.c $(LINKOPT) -o 
shprewind .libs/libshp.so
  
--shpadd:               shpadd.c shpopen.o
--      $(CC) $(CFLAGS) shpadd.c shpopen.o $(LINKOPT) -o shpadd
+-dbfcreate:    dbfcreate.c dbfopen.o safileio.o
+-      $(CC) $(CFLAGS) dbfcreate.c dbfopen.o safileio.o $(LINKOPT) -o dbfcreate
 +dbfcreate:    dbfcreate.c .libs/libshp.so
 +      $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) dbfcreate.c $(LINKOPT) -o 
dbfcreate .libs/libshp.so
  
--shpdump:      shpdump.c shpopen.o
--      $(CC) $(CFLAGS) shpdump.c shpopen.o $(LINKOPT) -o shpdump
+-dbfadd:               dbfadd.c dbfopen.o safileio.o
+-      $(CC) $(CFLAGS) dbfadd.c dbfopen.o safileio.o $(LINKOPT) -o dbfadd
 +dbfadd:               dbfadd.c .libs/libshp.so
 +      $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) dbfadd.c $(LINKOPT) -o dbfadd 
.libs/libshp.so
  
--shprewind:    shprewind.c shpopen.o
--      $(CC) $(CFLAGS) shprewind.c shpopen.o $(LINKOPT) -o shprewind
+-dbfdump:      dbfdump.c dbfopen.o safileio.o
+-      $(CC) $(CFLAGS) dbfdump.c dbfopen.o safileio.o $(LINKOPT) -o dbfdump
 +dbfdump:      dbfdump.c .libs/libshp.so
 +      $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) dbfdump.c $(LINKOPT) -o dbfdump 
.libs/libshp.so
  
--dbfcreate:    dbfcreate.c dbfopen.o
--      $(CC) $(CFLAGS) dbfcreate.c dbfopen.o $(LINKOPT) -o dbfcreate
+-shptest:      shptest.c shpopen.o safileio.o
+-      $(CC) $(CFLAGS) shptest.c shpopen.o safileio.o $(LINKOPT) -o shptest
 +shptest:      shptest.c .libs/libshp.so
 +      $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) shptest.c $(LINKOPT) -o shptest 
.libs/libshp.so
  
--dbfadd:               dbfadd.c dbfopen.o
--      $(CC) $(CFLAGS) dbfadd.c dbfopen.o $(LINKOPT) -o dbfadd
+-shputils:     shputils.c shpopen.o safileio.o dbfopen.o 
+-      $(CC) $(CFLAGS) shputils.c shpopen.o safileio.o dbfopen.o  $(LINKOPT) 
-o shputils
 +shputils:     shputils.c .libs/libshp.so
 +      $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) shputils.c $(LINKOPT) -o 
shputils .libs/libshp.so
  
--dbfdump:      dbfdump.c dbfopen.o
--      $(CC) $(CFLAGS) dbfdump.c dbfopen.o $(LINKOPT) -o dbfdump
--
--shptest:      shptest.c shpopen.o
--      $(CC) $(CFLAGS) shptest.c shpopen.o $(LINKOPT) -o shptest
--
--shputils:     shputils.c shpopen.o dbfopen.o
--      $(CC) $(CFLAGS) shputils.c shpopen.o dbfopen.o $(LINKOPT) -o shputils
--
--shptreedump:  shptreedump.c shptree.o shpopen.o
--      $(CC) $(CFLAGS) shptreedump.c shptree.o shpopen.o $(LINKOPT) \
+-shptreedump:  shptreedump.c shptree.o shpopen.o safileio.o
+-      $(CC) $(CFLAGS) shptreedump.c shptree.o shpopen.o safileio.o $(LINKOPT) 
\
 -              -o shptreedump
 +shptreedump:  shptreedump.c .libs/libshp.so
 +      $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) shptreedump.c $(LINKOPT) \
 +              -o shptreedump .libs/libshp.so
  
  clean:
-       rm -f *.o dbfdump dbfcreate dbfadd shpdump shpcreate shpadd shputils
-@@ -98,7 +89,9 @@
- SHPLIB_VERSION=1.2.9
- LIBSHP_VERSION=1.0.1 # still once to be changed manually (see for 1:1:0), 
sorry
- 
--lib:
-+lib: .libs/libshp.so
-+
-+.libs/libshp.so:
-       libtool --mode=compile gcc -DPACKAGE=\"libshp\" 
-DVERSION=\"$(SHPLIB_VERSION)\" -DSTDC_HEADERS=1  -I. $(CPPFLAGS) $(CFLAGS) -c 
shpopen.c
-       libtool --mode=compile gcc -DPACKAGE=\"libshp\" 
-DVERSION=\"$(SHPLIB_VERSION)\" -DSTDC_HEADERS=1  -I. $(CPPFLAGS) $(CFLAGS) -c 
shptree.c
-       libtool --mode=compile gcc -DPACKAGE=\"libshp\" 
-DVERSION=\"$(SHPLIB_VERSION)\" -DSTDC_HEADERS=1  -I. $(CPPFLAGS) $(CFLAGS) -c 
dbfopen.c
+       rm -f *.o shptest $(SHPBIN) libshp.a 
diff --git 
a/debian/patches/0005-Stop-setting-CFLAGS-and-PREFIX-in-the-Makefile.patch 
b/debian/patches/0005-Stop-setting-CFLAGS-and-PREFIX-in-the-Makefile.patch
new file mode 100644
index 0000000..e0559f6
--- /dev/null
+++ b/debian/patches/0005-Stop-setting-CFLAGS-and-PREFIX-in-the-Makefile.patch
@@ -0,0 +1,29 @@
+From: Arto Jantunen <vi...@debian.org>
+Date: Tue, 8 May 2012 14:31:56 +0300
+Subject: Stop setting CFLAGS and PREFIX in the Makefile
+
+---
+ Makefile |    6 ++++--
+ 1 file changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/Makefile b/Makefile
+index 6eb74a1..a74331d 100644
+--- a/Makefile
++++ b/Makefile
+@@ -1,12 +1,14 @@
+ 
+-PREFIX        =       /usr/local
+-CFLAGS        =       -g -Wall -fPIC
++#PREFIX       =       /usr/local
++#CFLAGS       =       -g -Wall -fPIC
+ #CFLAGS  =       -g -DUSE_CPL
+ #CC = g++
+ 
+ LIBOBJ        =       shpopen.o dbfopen.o safileio.o shptree.o 
+ SHPBIN        =       shpcreate shpadd shpdump shprewind dbfcreate dbfadd 
dbfdump \
+               shptreedump 
++#LINKOPT      =       /usr/local/lib/libdbmalloc.a
++#CFLAGS       =       -g
+ 
+ default:      all
+ 
diff --git a/debian/patches/0005-Stop-setting-CFLAGS-in-the-Makefile.patch 
b/debian/patches/0005-Stop-setting-CFLAGS-in-the-Makefile.patch
deleted file mode 100644
index 81e167d..0000000
--- a/debian/patches/0005-Stop-setting-CFLAGS-in-the-Makefile.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-From: Arto Jantunen <vi...@debian.org>
-Date: Tue, 8 May 2012 14:31:56 +0300
-Subject: [PATCH] Stop setting CFLAGS in the Makefile
-
----
- Makefile |    2 +-
- 1 files changed, 1 insertions(+), 1 deletions(-)
-
-diff --git a/Makefile b/Makefile
-index 3e53d15..6a614f1 100644
---- a/Makefile
-+++ b/Makefile
-@@ -1,6 +1,6 @@
- 
- #LINKOPT      =       /usr/local/lib/libdbmalloc.a
--CFLAGS        =       -g
-+#CFLAGS       =       -g
- 
- default:      all
- 
--- 
diff --git a/debian/patches/series b/debian/patches/series
index 61243bc..0f4f152 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,4 +1,4 @@
 0001-Add-manpages.patch
 0003-Properly-use-libtool.patch
 0004-Dynamically-link-the-shp-binaries-to-libshp.patch
-0005-Stop-setting-CFLAGS-in-the-Makefile.patch
+0005-Stop-setting-CFLAGS-and-PREFIX-in-the-Makefile.patch

-- 
Library for reading and writing ArcView Shapefiles

_______________________________________________
Pkg-grass-devel mailing list
Pkg-grass-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-grass-devel

Reply via email to