diff --git a/debian/.git-dpm b/debian/.git-dpm new file mode 100644 index 0000000..774d498 --- /dev/null +++ b/debian/.git-dpm @@ -0,0 +1,8 @@ +# see git-dpm(1) from git-dpm package +a6312ab3586cc621ef7f3f3f4d5aae57ee292168 +a6312ab3586cc621ef7f3f3f4d5aae57ee292168 +cf987032600e21d504318bace8c304777ec1dd24 +cf987032600e21d504318bace8c304777ec1dd24 +splix_2.0.0+svn315.orig.tar.gz +4f706b90a92706397ae6106d23983c36c7c5b688 +232905 diff --git a/debian/patches/0001-Fix-alignment-problem-on-armel.patch b/debian/patches/0001-Fix-alignment-problem-on-armel.patch index af2cbec..2d2f4c8 100644 --- a/debian/patches/0001-Fix-alignment-problem-on-armel.patch +++ b/debian/patches/0001-Fix-alignment-problem-on-armel.patch @@ -1,3 +1,4 @@ +From fe098f575428cc5af59d43db10842735775f7094 Mon Sep 17 00:00:00 2001 From: Luca Niccoli Date: Sun, 12 Jun 2011 15:30:15 +0200 Subject: Fix alignment problem on armel diff --git a/debian/patches/0002-Dont-let-bash-trim-whitespace.patch b/debian/patches/0002-Dont-let-bash-trim-whitespace.patch deleted file mode 100644 index 4c59f55..0000000 --- a/debian/patches/0002-Dont-let-bash-trim-whitespace.patch +++ /dev/null @@ -1,17 +0,0 @@ -Description: Set IFS when looping over the file to avoid letting /bin/bash trim the whitespace - as this makes the build unreproducible. - The whitespace in the original .drv.in files should be fixed nevertheless. -Author: Didier Raboud -Last-Update: 2016-06-12 - ---- a/ppd/compile.sh -+++ b/ppd/compile.sh -@@ -14,7 +14,7 @@ - # Function parseFile - # - parseFile() { -- while read LINE; do -+ while IFS= read LINE; do - if [ -n "`echo "$LINE" | grep '^[ \t]*#import[ \t]*"[a-zA-Z0-9\.\-]*"'`" ]; then - FILE=`echo "$LINE" | sed -re 's/[ \t]*#import[ \t]"([a-zA-Z0-9\.\-]*)"/\1/'` - parseFile $FILE $2 diff --git a/debian/patches/0002-Set-IFS-when-looping-over-the-file-to-avoid-letting-.patch b/debian/patches/0002-Set-IFS-when-looping-over-the-file-to-avoid-letting-.patch new file mode 100644 index 0000000..ed2831e --- /dev/null +++ b/debian/patches/0002-Set-IFS-when-looping-over-the-file-to-avoid-letting-.patch @@ -0,0 +1,26 @@ +From c42f94918e6b1fee3371242a6c9751a324106a67 Mon Sep 17 00:00:00 2001 +From: Didier Raboud +Date: Sat, 10 Feb 2018 17:11:44 +0100 +Subject: Set IFS when looping over the file to avoid letting /bin/bash trim + the whitespace + + as this makes the build unreproducible. + The whitespace in the original .drv.in files should be fixed nevertheless. +Last-Update: 2016-06-12 +--- + ppd/compile.sh | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/ppd/compile.sh b/ppd/compile.sh +index d44a3ae..79f5445 100755 +--- a/ppd/compile.sh ++++ b/ppd/compile.sh +@@ -14,7 +14,7 @@ + # Function parseFile + # + parseFile() { +- while read LINE; do ++ while IFS= read LINE; do + if [ -n "`echo "$LINE" | grep '^[ \t]*#import[ \t]*"[a-zA-Z0-9\.\-]*"'`" ]; then + FILE=`echo "$LINE" | sed -re 's/[ \t]*#import[ \t]"([a-zA-Z0-9\.\-]*)"/\1/'` + parseFile $FILE $2 diff --git a/debian/patches/0003-Fix-the-aready-already-typo.patch b/debian/patches/0003-Fix-the-aready-already-typo.patch new file mode 100644 index 0000000..76355cb --- /dev/null +++ b/debian/patches/0003-Fix-the-aready-already-typo.patch @@ -0,0 +1,40 @@ +From b5711388adaee9fe3980006a2915dc09e80aa942 Mon Sep 17 00:00:00 2001 +From: Didier Raboud +Date: Sat, 10 Feb 2018 17:11:45 +0100 +Subject: =?UTF-8?q?Fix=20the=20'aready'=20=E2=86=92=20'already'=20typo?= +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Last-Update: 2016-06-12 +--- + src/algo0x0d.cpp | 2 +- + src/cache.cpp | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/src/algo0x0d.cpp b/src/algo0x0d.cpp +index 5489886..6514999 100644 +--- a/src/algo0x0d.cpp ++++ b/src/algo0x0d.cpp +@@ -448,7 +448,7 @@ BandPlane * Algo0x0D::compress(const Request & request, unsigned char *data, + /* Zero value byte padding for data size alignment to 4-byte boundary. */ + unsigned long zerosPad = 4 - ( outputSize % 4 ); + +- /* Pad anyway even if aready aligned. */ ++ /* Pad anyway even if already aligned. */ + if ( outputSize + zerosPad <= maximumBufferSize ) { + while ( zerosPad-- ) { + output[ outputSize++ ] = 0; +diff --git a/src/cache.cpp b/src/cache.cpp +index 0602630..8a6a310 100644 +--- a/src/cache.cpp ++++ b/src/cache.cpp +@@ -569,7 +569,7 @@ bool CacheEntry::restoreIntoMemory() + + if (!_tempFile) { + ERRORMSG(_("Trying to restore a page instance into memory which is " +- "aready into memory")); ++ "already into memory")); + return false; + } + diff --git a/debian/patches/0003-fix-aready-typo.patch b/debian/patches/0003-fix-aready-typo.patch deleted file mode 100644 index a1ffcb5..0000000 --- a/debian/patches/0003-fix-aready-typo.patch +++ /dev/null @@ -1,26 +0,0 @@ -Description: Fix the 'aready' → 'already' typo -Author: Didier Raboud -Last-Update: 2016-06-12 - ---- a/src/algo0x0d.cpp -+++ b/src/algo0x0d.cpp -@@ -448,7 +448,7 @@ - /* Zero value byte padding for data size alignment to 4-byte boundary. */ - unsigned long zerosPad = 4 - ( outputSize % 4 ); - -- /* Pad anyway even if aready aligned. */ -+ /* Pad anyway even if already aligned. */ - if ( outputSize + zerosPad <= maximumBufferSize ) { - while ( zerosPad-- ) { - output[ outputSize++ ] = 0; ---- a/src/cache.cpp -+++ b/src/cache.cpp -@@ -569,7 +569,7 @@ - - if (!_tempFile) { - ERRORMSG(_("Trying to restore a page instance into memory which is " -- "aready into memory")); -+ "already into memory")); - return false; - } - diff --git a/debian/patches/0004-Set-debian-build-flags-during-build.patch b/debian/patches/0004-Set-debian-build-flags-during-build.patch new file mode 100644 index 0000000..d9551bb --- /dev/null +++ b/debian/patches/0004-Set-debian-build-flags-during-build.patch @@ -0,0 +1,30 @@ +From abaeacb60a6936304e2e940961ba95675e2c8066 Mon Sep 17 00:00:00 2001 +From: Luca Niccoli +Date: Mon, 12 Aug 2013 13:50:08 +0200 +Subject: Set debian build flags during build. + +Signed-off-by: Luca Niccoli +--- + module.mk | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +diff --git a/module.mk b/module.mk +index 9b6229c..ec84ace 100644 +--- a/module.mk ++++ b/module.mk +@@ -28,12 +28,12 @@ DRV_ONLY ?= 0 + + + # Flags +-CXXFLAGS += `cups-config --cflags` -Iinclude -Wall -I/opt/local/include ++CXXFLAGS += $(shell dpkg-buildflags --get CXXFLAGS) $(shell dpkg-buildflags --get CPPFLAGS) `cups-config --cflags` -Iinclude -Wall -I/opt/local/include + DEBUG_CXXFLAGS += -DDEBUG -DDUMP_CACHE + OPTIM_CXXFLAGS += -g +-rastertoqpdl_LDFLAGS := `cups-config --ldflags` -L/opt/local/lib ++rastertoqpdl_LDFLAGS := $(shell dpkg-buildflags --get LDFLAGS) `cups-config --ldflags` -L/opt/local/lib + rastertoqpdl_LIBS := `cups-config --libs` -lcupsimage +-pstoqpdl_LDFLAGS := `cups-config --ldflags` ++pstoqpdl_LDFLAGS := $(shell dpkg-buildflags --get LDFLAGS) `cups-config --ldflags` + pstoqpdl_LIBS := `cups-config --libs` -lcupsimage + + diff --git a/debian/patches/0005-Set-debian-build-flags-during-build.patch b/debian/patches/0005-Set-debian-build-flags-during-build.patch deleted file mode 100644 index 590c90f..0000000 --- a/debian/patches/0005-Set-debian-build-flags-during-build.patch +++ /dev/null @@ -1,29 +0,0 @@ -From: Luca Niccoli -Date: Mon, 12 Aug 2013 13:50:08 +0200 -Subject: Set debian build flags during build. - -Signed-off-by: Luca Niccoli ---- - module.mk | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) - -diff --git a/module.mk b/module.mk -index 9b6229c..bc45432 100644 ---- a/module.mk -+++ b/module.mk -@@ -28,12 +28,12 @@ DRV_ONLY ?= 0 - - - # Flags --CXXFLAGS += `cups-config --cflags` -Iinclude -Wall -I/opt/local/include -+CXXFLAGS += $(shell dpkg-buildflags --get CXXFLAGS) $(shell dpkg-buildflags --get CPPFLAGS) `cups-config --cflags` -Iinclude -Wall -I/opt/local/include - DEBUG_CXXFLAGS += -DDEBUG -DDUMP_CACHE - OPTIM_CXXFLAGS += -g --rastertoqpdl_LDFLAGS := `cups-config --ldflags` -L/opt/local/lib -+rastertoqpdl_LDFLAGS := $(shell dpkg-buildflags --get LDFLAGS) `cups-config --ldflags` -L/opt/local/lib - rastertoqpdl_LIBS := `cups-config --libs` -lcupsimage --pstoqpdl_LDFLAGS := `cups-config --ldflags` -+pstoqpdl_LDFLAGS := $(shell dpkg-buildflags --get LDFLAGS) `cups-config --ldflags` - pstoqpdl_LIBS := `cups-config --libs` -lcupsimage - - diff --git a/debian/patches/0005-Use-compilers-passed-to-make.patch b/debian/patches/0005-Use-compilers-passed-to-make.patch new file mode 100644 index 0000000..d7989cc --- /dev/null +++ b/debian/patches/0005-Use-compilers-passed-to-make.patch @@ -0,0 +1,28 @@ +From a6312ab3586cc621ef7f3f3f4d5aae57ee292168 Mon Sep 17 00:00:00 2001 +From: Helmut Grohne +Date: Sat, 10 Feb 2018 17:11:47 +0100 +Subject: Use compilers passed to make + +--- + rules.mk | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/rules.mk b/rules.mk +index 26ce4b5..17ca407 100644 +--- a/rules.mk ++++ b/rules.mk +@@ -6,12 +6,12 @@ + + $(rastertoqpdl_TARGET): $(rastertoqpdl_OBJ) + $(call printCmd, $(cmd_link)) +- $(Q)g++ -o $@ $^ $(rastertoqpdl_CXXFLAGS) $(rastertoqpdl_LDFLAGS) \ ++ $(Q)$(CXX) -o $@ $^ $(rastertoqpdl_CXXFLAGS) $(rastertoqpdl_LDFLAGS) \ + $(rastertoqpdl_LIBS) + + $(pstoqpdl_TARGET): $(pstoqpdl_OBJ) + $(call printCmd, $(cmd_link)) +- $(Q)g++ -o $@ $^ $(pstoqpdl_CXXFLAGS) $(pstoqpdl_LDFLAGS) \ ++ $(Q)$(CXX) -o $@ $^ $(pstoqpdl_CXXFLAGS) $(pstoqpdl_LDFLAGS) \ + $(pstoqpdl_LIBS) + + .PHONY: install installcms diff --git a/debian/patches/0006-cross.patch b/debian/patches/0006-cross.patch deleted file mode 100644 index afa638b..0000000 --- a/debian/patches/0006-cross.patch +++ /dev/null @@ -1,22 +0,0 @@ -From: Helmut Grohne -Subject: Use compilers passed to make - -Index: splix-2.0.0+svn315/rules.mk -=================================================================== ---- splix-2.0.0+svn315.orig/rules.mk -+++ splix-2.0.0+svn315/rules.mk -@@ -6,12 +6,12 @@ - - $(rastertoqpdl_TARGET): $(rastertoqpdl_OBJ) - $(call printCmd, $(cmd_link)) -- $(Q)g++ -o $@ $^ $(rastertoqpdl_CXXFLAGS) $(rastertoqpdl_LDFLAGS) \ -+ $(Q)$(CXX) -o $@ $^ $(rastertoqpdl_CXXFLAGS) $(rastertoqpdl_LDFLAGS) \ - $(rastertoqpdl_LIBS) - - $(pstoqpdl_TARGET): $(pstoqpdl_OBJ) - $(call printCmd, $(cmd_link)) -- $(Q)g++ -o $@ $^ $(pstoqpdl_CXXFLAGS) $(pstoqpdl_LDFLAGS) \ -+ $(Q)$(CXX) -o $@ $^ $(pstoqpdl_CXXFLAGS) $(pstoqpdl_LDFLAGS) \ - $(pstoqpdl_LIBS) - - .PHONY: install installcms diff --git a/debian/patches/series b/debian/patches/series index 947cb47..9d60346 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -1,5 +1,5 @@ 0001-Fix-alignment-problem-on-armel.patch -0002-Dont-let-bash-trim-whitespace.patch -0003-fix-aready-typo.patch -0005-Set-debian-build-flags-during-build.patch -0006-cross.patch +0002-Set-IFS-when-looping-over-the-file-to-avoid-letting-.patch +0003-Fix-the-aready-already-typo.patch +0004-Set-debian-build-flags-during-build.patch +0005-Use-compilers-passed-to-make.patch diff --git a/module.mk b/module.mk index 9b6229c..ec84ace 100644 --- a/module.mk +++ b/module.mk @@ -28,12 +28,12 @@ # Flags -CXXFLAGS += `cups-config --cflags` -Iinclude -Wall -I/opt/local/include +CXXFLAGS += $(shell dpkg-buildflags --get CXXFLAGS) $(shell dpkg-buildflags --get CPPFLAGS) `cups-config --cflags` -Iinclude -Wall -I/opt/local/include DEBUG_CXXFLAGS += -DDEBUG -DDUMP_CACHE OPTIM_CXXFLAGS += -g -rastertoqpdl_LDFLAGS := `cups-config --ldflags` -L/opt/local/lib +rastertoqpdl_LDFLAGS := $(shell dpkg-buildflags --get LDFLAGS) `cups-config --ldflags` -L/opt/local/lib rastertoqpdl_LIBS := `cups-config --libs` -lcupsimage -pstoqpdl_LDFLAGS := `cups-config --ldflags` +pstoqpdl_LDFLAGS := $(shell dpkg-buildflags --get LDFLAGS) `cups-config --ldflags` pstoqpdl_LIBS := `cups-config --libs` -lcupsimage diff --git a/ppd/compile.sh b/ppd/compile.sh index d44a3ae..79f5445 100755 --- a/ppd/compile.sh +++ b/ppd/compile.sh @@ -14,7 +14,7 @@ # Function parseFile # parseFile() { - while read LINE; do + while IFS= read LINE; do if [ -n "`echo "$LINE" | grep '^[ \t]*#import[ \t]*"[a-zA-Z0-9\.\-]*"'`" ]; then FILE=`echo "$LINE" | sed -re 's/[ \t]*#import[ \t]"([a-zA-Z0-9\.\-]*)"/\1/'` parseFile $FILE $2 diff --git a/rules.mk b/rules.mk index 26ce4b5..17ca407 100644 --- a/rules.mk +++ b/rules.mk @@ -6,12 +6,12 @@ $(rastertoqpdl_TARGET): $(rastertoqpdl_OBJ) $(call printCmd, $(cmd_link)) - $(Q)g++ -o $@ $^ $(rastertoqpdl_CXXFLAGS) $(rastertoqpdl_LDFLAGS) \ + $(Q)$(CXX) -o $@ $^ $(rastertoqpdl_CXXFLAGS) $(rastertoqpdl_LDFLAGS) \ $(rastertoqpdl_LIBS) $(pstoqpdl_TARGET): $(pstoqpdl_OBJ) $(call printCmd, $(cmd_link)) - $(Q)g++ -o $@ $^ $(pstoqpdl_CXXFLAGS) $(pstoqpdl_LDFLAGS) \ + $(Q)$(CXX) -o $@ $^ $(pstoqpdl_CXXFLAGS) $(pstoqpdl_LDFLAGS) \ $(pstoqpdl_LIBS) .PHONY: install installcms diff --git a/src/algo0x0d.cpp b/src/algo0x0d.cpp index 5489886..6514999 100644 --- a/src/algo0x0d.cpp +++ b/src/algo0x0d.cpp @@ -448,7 +448,7 @@ /* Zero value byte padding for data size alignment to 4-byte boundary. */ unsigned long zerosPad = 4 - ( outputSize % 4 ); - /* Pad anyway even if aready aligned. */ + /* Pad anyway even if already aligned. */ if ( outputSize + zerosPad <= maximumBufferSize ) { while ( zerosPad-- ) { output[ outputSize++ ] = 0; diff --git a/src/cache.cpp b/src/cache.cpp index 0602630..8a6a310 100644 --- a/src/cache.cpp +++ b/src/cache.cpp @@ -569,7 +569,7 @@ if (!_tempFile) { ERRORMSG(_("Trying to restore a page instance into memory which is " - "aready into memory")); + "already into memory")); return false; } diff --git a/src/qpdl.cpp b/src/qpdl.cpp index 994e1c8..a95f361 100644 --- a/src/qpdl.cpp +++ b/src/qpdl.cpp @@ -132,7 +132,7 @@ { unsigned long version, subVersion, size, dataSize, checkSum; bool color, headerSent=false; - unsigned char header[0x20]; + unsigned char header[0x20] __attribute__((aligned(4))); const BandPlane *plane; version = request.printer()->qpdlVersion();