summaryrefslogtreecommitdiff
path: root/debian/patches
diff options
context:
space:
mode:
Diffstat (limited to 'debian/patches')
-rw-r--r--debian/patches/0001_jam.patch143
-rw-r--r--debian/patches/0100_spelling.patch712
-rw-r--r--debian/patches/0105_dispwin_segfault.patch20
-rw-r--r--debian/patches/0110_usb-db_new.patch19
-rw-r--r--debian/patches/0115_hurd_PATH_MAX.patch81
-rw-r--r--debian/patches/0120_kfreebsd.patch55
-rw-r--r--debian/patches/0125_gcc5.patch20
-rw-r--r--debian/patches/series7
8 files changed, 1057 insertions, 0 deletions
diff --git a/debian/patches/0001_jam.patch b/debian/patches/0001_jam.patch
new file mode 100644
index 0000000..251f61f
--- /dev/null
+++ b/debian/patches/0001_jam.patch
@@ -0,0 +1,143 @@
+Description: Add multiarch support to jam files
+Author: Jörg Frings Fürst <debian@jff-webhosting.net>
+Forwarded: http://www.freelists.org/post/argyllcms/Some-buildsystem-issues
+Last-Update: 2015-08-23
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+Index: trunk/Jambase
+===================================================================
+--- trunk.orig/Jambase
++++ trunk/Jambase
+@@ -941,7 +941,7 @@ else if $(UNIX)
+
+ # UNIX defaults
+
+- CCFLAGS ?= -DUNIX -D_THREAD_SAFE -pipe ;
++ CCFLAGS ?= $(CPPFLAGS) -g -DUNIX -D_THREAD_SAFE -pipe ;
+ CCOPTFLAG ?= -O2 ;
+ CCDEBUGFLAG ?= -g ;
+ CCPROFFLAG ?= ;
+@@ -951,7 +951,7 @@ else if $(UNIX)
+ CHGRP ?= chgrp ;
+ CHOWN ?= chown ;
+ LEX ?= lex ;
+- LINKFLAGS ?= ;
++ LINKFLAGS ?= $(LDFLAGS) ;
+ LINKOPTFLAG ?= -O ; # Affects creating .so's
+ LINKSTRIPFLAG ?= -s ;
+ LINKDEBUGFLAG ?= ;
+@@ -1037,7 +1037,7 @@ else if $(UNIX)
+ RMDIR ?= $(RM) ;
+ RSH ?= rsh ;
+ SED ?= sed ;
+- SHELLHEADER ?= "#!/bin/sh" ;
++ SHELLHEADER ?= "#!/bin/bash" ;
+ SHELLMODE ?= 755 ;
+ SLASH ?= / ;
+ STDHDRS ?= /usr/include ;
+Index: trunk/Jamtop
+===================================================================
+--- trunk.orig/Jamtop
++++ trunk/Jamtop
+@@ -23,6 +23,7 @@ ANCHORED_PATH_VARS = DESTDIR ;
+ # Should we also allow CFLAGS, CXXFLAGS, CPPFLAGS & LDFLAGS env. variables
+ # to have effect ?
+
++BUILD_SHARED_LIB = 1 ;
+
+ # Tell standalone libraries that they are part of Argyll:
+ DEFINES += ARGYLLCMS ;
+@@ -139,17 +140,82 @@ rule CheckForLibrary {
+ }
+
+ if ! $(BUILTIN_$(UCASE)) && $(UNIX) {
+- if [ GLOB /usr/include$(subd) : $(lcase).h $(lcase)lib.h ]
+- || [ GLOB /usr/local/include$(subd) : $(lcase).h $(lcase)lib.h ]
+- || [ GLOB /usr/include/x86_64-linux-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
+- || [ GLOB /usr/include/i386-linux-gnu$(subd) : $(lcase).h $(lcase)lib.h ] {
+- if [ GLOB /usr/lib : lib$(lcase).so ] || [ GLOB /usr/lib : lib$(lcase).a ]
+- || [ GLOB /usr/local/lib : lib$(lcase).so ] || [ GLOB /usr/local/lib : lib$(lcase).a ]
+- || [ GLOB /usr/lib64 : lib$(lcase).so ] || [ GLOB /usr/lib64 : lib$(lcase).a ]
+- || [ GLOB /usr/lib/x86_64-linux-gnu : lib$(lcase).so ]
+- || [ GLOB /usr/lib/x86_64-linux-gnu : lib$(lcase).a ]
+- || [ GLOB /usr/lib/i386-linux-gnu : lib$(lcase).so ]
+- || [ GLOB /usr/lib/i386-linux-gnu : lib$(lcase).a ] {
++ if [ GLOB /usr/include$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/local/include$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/x86_64-linux-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/i386-linux-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/alpha-linux-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/aarch64-linux-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/arm-linux-gnueabi$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/arm-linux-gnueabihf$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/hppa-linux-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/i386-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/x86_64-kfreebsd-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/i386-kfreebsd-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/m68k-linux-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/mips-linux-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/mipsel-linux-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/mips64el-linux-gnuabi64$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/powerpc-linux-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/powerpc-linux-gnuspe$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/powerpc64-linux-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/powerpc64le-linux-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/s390x-linux-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/sh4-linux-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/sparc-linux-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/sparc64-linux-gnu$(subd) : $(lcase).h $(lcase)lib.h ]
++ || [ GLOB /usr/include/x86_64-linux-gnux32$(subd) : $(lcase).h $(lcase)lib.h ] {
++ if [ GLOB /usr/lib : lib$(lcase).so ] || [ GLOB /usr/lib : lib$(lcase).a ]
++ || [ GLOB /usr/local/lib : lib$(lcase).so ]
++ || [ GLOB /usr/local/lib : lib$(lcase).a ]
++ || [ GLOB /usr/lib64 : lib$(lcase).so ]
++ || [ GLOB /usr/lib64 : lib$(lcase).a ]
++ || [ GLOB /usr/lib/x86_64-linux-gnu : lib$(lcase).so ]
++ || [ GLOB /usr/lib/x86_64-linux-gnu : lib$(lcase).a ]
++ || [ GLOB /usr/lib/i386-linux-gnu : lib$(lcase).so ]
++ || [ GLOB /usr/lib/i386-linux-gnu : lib$(lcase).a ]
++ || [ GLOB /usr/lib/alpha-linux-gnu : lib$(lcase).so ]
++ || [ GLOB /usr/lib/alpha-linux-gnu : lib$(lcase).a ]
++ || [ GLOB /usr/lib/aarch64-linux-gnu : lib$(lcase).so ]
++ || [ GLOB /usr/lib/aarch64-linux-gnu : lib$(lcase).a ]
++ || [ GLOB /usr/lib/arm-linux-gnueabi : lib$(lcase).so ]
++ || [ GLOB /usr/lib/arm-linux-gnueabi : lib$(lcase).a ]
++ || [ GLOB /usr/lib/arm-linux-gnueabihf : lib$(lcase).so ]
++ || [ GLOB /usr/lib/arm-linux-gnueabihf : lib$(lcase).a ]
++ || [ GLOB /usr/lib/hppa-linux-gnu : lib$(lcase).so ]
++ || [ GLOB /usr/lib/hppa-linux-gnu : lib$(lcase).a ]
++ || [ GLOB /usr/lib/i386-gnu : lib$(lcase).so ]
++ || [ GLOB /usr/lib/i386-gnu : lib$(lcase).a ]
++ || [ GLOB /usr/lib/x86_64-kfreebsd-gnu : lib$(lcase).so ]
++ || [ GLOB /usr/lib/x86_64-kfreebsd-gnu : lib$(lcase).a ]
++ || [ GLOB /usr/lib/i386-kfreebsd-gnu : lib$(lcase).so ]
++ || [ GLOB /usr/lib/i386-kfreebsd-gnu : lib$(lcase).a ]
++ || [ GLOB /usr/lib/m68k-linux-gnu : lib$(lcase).so ]
++ || [ GLOB /usr/lib/m68k-linux-gnu : lib$(lcase).a ]
++ || [ GLOB /usr/lib/mips-linux-gnu : lib$(lcase).so ]
++ || [ GLOB /usr/lib/mips-linux-gnu : lib$(lcase).a ]
++ || [ GLOB /usr/lib/mipsel-linux-gnu : lib$(lcase).so ]
++ || [ GLOB /usr/lib/mipsel-linux-gnu : lib$(lcase).a ]
++ || [ GLOB /usr/lib/mips64el-linux-gnuabi64 : lib$(lcase).so ]
++ || [ GLOB /usr/lib/mips64el-linux-gnuabi64 : lib$(lcase).a ]
++ || [ GLOB /usr/lib/powerpc-linux-gnu : lib$(lcase).so ]
++ || [ GLOB /usr/lib/powerpc-linux-gnu : lib$(lcase).a ]
++ || [ GLOB /usr/lib/powerpc-linux-gnuspe : lib$(lcase).so ]
++ || [ GLOB /usr/lib/powerpc-linux-gnuspe : lib$(lcase).a ]
++ || [ GLOB /usr/lib/powerpc64-linux-gnu : lib$(lcase).so ]
++ || [ GLOB /usr/lib/powerpc64-linux-gnu : lib$(lcase).a ]
++ || [ GLOB /usr/lib/powerpc64le-linux-gnu : lib$(lcase).so ]
++ || [ GLOB /usr/lib/powerpc64le-linux-gnu : lib$(lcase).a ]
++ || [ GLOB /usr/lib/s390x-linux-gnu : lib$(lcase).so ]
++ || [ GLOB /usr/lib/s390x-linux-gnu : lib$(lcase).a ]
++ || [ GLOB /usr/lib/sh4-linux-gnu : lib$(lcase).so ]
++ || [ GLOB /usr/lib/sh4-linux-gnu : lib$(lcase).a ]
++ || [ GLOB /usr/lib/sparc-linux-gnu : lib$(lcase).so ]
++ || [ GLOB /usr/lib/sparc-linux-gnu : lib$(lcase).a ]
++ || [ GLOB /usr/lib/sparc64-linux-gnu : lib$(lcase).so ]
++ || [ GLOB /usr/lib/sparc64-linux-gnu : lib$(lcase).a ]
++ || [ GLOB /usr/lib/x86_64-linux-gnux32 : lib$(lcase).so ]
++ || [ GLOB /usr/lib/x86_64-linux-gnux32 : lib$(lcase).a ] {
+ echo "Using system $(UCASE) library" ;
+ $(UCASE)LIB = ;
+ $(UCASE)INC = ;
diff --git a/debian/patches/0100_spelling.patch b/debian/patches/0100_spelling.patch
new file mode 100644
index 0000000..5b57b5c
--- /dev/null
+++ b/debian/patches/0100_spelling.patch
@@ -0,0 +1,712 @@
+Description: correct some typos
+Author: Jörg Frings-Fürst <debian@jff-webhosting.net>
+Last-Update: 2015-09-30
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+Index: trunk/spectro/dispcal.c
+===================================================================
+--- trunk.orig/spectro/dispcal.c
++++ trunk/spectro/dispcal.c
+@@ -1937,7 +1937,7 @@ int main(int argc, char *argv[]) {
+ /* Serial port flow control */
+ } else if (argv[fa][1] == 'W') {
+ fa = nfa;
+- if (na == NULL) usage(0,"Paramater expected following -W");
++ if (na == NULL) usage(0,"Parameter expected following -W");
+ if (na[0] == 'n' || na[0] == 'N')
+ fc = fc_none;
+ else if (na[0] == 'h' || na[0] == 'H')
+@@ -1960,13 +1960,13 @@ int main(int argc, char *argv[]) {
+ /* Black point correction amount */
+ } else if (argv[fa][1] == 'k') {
+ fa = nfa;
+- if (na == NULL) usage(0,"Paramater expected following -k");
++ if (na == NULL) usage(0,"Parameter expected following -k");
+ bkcorrect = atof(na);
+ if (bkcorrect < 0.0 || bkcorrect > 1.0) usage(0,"-k parameter must be between 0.0 and 1.0");
+ /* Neutral blend rate (power) */
+ } else if (argv[fa][1] == 'A') {
+ fa = nfa;
+- if (na == NULL) usage(0,"Paramater expected following -A");
++ if (na == NULL) usage(0,"Parameter expected following -A");
+ x.nbrate = atof(na);
+ if (x.nbrate < 0.05 || x.nbrate > 20.0) usage(0,"-A parameter must be between 0.05 and 20.0");
+ /* Black brightness */
+@@ -1999,7 +1999,7 @@ int main(int argc, char *argv[]) {
+ /* COM port */
+ } else if (argv[fa][1] == 'c') {
+ fa = nfa;
+- if (na == NULL) usage(0,"Paramater expected following -c");
++ if (na == NULL) usage(0,"Parameter expected following -c");
+ comport = atoi(na);
+ if (comport < 1 || comport > 50) usage(0,"-c parameter %d out of range",comport);
+
+@@ -3063,7 +3063,7 @@ int main(int argc, char *argv[]) {
+ /* Black level adjustment */
+ /* Due to the possibility of the channel offsets not being even, */
+ /* we use the largest of the XYZ values after they have been */
+- /* scaled to be even acording to the white XYZ balance. */
++ /* scaled to be even according to the white XYZ balance. */
+ /* It's safer to set the black level a bit low, and then the */
+ /* calibration curves can bump the low ones up. */
+ if (c == '1') {
+Index: trunk/spectro/spotread.c
+===================================================================
+--- trunk.orig/spectro/spotread.c
++++ trunk/spectro/spotread.c
+@@ -483,7 +483,7 @@ int main(int argc, char *argv[]) {
+ /* COM port */
+ } else if (argv[fa][1] == 'c') {
+ fa = nfa;
+- if (na == NULL) usage("Paramater expected following -c");
++ if (na == NULL) usage("Parameter expected following -c");
+ {
+ comport = atoi(na);
+ if (comport < 1 || comport > 40) usage("-c parameter %d out of range",comport);
+@@ -492,7 +492,7 @@ int main(int argc, char *argv[]) {
+ /* Display type */
+ } else if (argv[fa][1] == 'y') {
+ fa = nfa;
+- if (na == NULL) usage("Paramater expected following -y");
++ if (na == NULL) usage("Parameter expected following -y");
+ dtype = na[0];
+
+ #ifndef SALONEINSTLIB
+@@ -500,7 +500,7 @@ int main(int argc, char *argv[]) {
+ } else if (argv[fa][1] == 'I') {
+
+ fa = nfa;
+- if (na == NULL) usage("Paramater expected following -I");
++ if (na == NULL) usage("Parameter expected following -I");
+ if (strcmp(na, "A") == 0
+ || strcmp(na, "M0") == 0) {
+ tillum_set = spec = 1;
+@@ -539,7 +539,7 @@ int main(int argc, char *argv[]) {
+ /* Spectral Illuminant type for XYZ computation */
+ } else if (argv[fa][1] == 'i') {
+ fa = nfa;
+- if (na == NULL) usage("Paramater expected following -i");
++ if (na == NULL) usage("Parameter expected following -i");
+ if (strcmp(na, "A") == 0) {
+ illum_set = spec = 1;
+ illum = icxIT_A;
+@@ -579,7 +579,7 @@ int main(int argc, char *argv[]) {
+ /* Spectral Observer type */
+ } else if (argv[fa][1] == 'Q') {
+ fa = nfa;
+- if (na == NULL) usage("Paramater expected following -Q");
++ if (na == NULL) usage("Parameter expected following -Q");
+ if (strcmp(na, "1931_2") == 0) { /* Classic 2 degree */
+ obType = icxOT_CIE_1931_2;
+ } else if (strcmp(na, "1964_10") == 0) { /* Classic 10 degree */
+@@ -657,7 +657,7 @@ int main(int argc, char *argv[]) {
+ /* Filter configuration */
+ } else if (argv[fa][1] == 'F') {
+ fa = nfa;
+- if (na == NULL) usage("Paramater expected following -F");
++ if (na == NULL) usage("Parameter expected following -F");
+ if (na[0] == 'n' || na[0] == 'N')
+ fe = inst_opt_filter_none;
+ else if (na[0] == 'p' || na[0] == 'P')
+@@ -672,7 +672,7 @@ int main(int argc, char *argv[]) {
+ /* Extra filter compensation file */
+ } else if (argv[fa][1] == 'E') {
+ fa = nfa;
+- if (na == NULL) usage("Paramater expected following -E");
++ if (na == NULL) usage("Parameter expected following -E");
+ strncpy(filtername,na,MAXNAMEL-1); filtername[MAXNAMEL-1] = '\000';
+
+ /* Show Yxy */
+Index: trunk/spectro/colorhug.c
+===================================================================
+--- trunk.orig/spectro/colorhug.c
++++ trunk/spectro/colorhug.c
+@@ -212,7 +212,7 @@ colorhug_command(colorhug *p,
+
+ a1logd(p->log,8,"colorhug_command: Read %d bytes and %d read\n",xrbytes,rbytes);
+ if (rbytes >= 2) {
+- a1logd(p->log,6,"colorhug_command: recieved cmd '%s' error '%s' args '%s'\n",
++ a1logd(p->log,6,"colorhug_command: received cmd '%s' error '%s' args '%s'\n",
+ inst_desc(buf[1]),
+ colorhug_interp_error((inst *) p, buf[0]),
+ icoms_tohex(buf, rbytes - 2));
+Index: trunk/spectro/dispwin.c
+===================================================================
+--- trunk.orig/spectro/dispwin.c
++++ trunk/spectro/dispwin.c
+@@ -2734,7 +2734,7 @@ int dispwin_install_profile(dispwin *p,
+
+ /* Un-Install a display profile */
+ /* Return nz if failed, */
+-/* 1 if not sucessfully deleted */
++/* 1 if not successfully deleted */
+ /* 2 if profile not found */
+ int dispwin_uninstall_profile(dispwin *p, char *fname, p_scope scope) {
+ debugr2((errout,"dispwin_uninstall_profile '%s'\n", fname));
+@@ -5131,7 +5131,7 @@ int ddebug /* >0 to print debug sta
+ p->native = native &= ~2;
+ }
+
+- debugr("new_dispwin: return sucessfully\n");
++ debugr("new_dispwin: return successfully\n");
+ return p;
+ }
+
+Index: trunk/spectro/dtp51.c
+===================================================================
+--- trunk.orig/spectro/dtp51.c
++++ trunk/spectro/dtp51.c
+@@ -679,7 +679,7 @@ dtp51_interp_error(inst *pp, int ec) {
+ case DTP51_INVALID_STEP:
+ return "Invalid step";
+ case DTP51_NO_DATA_AVAILABLE:
+- return "No data availble";
++ return "No data avaialble";
+ case DTP51_LAMP_MARGINAL:
+ return "Lamp marginal";
+ case DTP51_LAMP_FAILURE:
+Index: trunk/spectro/dtp92.c
+===================================================================
+--- trunk.orig/spectro/dtp92.c
++++ trunk/spectro/dtp92.c
+@@ -928,7 +928,7 @@ dtp92_interp_error(inst *pp, int ec) {
+ case DTP92_NO_DATA_AVAILABLE:
+ return "No data available";
+ case DTP92_MISSING_PARAMETER:
+- return "Paramter is missing";
++ return "Parameter is missing";
+ case DTP92_CALIBRATION_DENIED:
+ return "Invalid calibration enable code";
+ case DTP92_NEEDS_OFFSET_CAL:
+Index: trunk/spectro/hidio.c
+===================================================================
+--- trunk.orig/spectro/hidio.c
++++ trunk/spectro/hidio.c
+@@ -739,7 +739,7 @@ icoms_hid_read(icoms *p,
+ {
+ unsigned char *rbuf2;
+
+- /* Create a copy of the data recieved with one more byte */
++ /* Create a copy of the data received with one more byte */
+ if ((rbuf2 = malloc(bsize + 1)) == NULL) {
+ a1loge(p->log, ICOM_SYS, "icoms_hid_read: malloc failed\n");
+ return ICOM_SYS;
+Index: trunk/spectro/huey.c
+===================================================================
+--- trunk.orig/spectro/huey.c
++++ trunk/spectro/huey.c
+@@ -81,7 +81,7 @@ static int icoms2huey_err(int se, int to
+ /* i1Display command codes */
+ /* B = byte (8bit), S = short (16bit), W = word (32bit), A = string */
+ /* U = unused byte, - = no arguments/results */
+-/* The is a 7 byte command buffer and 6 response recieve buffer. */
++/* The is a 7 byte command buffer and 6 response receive buffer. */
+ /* :2 means the read is from a second 8 byte ep x81 read. */
+ /* cbuf[-] is command byte */
+ /* rbuf[-2] is continuation byte */
+Index: trunk/spectro/i1pro_imp.c
+===================================================================
+--- trunk.orig/spectro/i1pro_imp.c
++++ trunk/spectro/i1pro_imp.c
+@@ -3813,7 +3813,7 @@ i1pro_code i1pro_restore_refspot_cal(i1p
+ return I1PRO_OK;
+ }
+
+- /* We've sucessfully restored the dark calibration */
++ /* We've successfully restored the dark calibration */
+ s->dark_valid = 1;
+ s->ddate = m->caldate;
+
+@@ -3858,7 +3858,7 @@ i1pro_code i1pro_restore_refspot_cal(i1p
+ return I1PRO_OK;
+ }
+
+- /* We've sucessfully restored the calibration */
++ /* We've successfully restored the calibration */
+ s->cal_valid = 1;
+ s->cfdate = m->caldate;
+
+Index: trunk/spectro/madvrwin.c
+===================================================================
+--- trunk.orig/spectro/madvrwin.c
++++ trunk/spectro/madvrwin.c
+@@ -593,7 +593,7 @@ int ii = 0;
+ }
+ #endif
+
+- debugr("new_madvrwin: return sucessfully\n");
++ debugr("new_madvrwin: return successfully\n");
+
+ return p;
+ }
+Index: trunk/spectro/ss.c
+===================================================================
+--- trunk.orig/spectro/ss.c
++++ trunk/spectro/ss.c
+@@ -1787,7 +1787,7 @@ ss_interp_error(inst *pp, int ec) {
+ case ss_et_BadHexEncoding:
+ return "Message received from instrument has bad Hex encoding";
+ case ss_et_RecBufferOverun:
+- return "Message received from instrument would overflow recieve buffer";
++ return "Message received from instrument would overflow receive buffer";
+ default:
+ return "Unknown error code";
+ }
+Index: trunk/spectro/ss_imp.c
+===================================================================
+--- trunk.orig/spectro/ss_imp.c
++++ trunk/spectro/ss_imp.c
+@@ -216,7 +216,7 @@ static int h2b(ss *p, char c) {
+ return 0;
+ }
+
+-/* Return the first enum from the recieve buffer without removing it. */
++/* Return the first enum from the receive buffer without removing it. */
+ int ss_peek_ans(ss *p) {
+ int rv;
+
+Index: trunk/spectro/webwin.c
+===================================================================
+--- trunk.orig/spectro/webwin.c
++++ trunk/spectro/webwin.c
+@@ -396,7 +396,7 @@ int ddebug /* >0 to print debug sta
+ msec_sleep(50);
+ }
+
+- debugr("new_webwin: return sucessfully\n");
++ debugr("new_webwin: return successfully\n");
+
+ return p;
+ }
+Index: trunk/xicc/cv.c
+===================================================================
+--- trunk.orig/xicc/cv.c
++++ trunk/xicc/cv.c
+@@ -101,7 +101,7 @@ main(int argc, char *argv[]) {
+
+ printf("There are %d parameters:\n",np); fflush(stdout);
+ for (i = 0; i < np; i++) {
+- printf("Paramter %d = %f\n",i, params[i]); fflush(stdout);
++ printf("Parameter %d = %f\n",i, params[i]); fflush(stdout);
+ }
+
+ /* Display the result */
+Index: trunk/spectro/ss_imp.h
+===================================================================
+--- trunk.orig/spectro/ss_imp.h
++++ trunk/spectro/ss_imp.h
+@@ -720,7 +720,7 @@ void ss_add_string(struct _ss *p, char *
+ /* - - - - - - - - - - - - - - - - - - - - - */
+ /* ANSWER: */
+
+-/* Return the first enum from the recieve buffer without removing it. */
++/* Return the first enum from the receive buffer without removing it. */
+ int ss_peek_ans(struct _ss *p);
+
+ /* Remove a Spectrolino answer enum from the revieve buffer, */
+Index: trunk/imdi/cctiff.c
+===================================================================
+--- trunk.orig/imdi/cctiff.c
++++ trunk/imdi/cctiff.c
+@@ -36,7 +36,7 @@
+ Add flag to ignore inkname mismatches.
+
+
+- Should add support for transfering any extra alpha
++ Should add support for transferring any extra alpha
+ planes from input to output, rather than simply ignoring them.
+
+
+@@ -1953,11 +1953,11 @@ main(int argc, char *argv[]) {
+
+ if (wh != NULL) {
+ printf("Output TIFF file '%s'\n",out_name);
+- printf("Ouput raster file ICC colorspace is %s\n",icm2str(icmColorSpaceSignature,su.outs));
++ printf("Output raster file ICC colorspace is %s\n",icm2str(icmColorSpaceSignature,su.outs));
+ printf("Output TIFF file photometric is %s\n",Photometric2str(wphotometric));
+ } else {
+ printf("Output JPEG file '%s'\n",out_name);
+- printf("Ouput raster file ICC colorspace is %s\n",icm2str(icmColorSpaceSignature,su.outs));
++ printf("Output raster file ICC colorspace is %s\n",icm2str(icmColorSpaceSignature,su.outs));
+ printf("Output JPEG file colorspace is %s\n",JPEG_cspace2str(wj.jpeg_color_space));
+ if (wdesc != NULL)
+ printf("Output raster file description: '%s'\n",wdesc);
+Index: trunk/imdi/imdi.h
+===================================================================
+--- trunk.orig/imdi/imdi.h
++++ trunk/imdi/imdi.h
+@@ -38,7 +38,7 @@ struct _imdi {
+
+ /* Note that once an imdi is created, multiple can call interp() without */
+ /* interfering with each other, allowing parallel execution. */
+- void (*interp)(struct _imdi *s, void **outp, int outst, /* Ouput pointers and stride */
++ void (*interp)(struct _imdi *s, void **outp, int outst, /* Output pointers and stride */
+ void **inp, int inst, /* Input pointers and stride */
+ unsigned int npixels); /* Number of pixels */
+
+Index: trunk/spectro/munki_imp.c
+===================================================================
+--- trunk.orig/spectro/munki_imp.c
++++ trunk/spectro/munki_imp.c
+@@ -6393,7 +6393,7 @@ munki_code munki_create_hr(munki *p, int
+ int i, j, jj, k, cx, sx;
+ munki_fc coeff[40][16]; /* Existing filter cooefficients */
+ int nwav1; /* Number of filters */
+- double wl_short1, wl_long1; /* Ouput wavelength of first and last filters */
++ double wl_short1, wl_long1; /* Output wavelength of first and last filters */
+ double wl_step1;
+ munki_xp xp[41]; /* Crossover points each side of filter */
+ munki_code ev = MUNKI_OK;
+Index: trunk/target/printtarg.c
+===================================================================
+--- trunk.orig/target/printtarg.c
++++ trunk/target/printtarg.c
+@@ -2209,7 +2209,7 @@ int *p_npat /* Return number of patche
+
+
+ } else {
+- error("Unsupported intrument type");
++ error("Unsupported instrument type");
+ }
+
+ /* Compute page limits */
+@@ -2953,7 +2953,7 @@ char *argv[];
+ double sscale = 1.0; /* Spacer size scale */
+ int rand = 1;
+ int qbits = 0; /* Quantization bits */
+- int oft = 0; /* Ouput File type, 0 = PS, 1 = EPS , 2 = TIFF */
++ int oft = 0; /* Output File type, 0 = PS, 1 = EPS , 2 = TIFF */
+ int nocups = 0; /* Supress CUPS PS/EPS job ticket */
+ depth2d tiffdpth = bpc8_2d; /* TIFF pixel depth */
+ double tiffres = 100.0; /* TIFF resolution in DPI */
+Index: trunk/gamut/nearsmth.c
+===================================================================
+--- trunk.orig/gamut/nearsmth.c
++++ trunk/gamut/nearsmth.c
+@@ -263,7 +263,7 @@ double dxratio /* Depth expansion ratio
+ double va, vr, vd, vv = 0.0;
+
+ /* Absolute, Delta E^2 between test point and destination closest */
+- /* aodv is already positioned acording to the LCh weights, */
++ /* aodv is already positioned according to the LCh weights, */
+ /* so weight as per average of these */
+ a_o = w->a.o;
+ va = wdesq(dtp, aodv, a_o, a_o, a_o, SUM_POW);
+@@ -4067,7 +4067,7 @@ static void create_influence_plot(nearsm
+ swdiag = new_rspl(RSPL_NOFLAGS, 3, 3); /* Allocate 3D -> 3D */
+ swdiag->fit_rspl(swdiag, RSPL_NOFLAGS, fpnts, nmpts, NULL, NULL, gres, NULL, NULL, 1.0, avgdev, NULL);
+
+- /* Now create a plot of the sci_gam with the vertexes colored acording to the */
++ /* Now create a plot of the sci_gam with the vertexes colored according to the */
+ /* diagnostic map. */
+ if ((wrl = new_vrml("sci_gam_wt", 1, vrml_lab)) == NULL) {
+ fprintf(stderr,"gamut map: new_vrml failed for '%s%s'\n","sci_gam_wt",vrm_ext());
+Index: trunk/gamut/nearsmth.h
+===================================================================
+--- trunk.orig/gamut/nearsmth.h
++++ trunk/gamut/nearsmth.h
+@@ -294,7 +294,7 @@ gammapweights *src2, double wgt2,
+ gammapweights *src3, double wgt3
+ );
+
+-/* Tweak weights acording to extra cmy cusp flags or rel override */
++/* Tweak weights according to extra cmy cusp flags or rel override */
+ void tweak_weights(gammapweights out[14], int dst_cmymap, int rel_oride);
+
+ #endif /* NEARSMTH_H */
+Index: trunk/imdi/cctiffo.c
+===================================================================
+--- trunk.orig/imdi/cctiffo.c
++++ trunk/imdi/cctiffo.c
+@@ -307,7 +307,7 @@ int pmtc
+ case PHOTOMETRIC_LOGLUV:
+ return "CIELog2Luv";
+ }
+- sprintf(buf,"Unknonw Tag %d",pmtc);
++ sprintf(buf,"Unknown Tag %d",pmtc);
+ return buf;
+ }
+
+Index: trunk/imdi/greytiff.c
+===================================================================
+--- trunk.orig/imdi/greytiff.c
++++ trunk/imdi/greytiff.c
+@@ -132,7 +132,7 @@ int pmtc
+ case PHOTOMETRIC_LOGLUV:
+ return "CIELog2Luv";
+ }
+- sprintf(buf,"Unknonw Tag %d",pmtc);
++ sprintf(buf,"Unknown Tag %d",pmtc);
+ return buf;
+ }
+
+Index: trunk/link/collink.c
+===================================================================
+--- trunk.orig/link/collink.c
++++ trunk/link/collink.c
+@@ -1111,7 +1111,7 @@ void devip_devop(void *cntx, double *out
+ }
+ /* We've got the input profile PCS' at this point. */
+
+- /* If we're transfering the K value from the input profile to the */
++ /* If we're transferring the K value from the input profile to the */
+ /* output, copy it into locus[], which will be given to the inverse */
+ /* lookup function, else the inverse lookup will generate a K using */
+ /* the curve parameters. */
+@@ -1243,7 +1243,7 @@ void devip_devop(void *cntx, double *out
+ if (p->nhack == 2) {
+ /* Ideally we would create a 4D PCSK -> PCSK gamut mapping */
+ /* to smoothly and accurately cope with the changing source */
+- /* and destination gamuts acording to their degree of "K onlyness". */
++ /* and destination gamuts according to their degree of "K onlyness". */
+ /* In practice we're going to simply interpolated between */
+ /* two extremes: unrestricted gamut and K only black gamut. */
+ double map0[3], map1[3];
+Index: trunk/profile/printcal.c
+===================================================================
+--- trunk.orig/profile/printcal.c
++++ trunk/profile/printcal.c
+@@ -1294,7 +1294,7 @@ int main(int argc, char *argv[]) {
+ icmXYZ2Lab(&wht, wp->Lab, wp->XYZ);
+ }
+
+- /* Sort the channel acording to device value */
++ /* Sort the channel according to device value */
+ /* For a consistent result for identical device values, */
+ /* secondary sort by inverse CIE value */
+ //#define HEAP_COMPARE(A,B) ((A).dev < (B).dev)
+Index: trunk/spectro/dispsup.c
+===================================================================
+--- trunk.orig/spectro/dispsup.c
++++ trunk/spectro/dispsup.c
+@@ -707,7 +707,7 @@ static int disprd_read_imp(
+ scb->serno = p->serno++;
+ scb->msec = msec_time();
+
+- a1logd(p->log,1, "got reading %f %f %f, transfering to col\n",
++ a1logd(p->log,1, "got reading %f %f %f, transferring to col\n",
+ val.XYZ[0], val.XYZ[1], val.XYZ[2]);
+
+ scb->mtype = val.mtype;
+Index: trunk/gamut/gammap.c
+===================================================================
+--- trunk.orig/gamut/gammap.c
++++ trunk/gamut/gammap.c
+@@ -853,7 +853,7 @@ gammap *new_gammap(
+ #endif
+ if (gmi->bph == gmm_clipBP) {
+
+- /* Extend the target black point to accomodate the */
++ /* Extend the target black point to accommodate the */
+ /* bent or clipped destination space L* range */
+ if (fabp[0] < dr_cs_bp[0]) {
+ t = (fabp[0] - dr_cs_wp[0])/(dr_cs_bp[0] - dr_cs_wp[0]);
+Index: trunk/profile/profout.c
+===================================================================
+--- trunk.orig/profile/profout.c
++++ trunk/profile/profout.c
+@@ -1048,7 +1048,7 @@ make_output_icc(
+ if (iccver < icmVersion2_4) {
+ iccver = icmVersion2_4; /* Need 2.4.0 for Display intents */
+ if (verb)
+- fprintf(verbo,"Bumped ICC version to 2.4.0 to accomodate multiple Display intents\n");
++ fprintf(verbo,"Bumped ICC version to 2.4.0 to accommodate multiple Display intents\n");
+ }
+ }
+ if (wr_icco->set_version(wr_icco, iccver) != 0)
+Index: trunk/render/thscreen.c
+===================================================================
+--- trunk.orig/render/thscreen.c
++++ trunk/render/thscreen.c
+@@ -636,7 +636,7 @@ thscreen *new_thscreen(
+ mrang = 65535.0/(t->oelev - 1.0);
+ DBG(("new_thscreen() raw modulation rande = %f\n",mrang));
+
+- /* Modify the modulation range to accomodate any level overlap */
++ /* Modify the modulation range to accommodate any level overlap */
+ if (olap > 0.0 && t->oelev > 2) {
+ mrang = ((t->oelev - 2.0) * olap * mrang + 65535.0)/(t->oelev - 1.0);
+ DBG(("new_thscreen() modulation adjusted for overlap = %f\n",mrang));
+Index: trunk/xicc/xspect.c
+===================================================================
+--- trunk.orig/xicc/xspect.c
++++ trunk/xicc/xspect.c
+@@ -4440,7 +4440,7 @@ void xspect_plot10(xspect *sp, int n) {
+ /* Given an emission spectrum, set the UV output to the given level. */
+ /* The shape of the UV is taken from FWA1_stim, and the level is */
+ /* with respect to the Y of the input spectrum. */
+-/* The output range is extended to accomodate the UV wavelengths */
++/* The output range is extended to accommodate the UV wavelengths */
+ void xsp_setUV(xspect *out, xspect *in, double uvlevel) {
+ int i, xs, xe;
+ double ww, avg;
+Index: trunk/spectro/ccxxmake.c
+===================================================================
+--- trunk.orig/spectro/ccxxmake.c
++++ trunk/spectro/ccxxmake.c
+@@ -398,7 +398,7 @@ int main(int argc, char *argv[]) {
+ /* COM port */
+ } else if (argv[fa][1] == 'c') {
+ fa = nfa;
+- if (na == NULL) usage(0,"Paramater expected following -c");
++ if (na == NULL) usage(0,"Parameter expected following -c");
+ comno = atoi(na);
+ if (comno < 1 || comno > 40) usage(0,"-c parameter %d out of range",comno);
+
+@@ -498,7 +498,7 @@ int main(int argc, char *argv[]) {
+ /* Serial port flow control */
+ } else if (argv[fa][1] == 'W') {
+ fa = nfa;
+- if (na == NULL) usage(0,"Paramater expected following -W");
++ if (na == NULL) usage(0,"Parameter expected following -W");
+ if (na[0] == 'n' || na[0] == 'N')
+ fc = fc_none;
+ else if (na[0] == 'h' || na[0] == 'H')
+@@ -587,7 +587,7 @@ int main(int argc, char *argv[]) {
+ strcat(outname, doccss ? ".ccss" : ".ccmx");
+
+ if (fakeseq && doccss)
+- error("Fake CCSS test not implemeted");
++ error("Fake CCSS test not implemented");
+
+ printf("\n");
+
+Index: trunk/spectro/dispread.c
+===================================================================
+--- trunk.orig/spectro/dispread.c
++++ trunk/spectro/dispread.c
+@@ -413,7 +413,7 @@ int main(int argc, char *argv[]) {
+ /* COM port */
+ } else if (argv[fa][1] == 'c') {
+ fa = nfa;
+- if (na == NULL) usage(0,"Paramater expected following -c");
++ if (na == NULL) usage(0,"Parameter expected following -c");
+ comport = atoi(na);
+ if (comport < 1 || comport > 50) usage(0,"-c parameter %d out of range",comport);
+
+Index: trunk/spectro/fakeread.c
+===================================================================
+--- trunk.orig/spectro/fakeread.c
++++ trunk/spectro/fakeread.c
+@@ -814,7 +814,7 @@ int main(int argc, char *argv[])
+
+ /* We're assuming that the input space has a perfect black point... */
+
+- /* Lookup the ouput black point in XYZ PCS. We're assuming monotonicity.. */
++ /* Lookup the output black point in XYZ PCS. We're assuming monotonicity.. */
+ bp[0] = bp[1] = bp[2] = 0.0;
+ oluo->lookup(oluo, bp, bp);
+
+@@ -827,7 +827,7 @@ int main(int argc, char *argv[])
+ bt1886 == 1 ? egamma : tgamma, bt1886 == 1 ? 1 : 0);
+
+ if (verb)
+- printf("Gamma Curve: Using ouput black offset proportion %f\n",outoprop);
++ printf("Gamma Curve: Using output black offset proportion %f\n",outoprop);
+
+ if (bt1886 == 1) { /* Using effective gamma */
+ if (verb)
+Index: trunk/profile/invprofcheck.c
+===================================================================
+--- trunk.orig/profile/invprofcheck.c
++++ trunk/profile/invprofcheck.c
+@@ -99,7 +99,7 @@ void usage(void) {
+ fprintf(stderr," -k Show CIEDE2000 delta E values\n");
+ fprintf(stderr," -w create %s visualisation (profile%s)\n",vrml_format(),vrml_ext());
+ fprintf(stderr," -x Use %s axes\n",vrml_format());
+- fprintf(stderr," -e Color vectors acording to delta E\n");
++ fprintf(stderr," -e Color vectors according to delta E\n");
+ fprintf(stderr," profile.icm Profile to check\n");
+ exit(1);
+ }
+Index: trunk/profile/profcheck.c
+===================================================================
+--- trunk.orig/profile/profcheck.c
++++ trunk/profile/profcheck.c
+@@ -59,7 +59,7 @@ usage(void) {
+ fprintf(stderr," -w create %s visualisation (iccprofile%s)\n",vrml_format(),vrml_ext());
+ fprintf(stderr," -x Use %s axes\n",vrml_format());
+ fprintf(stderr," -m Make %s lines a minimum of 0.5\n",vrml_format());
+- fprintf(stderr," -e Color vectors acording to delta E\n");
++ fprintf(stderr," -e Color vectors according to delta E\n");
+ fprintf(stderr," -h Plot a histogram of delta E's\n");
+ fprintf(stderr," -s Sort output by delta E\n");
+ fprintf(stderr," -P N.NN Create a pruned .ti3 with points less or equal to N.NN delta E\n");
+Index: trunk/spectro/ccwin.c
+===================================================================
+--- trunk.orig/spectro/ccwin.c
++++ trunk/spectro/ccwin.c
+@@ -827,7 +827,7 @@ int ddebug /* >0 to print debug sta
+ return NULL;
+ }
+
+- debugr2((errout,"new_ccwin: return sucessfully\n"));
++ debugr2((errout,"new_ccwin: return successfully\n"));
+
+ return p;
+ }
+Index: trunk/profile/colverify.c
+===================================================================
+--- trunk.orig/profile/colverify.c
++++ trunk/profile/colverify.c
+@@ -68,7 +68,7 @@ usage(void) {
+ fprintf(stderr," -D Use D50 100.0 as L*a*b* white reference\n");
+ fprintf(stderr," -c Show CIE94 delta E values\n");
+ fprintf(stderr," -k Show CIEDE2000 delta E values\n");
+- fprintf(stderr," -h [hist.txt] Plot a histogram of delta E's [Optionaly save points to .txt]\n");
++ fprintf(stderr," -h [hist.txt] Plot a histogram of delta E's [Optionally save points to .txt]\n");
+ fprintf(stderr," -s Sort patch values by error\n");
+ fprintf(stderr," -w create PCS %s vector visualisation (measured%s)\n",vrml_format(),vrml_ext());
+ fprintf(stderr," -W create PCS %s marker visualisation (measured%s)\n",vrml_format(),vrml_ext());
+Index: trunk/spectro/ex1.c
+===================================================================
+--- trunk.orig/spectro/ex1.c
++++ trunk/spectro/ex1.c
+@@ -1454,7 +1454,7 @@ static void dump_command(ex1 *p, ORD8 *b
+ if (flags & EX1_FLAG_NACK)
+ a1logd(p->log, 0, " Negative acknowldgement response\n");
+ if (flags & EX1_FLAG_EXPTN)
+- a1logd(p->log, 0, " Exception occured\n");
++ a1logd(p->log, 0, " Exception occurred\n");
+ if (flags & EX1_FLAG_PVDEP)
+ a1logd(p->log, 0, " Protocol version is deprecated request\n");
+
+Index: trunk/ccast/ccmes.c
+===================================================================
+--- trunk.orig/ccast/ccmes.c
++++ trunk/ccast/ccmes.c
+@@ -85,7 +85,7 @@ char *ccmessv_emes(ccmessv_err rv) {
+ return "ccmes: connection has been closed";
+ }
+
+- return "Uknown ccmessv error";
++ return "Unknown ccmessv error";
+ }
+
+ #if defined(LOWVERBTRACE) || defined(DEBUG)
+Index: trunk/ccast/ccpacket.c
+===================================================================
+--- trunk.orig/ccast/ccpacket.c
++++ trunk/ccast/ccpacket.c
+@@ -133,7 +133,7 @@ char *ccpacket_emes(ccpacket_err rv) {
+ return "Packet: failed to read message";
+ }
+
+- return "Uknown ccpacket error";
++ return "Unknown ccpacket error";
+ }
+
+ /* Establish an ccpacket connection - implementation */
+Index: trunk/spectro/xdg_bds.c
+===================================================================
+--- trunk.orig/spectro/xdg_bds.c
++++ trunk/spectro/xdg_bds.c
+@@ -863,7 +863,7 @@ char *xdg_errstr(xdg_error er) {
+ case xdg_nohome:
+ return "There is no $HOME";
+ case xdg_noalluserprofile:
+- return "Theres no $ALLUSERSPROFILE is no $ALLUSERSPROFILE";
++ return "There's no $ALLUSERSPROFILE is no $ALLUSERSPROFILE";
+ case xdg_nopath:
+ return "There is no resulting path";
+ case xdg_mallformed:
diff --git a/debian/patches/0105_dispwin_segfault.patch b/debian/patches/0105_dispwin_segfault.patch
new file mode 100644
index 0000000..cfd6eba
--- /dev/null
+++ b/debian/patches/0105_dispwin_segfault.patch
@@ -0,0 +1,20 @@
+Description: Add check for NULL pointer
+Author: Jörg Frings-Fürst <debian@jff-webhsoting.net>
+Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=700253
+Forwarded: http://www.freelists.org/post/argyllcms/dispwin-bad-command-line-option-makes-dispwin-segfault
+Reviewed-by:
+Last-Update: 2015-08-23
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+Index: trunk/spectro/dispwin.c
+===================================================================
+--- trunk.orig/spectro/dispwin.c
++++ trunk/spectro/dispwin.c
+@@ -5556,6 +5556,7 @@ main(int argc, char *argv[]) {
+
+ /* Display number */
+ else if (argv[fa][1] == 'd') {
++ if(na == NULL) usage(0, "-d parameter missing");
+ if (strncmp(na,"web",3) == 0
+ || strncmp(na,"WEB",3) == 0) {
+ webdisp = 8080;
diff --git a/debian/patches/0110_usb-db_new.patch b/debian/patches/0110_usb-db_new.patch
new file mode 100644
index 0000000..f826509
--- /dev/null
+++ b/debian/patches/0110_usb-db_new.patch
@@ -0,0 +1,19 @@
+Description: Use hwdb builtin, instead of the obsolete usb-db in the udev rules.
+Author: Dmitrijs Ledkovs <dmitrij.ledkov@ubuntu.com>
+Bug-Ubuntu: https://bugs.launchpad.net/bugs/1200185
+Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=762887
+Last-Update: 2014-09-26
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+Index: trunk/usb/55-Argyll.rules
+===================================================================
+--- trunk.orig/usb/55-Argyll.rules 2014-09-25 11:10:12.000000000 +0200
++++ trunk/usb/55-Argyll.rules 2014-09-26 14:08:21.067295380 +0200
+@@ -85,6 +85,6 @@
+ ENV{COLOR_MEASUREMENT_DEVICE}=="*?", ENV{ACL_MANAGE}!="*?", MODE="660", GROUP="plugdev"
+
+ # Set ID_VENDOR and ID_MODEL acording to VID and PID
+-TEST=="/lib/udev/usb-db", IMPORT{program}="usb-db %p"
++IMPORT{builtin}="hwdb --subsystem=usb"
+
+ LABEL="argyll_rules_end"
diff --git a/debian/patches/0115_hurd_PATH_MAX.patch b/debian/patches/0115_hurd_PATH_MAX.patch
new file mode 100644
index 0000000..3775edc
--- /dev/null
+++ b/debian/patches/0115_hurd_PATH_MAX.patch
@@ -0,0 +1,81 @@
+Description: Add on hurdi386 missing PATH_MAX
+Author: Jörg Frings-Fürst <debian@jff-webhosting.net>
+Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=762774
+Last-Update: 2014-09-25
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+Index: trunk/numlib/numsup.c
+===================================================================
+--- trunk.orig/numlib/numsup.c
++++ trunk/numlib/numsup.c
+@@ -47,6 +47,10 @@
+
+ /* Globals */
+
++#ifndef PATH_MAX
++#define PATH_MAX 4096
++#endif
++
+ char *exe_path = "\000"; /* Directory executable resides in ('/' dir separator) */
+ //char *error_program = "Unknown"; /* Name to report as responsible for an error */
+
+Index: trunk/spectro/mongoose.c
+===================================================================
+--- trunk.orig/spectro/mongoose.c
++++ trunk/spectro/mongoose.c
+@@ -46,6 +46,10 @@
+ added to /usr/lib/firewalld/services
+ */
+
++#ifndef PATH_MAX
++#define PATH_MAX 4096
++#endif
++
+ #if defined(_WIN32)
+ #define _CRT_SECURE_NO_WARNINGS // Disable deprecation warning in VS2005
+ #else
+Index: trunk/spectro/usbio_lx.c
+===================================================================
+--- trunk.orig/spectro/usbio_lx.c
++++ trunk/spectro/usbio_lx.c
+@@ -33,6 +33,10 @@
+ #define poll_x poll
+ #endif
+
++#ifndef PATH_MAX
++#define PATH_MAX 4096
++#endif
++
+ /* USB descriptors are little endian */
+
+ /* Take a word sized return buffer, and convert it to an unsigned int */
+Index: trunk/spectro/usbio_nt.c
+===================================================================
+--- trunk.orig/spectro/usbio_nt.c
++++ trunk/spectro/usbio_nt.c
+@@ -31,6 +31,10 @@
+ #define LIBUSBW1_PATH_MAX 512
+ #define LIBUSBW1_DEFAULT_TIMEOUT 5000
+
++#ifndef PATH_MAX
++#define PATH_MAX 4096
++#endif
++
+ /* USB descriptors are little endian */
+
+ /* Take a word sized return buffer, and convert it to an unsigned int */
+Index: trunk/spectro/hidio.c
+===================================================================
+--- trunk.orig/spectro/hidio.c
++++ trunk/spectro/hidio.c
+@@ -100,6 +100,10 @@
+ #endif
+ #endif
+
++#ifndef PATH_MAX
++#define PATH_MAX 4096
++#endif
++
+ #if defined(NT)
+
+ /* Declartions to enable HID access without using the DDK */
diff --git a/debian/patches/0120_kfreebsd.patch b/debian/patches/0120_kfreebsd.patch
new file mode 100644
index 0000000..2b4b622
--- /dev/null
+++ b/debian/patches/0120_kfreebsd.patch
@@ -0,0 +1,55 @@
+From: Steven Chamberlain <steven@pyro.eu.org>
+Subject: use FreeBSD USB I/O code on GNU/kFreeBSD
+
+Use the FreeBSD USB I/O code not just on __FreeBSD__ itself,
+but on any system having __FreeBSD_kernel__ (such as GNU/kFreeBSD).
+
+--- a/spectro/usbio.c
++++ b/spectro/usbio.c
+@@ -94,7 +94,7 @@
+ # include "usbio_ox.c"
+ # endif
+ # if defined(UNIX_X11)
+-# if defined(__FreeBSD__)
++# if defined(__FreeBSD_kernel__)
+ # include "usbio_bsd.c"
+ # else
+ # include "usbio_lx.c"
+--- a/spectro/usbio_bsd.c
++++ b/spectro/usbio_bsd.c
+@@ -37,7 +37,7 @@
+ #include <fcntl.h>
+ #include <glob.h>
+ #include <sys/ioctl.h>
+-#if defined(__FreeBSD__)
++#if defined(__FreeBSD_kernel__)
+ # include <dev/usb/usb_ioctl.h> /* Not sure what's going on with FreeBSD... */
+ #else
+ # include <dev/usb/usb.h> /* The usual include for BSD */
+@@ -59,7 +59,7 @@
+ ) {
+ int i, j;
+ char *paths[] = {
+-#if defined(__FreeBSD__)
++#if defined(__FreeBSD_kernel__)
+ "/dev/usb/[0-9]*.*.0", /* FreeBSD >= 8 */
+ "/dev/ugen[0-9]*", /* FreeBSD < 8, but no .E */
+ #else
+@@ -94,7 +94,7 @@
+ /* For all the nodes found by the glob */
+ for (i = 0; i < g.gl_pathc; i++) {
+
+-#if defined(__FreeBSD__)
++#if defined(__FreeBSD_kernel__)
+ /* Skip anything with an end point number */
+ if (j == 1 && strchr(g.gl_pathv[i], '.') != NULL)
+ continue;
+@@ -141,7 +141,7 @@
+
+ /* Create the base device path */
+ dpath = g.gl_pathv[i];
+-#if defined(__FreeBSD__)
++#if defined(__FreeBSD_kernel__)
+ if (j == 0) { /* Remove .0 */
+ if ((cp = strrchr(dpath, '.')) != NULL
+ && cp[1] == '0' && cp[2] == '\000')
diff --git a/debian/patches/0125_gcc5.patch b/debian/patches/0125_gcc5.patch
new file mode 100644
index 0000000..2806745
--- /dev/null
+++ b/debian/patches/0125_gcc5.patch
@@ -0,0 +1,20 @@
+Description: Fix FTBFS with GCC 5
+Author: James Cowgill <james410@cowgill.org.uk>
+Bug-Debian: https://bugs.debian.org/777779
+Forwarded: no
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+--- a/icc/icc.h
++++ b/icc/icc.h
+@@ -100,7 +100,11 @@
+ #define CF64PREC "LL" /* Constant precision specifier */
+
+ #ifndef ATTRIBUTE_NORETURN
++#ifdef _MSC_VER
+ # define ATTRIBUTE_NORETURN __declspec(noreturn)
++#else
++# define ATTRIBUTE_NORETURN __attribute__((noreturn))
++#endif
+ #endif
+
+ #else /* !__STDC_VERSION__ */
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..c9ba163
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1,7 @@
+0105_dispwin_segfault.patch
+0100_spelling.patch
+0001_jam.patch
+0115_hurd_PATH_MAX.patch
+#0110_usb-db_new.patch
+#0120_kfreebsd.patch
+0125_gcc5.patch