Archive for the ‘daemontools’ tag
Fix nasty compile error while compiling DJBware
If you are compiling daemontools on ubuntu and you get:
<snip>
./compile subgetopt.c ./choose cl trywaitp haswaitp.h1 haswaitp.h2 > haswaitp.h ./compile wait_nohang.c ./compile wait_pid.c ./makelib unix.a alloc.o alloc_re.o buffer.o buffer_0.o buffer_1.o \ buffer_2.o buffer_get.o buffer_put.o buffer_read.o buffer_write.o \ coe.o env.o error.o error_str.o fd_copy.o fd_move.o fifo.o lock_ex.o \ lock_exnb.o ndelay_off.o ndelay_on.o open_append.o open_read.o \ open_trunc.o open_write.o openreadclose.o pathexec_env.o \ pathexec_run.o prot.o readclose.o seek_set.o sgetopt.o sig.o \ sig_block.o sig_catch.o sig_pause.o stralloc_cat.o stralloc_catb.o \ stralloc_cats.o stralloc_eady.o stralloc_opyb.o stralloc_opys.o \ stralloc_pend.o strerr_die.o strerr_sys.o subgetopt.o wait_nohang.o \ wait_pid.o ./load envdir unix.a byte.a collect2: ld terminated with signal 11 [Segmentation fault] /usr/bin/ld: make: *** [envdir] Error 1 Copying commands into ./command... cp: cannot stat `compile/svscan': No such file or directory
</snip>
OR you are trying to compile ucspi-tcp and you get an error like one below:
<snip>
./compile str_start.c ./compile uint16_pack.c ./compile uint16_unpack.c ./compile uint32_pack.c ./compile uint32_unpack.c ./makelib byte.a byte_chr.o byte_copy.o byte_cr.o \ byte_diff.o byte_rchr.o byte_zero.o case_diffb.o \ case_diffs.o fmt_ulong.o ip4_fmt.o ip4_scan.o scan_ulong.o \ str_chr.o str_diff.o str_len.o str_start.o uint16_pack.o \ uint16_unpack.o uint32_pack.o uint32_unpack.o ( ( ./compile trylsock.c && \ ./load trylsock -lsocket -lnsl ) >/dev/null 2>&1 \ && echo -lsocket -lnsl || exit 0 ) > socket.lib rm -f trylsock.o trylsock ./load tcpserver rules.o remoteinfo.o timeoutconn.o cdb.a \ dns.a time.a unix.a byte.a `cat socket.lib` collect2: ld terminated with signal 11 [Segmentation fault] /usr/bin/ld: make: *** [tcpserver] Error 1
Edit src/error.h in daemontools or error.h in ucspi-tcp and remove the line
extern int errno;
replace it with
#include <errno.h>
and recompile it.