Page MenuHome GnuPG

nPth fails to compile
Closed, ResolvedPublic

Description

I'm working on one of my older test machines. It is Fedora 1, i686 with GCC 3.3. I keep it around for testing with the ancient compiler and toolchain. The toolchain only provides SSSE3 support.

nPth is failing to compile.

gmake  all-recursive
gmake[1]: Entering directory `/home/build/npth-1.6'
Making all in src
gmake[2]: Entering directory `/home/build/npth-1.6/src'
/bin/sh ../libtool  --tag=CC   --mode=compile gcc -DHAVE_CONFIG_H -I. -I..   -I/usr/local/include -DNDEBUG  -g2 -O2 -m32 -fPIC -MT npth.lo -MD -MP -MF .deps/npth.Tpo -c -o npth.lo npth.c
/bin/sh ../libtool  --tag=CC   --mode=compile gcc -DHAVE_CONFIG_H -I. -I..   -I/usr/local/include -DNDEBUG  -g2 -O2 -m32 -fPIC -MT npth-sigev.lo -MD -MP -MF .deps/npth-sigev.Tpo -c -o npth-sigev.lo npth-sigev.c
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -I.. -I/usr/local/include -DNDEBUG -g2 -O2 -m32 -fPIC -MT npth.lo -MD -MP -MF .deps/npth.Tpo -c npth.c  -fPIC -DPIC -o .libs/npth.o
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -I.. -I/usr/local/include -DNDEBUG -g2 -O2 -m32 -fPIC -MT npth-sigev.lo -MD -MP -MF .deps/npth-sigev.Tpo -c npth-sigev.c  -fPIC -DPIC -o .libs/npth-sigev.o
mv -f .deps/npth.Tpo .deps/npth.Plo
mv -f .deps/npth-sigev.Tpo .deps/npth-sigev.Plo
/bin/sh ../libtool  --tag=CC   --mode=link gcc  -g2 -O2 -m32 -fPIC   -Wl,--version-script=./libnpth.vers -version-info 1:2:1 -L/usr/local/lib -m32 -Wl,-R,/usr/local/lib -Wl,--enable-new-dtags -o libnpth.la -rpath /usr/local/lib npth.lo npth-sigev.lo  -ldl -lpthread
libtool: link: gcc -shared  -fPIC -DPIC  .libs/npth.o .libs/npth-sigev.o   -L/usr/local/lib -ldl -lpthread  -O2 -m32 -Wl,--version-script=./libnpth.vers -m32 -Wl,-R -Wl,/usr/local/lib -Wl,--enable-new-dtags   -Wl,-soname -Wl,libnpth.so.0 -o .libs/libnpth.so.0.1.2
libtool: link: (cd ".libs" && rm -f "libnpth.so.0" && ln -s "libnpth.so.0.1.2" "libnpth.so.0")
libtool: link: (cd ".libs" && rm -f "libnpth.so" && ln -s "libnpth.so.0.1.2" "libnpth.so")
libtool: link: ( cd ".libs" && rm -f "libnpth.la" && ln -s "../libnpth.la" "libnpth.la" )
gmake[2]: Leaving directory `/home/build/npth-1.6/src'
Making all in tests
gmake[2]: Entering directory `/home/build/npth-1.6/tests'
gcc -DHAVE_CONFIG_H -I. -I..  -I../src -D_POSIX_C_SOURCE=200112L -I/usr/local/include -DNDEBUG  -g2 -O2 -m32 -fPIC -MT t-mutex.o -MD -MP -MF .deps/t-mutex.Tpo -c -o t-mutex.o t-mutex.c
gcc -DHAVE_CONFIG_H -I. -I..  -I../src -D_POSIX_C_SOURCE=200112L -I/usr/local/include -DNDEBUG  -g2 -O2 -m32 -fPIC -MT t-thread.o -MD -MP -MF .deps/t-thread.Tpo -c -o t-thread.o t-thread.c
gcc -DHAVE_CONFIG_H -I. -I..  -I../src -D_POSIX_C_SOURCE=200112L -I/usr/local/include -DNDEBUG  -g2 -O2 -m32 -fPIC -MT t-fork.o -MD -MP -MF .deps/t-fork.Tpo -c -o t-fork.o t-fork.c
In file included from t-support.h:18,
                 from t-fork.c:16:
../src/npth.h:270: error: syntax error before "npth_rwlock_t"
../src/npth.h:270: warning: data definition has no type or storage class
../src/npth.h:275: error: syntax error before '*' token
../src/npth.h:277: error: syntax error before '*' token
../src/npth.h:281: error: syntax error before '*' token
../src/npth.h:282: error: syntax error before '*' token
gmake[2]: *** [t-fork.o] Error 1
gmake[2]: *** Waiting for unfinished jobs....
In file included from t-support.h:18,
                 from t-mutex.c:13:
../src/npth.h:270: error: syntax error before "npth_rwlock_t"
../src/npth.h:270: warning: data definition has no type or storage class
../src/npth.h:275: error: syntax error before '*' token
../src/npth.h:277: error: syntax error before '*' token
../src/npth.h:281: error: syntax error before '*' token
../src/npth.h:282: error: syntax error before '*' token
gmake[2]: *** [t-mutex.o] Error 1
In file included from t-support.h:18,
                 from t-thread.c:13:
../src/npth.h:270: error: syntax error before "npth_rwlock_t"
../src/npth.h:270: warning: data definition has no type or storage class
../src/npth.h:275: error: syntax error before '*' token
../src/npth.h:277: error: syntax error before '*' token
../src/npth.h:281: error: syntax error before '*' token
../src/npth.h:282: error: syntax error before '*' token
gmake[2]: *** [t-thread.o] Error 1
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory `/home/build/npth-1.6'
gmake: *** [all] Error 2
Failed to build npth

Related Objects

Event Timeline

JW created this object in space S1 Public.
gniibe triaged this task as Normal priority.
gniibe added a subscriber: gniibe.

OK, it's a libc with no pthread_rwlock_t.

Could you please test this change for the master in repo?
You need automake, autoconf, etc., and need to invoke autogen.sh after applying the patch.

I leave Android things untouched, for now.