Source: abyss Version: 2.1.5-3 Severity: important SUMMARY: abyss fails to build on hurd due to missing header file
DISCOVERY: Build log of abyss-2.1.5-3 on mahler.debian.net (2019-01-09 22:47:19): https://buildd.debian.org/status/fetch.php?pkg=abyss&arch=hurd-i386&ver=2.1.5-3&stamp=1547074039&raw=0 DESCRIPTION: Abyss-2.1.5-3 gives the build error: ../Common/MemoryUtil.h:11:11: fatal error: mach/task.h: No such file or directory It seems that this is due to an out-of-date usage of mach include files and possibly also linking with mach. CONTEXT: On the exodar GNU/hurd emulation: $ uname -a GNU exodar 0.9 GNU-Mach 1.8+git20181103-486-dbg/Hurd-0.9 i686-AT386 GNU $ cat /proc/hostinfo Basic info: max_cpus = 1 /* max number of cpus possible */ avail_cpus = 1 /* number of cpus now available */ memory_size = 3221151744 /* size of memory in bytes */ cpu_type = 19 /* cpu type */ cpu_subtype = 1 /* cpu subtype */ Scheduling info: min_timeout = 10 /* minimum timeout in milliseconds */ min_quantum = 100 /* minimum quantum in milliseconds */ Load info: avenrun[3] = { 0.10, 0.28, 0.60 } mach_factor[3] = { 0.89, 0.81, 0.64 } $ dpkg -l |egrep "abyss|gcc|g\+\+" ii g++ 4:8.2.0-2 hurd-i386 GNU C++ compiler ii g++-8 8.2.0-14 hurd-i386 GNU C++ compiler ii gcc 4:8.2.0-2 hurd-i386 GNU C compiler ii gcc-8 8.2.0-14 hurd-i386 GNU C compiler ii gcc-8-base:hurd-i386 8.2.0-14 hurd-i386 GCC, the GNU Compiler Collection (base package) ii libgcc-8-dev:hurd-i386 8.2.0-14 hurd-i386 GCC support library (development files) ii libgcc1:hurd-i386 1:8.2.0-14 hurd-i386 GCC support library REPRODUCE: On exodar: $ apt-get source abyss $ apt-get build-dep abyss $ cd abyss-2.1.5 $ fakeroot debian/rules binary ... g++ -Wall -Wextra -fopenmp -g -O2 -fdebug-prefix-map=/home/boud-guest/abyss-2.1.5=. -fstack-protector-strong -Wformat -Werror=format-security -DGTEST_USE_OWN_TR1_TUPLE=0 -Wl,-z,relro -Wl,-z,now -o abyss-align abyss_align-align.o ./libalign.a ../dialign/libdialign.a ../DataLayer/libdatalayer.a ../Common/libcommon.a -ldl -lm g++ -DHAVE_CONFIG_H -I. -I.. -I.. -I../Common -I../DataLayer -I/home/boud-guest/abyss-2.1.5 -Wdate-time -D_FORTIFY_SOURCE=2 -isystem/home/boud-guest/abyss-2.1.5/boost_1_56_0 -Wall -Wextra -fopenmp -g -O2 -fdebug-prefix-map=/home/boud-guest/abyss-2.1.5=. -fstack-protector-strong -Wformat -Werror=format-security -DGTEST_USE_OWN_TR1_TUPLE=0 -c -o abyss_mergepairs-mergepairs.o `test -f 'mergepairs.cc' || echo './'`mergepairs.cc g++ -Wall -Wextra -fopenmp -g -O2 -fdebug-prefix-map=/home/boud-guest/abyss-2.1.5=. -fstack-protector-strong -Wformat -Werror=format-security -DGTEST_USE_OWN_TR1_TUPLE=0 -Wl,-z,relro -Wl,-z,now -o abyss-mergepairs abyss_mergepairs-mergepairs.o ./libalign.a ../dialign/libdialign.a ../DataLayer/libdatalayer.a ../Common/libcommon.a -ldl -lm make[4]: Leaving directory '/home/boud-guest/abyss-2.1.5/Align' Making all in ABYSS make[4]: Entering directory '/home/boud-guest/abyss-2.1.5/ABYSS' g++ -DHAVE_CONFIG_H -I. -I.. -I.. -I/home/boud-guest/abyss-2.1.5 -Wdate-time -D_FORTIFY_SOURCE=2 -isystem/home/boud-guest/abyss-2.1.5/boost_1_56_0 -Wall -Wextra -g -O2 -fdebug-prefix-map=/home/boud-guest/abyss-2.1.5=. -fstack-protector-strong -Wformat -Werror=format-security -DGTEST_USE_OWN_TR1_TUPLE=0 -c -o ABYSS-abyss.o `test -f 'abyss.cc' || echo './'`abyss.cc In file included from ../Assembly/DBG.h:7, from ../Assembly/SequenceCollection.h:22, from abyss.cc:5: ../Common/MemoryUtil.h:11:11: fatal error: mach/task.h: No such file or directory # include <mach/task.h> // for task_info ^~~~~~~~~~~~~ compilation terminated. Makefile:410: recipe for target 'ABYSS-abyss.o' failed make[4]: *** [ABYSS-abyss.o] Error 1 HYPOTHESES FOR FIXING: Without knowing details of hurd/mach: (1) My first guess was that <mach/task_info.h> should be included instead of <mach/task.h>, but some other updates look like they're needed too. Making this replacement in Common/MemoryUtil.h and changing nothing else gives: g++ -Wall -Wextra -g -O2 -fdebug-prefix-map=/home/boud-guest/abyss-2.1.5=. -fstack-protector-strong -Wformat -Werror=format-security -DGTEST_USE_OWN_TR1_TUPLE=0 -Wl,-z,relro -Wl,-z,now -o ABYSS ABYSS-abyss.o ../DataBase/libdb.a -lsqlite3 -ldl -lm ../Assembly/libassembly.a ../DataLayer/libdatalayer.a ../Common/libcommon.a -ldl -lm /usr/bin/ld: ABYSS-abyss.o: in function `getMemoryUsage': ./ABYSS/../Common/MemoryUtil.h:22: undefined reference to `task_info(unsigned long, int, int*, unsigned int*)' collect2: error: ld returned 1 exit status Makefile:372: recipe for target 'ABYSS' failed make[4]: *** [ABYSS] Error 1 (2) Trying <mach.h> instead of both <mach/mach.h> and <mach/task.h>, and putting '__task_info' instead of 'task_info', with both of these changes in Common/MemoryUtil.h and modifying no other files, gives: g++ -Wall -Wextra -g -O2 -fdebug-prefix-map=/home/boud-guest/abyss-2.1.5=. -fstack-protector-strong -Wformat -Werror=format-security -DGTEST_USE_OWN_TR1_TUPLE=0 -Wl,-z,relro -Wl,-z,now -o ABYSS ABYSS-abyss.o ../DataBase/libdb.a -lsqlite3 -ldl -lm ../Assembly/libassembly.a ../DataLayer/libdatalayer.a ../Common/libcommon.a -ldl -lm /usr/bin/ld: ABYSS-abyss.o: in function `getMemoryUsage': ./ABYSS/../Common/MemoryUtil.h:22: undefined reference to `__task_info(unsigned long, int, int*, unsigned int*)' collect2: error: ld returned 1 exit status Makefile:372: recipe for target 'ABYSS' failed make[4]: *** [ABYSS] Error 1 (3) It looks like including only <mach.h> should automatically include /usr/include/mach/mach_interface.h>, which includes a prototype for kern_return_t __task_info( ... ) but g++ doesn't find this when linking. Does g++ have something missing when linking to code created with mach-specific extensions? COMMENT: Since this software looks like it caters specifically to Mach, it would be a pity not to update this to the current recommended usage of Mach.