After adding -fPIC to the gcc commandline and doing an ebuid ... compile this is the output.....: make -C libcap CC='gcc' CFLAGS='-Dlinux -ansi -D_POSIX_SOURCE -Wall -Wwrite-strings -Wpointer-arith -Wcast-qual -Wcast-align -Wtraditional -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline -Wshadow -pedantic -mcpu=ev56 -O3 -pipe -I/usr/include/python2.2 -I/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap/include -fPIC' LD='ld' LIBS='-L/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap -lcap' LDFLAGS='-s ' VERSION='1' MINOR='10' LIBDIR='/lib' INCDIR='/usr/include' SBINDIR='/sbin' MANDIR='/usr/man' all make[1]: Entering directory `/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap' make[1]: warning: jobserver unavailable: using -j1. Add `+' to parent make rule. gcc -Dlinux -ansi -D_POSIX_SOURCE -Wall -Wwrite-strings -Wpointer-arith -Wcast-qual -Wcast-align -Wtraditional -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline -Wshadow -pedantic -mcpu=ev56 -O3 -pipe -I/usr/include/python2.2 -I/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap/include -fPIC -c cap_alloc.c -o cap_alloc.o In file included from cap_alloc.c:12: libcap.h:57:3: warning: suggest hiding #error from traditional C with an indented # libcap.h:58:3: warning: suggest hiding #error from traditional C with an indented # libcap.h:101:25: warning: ISO C does not permit named variadic macros cap_alloc.c:26:35: warning: ISO C99 requires rest arguments to be used cap_alloc.c:77:34: warning: ISO C99 requires rest arguments to be used cap_alloc.c:84:35: warning: ISO C99 requires rest arguments to be used cap_alloc.c:118:65: warning: ISO C99 requires rest arguments to be used gcc -Dlinux -ansi -D_POSIX_SOURCE -Wall -Wwrite-strings -Wpointer-arith -Wcast-qual -Wcast-align -Wtraditional -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline -Wshadow -pedantic -mcpu=ev56 -O3 -pipe -I/usr/include/python2.2 -I/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap/include -fPIC -c cap_proc.c -o cap_proc.o In file included from cap_proc.c:11: libcap.h:57:3: warning: suggest hiding #error from traditional C with an indented # libcap.h:58:3: warning: suggest hiding #error from traditional C with an indented # libcap.h:101:25: warning: ISO C does not permit named variadic macros cap_proc.c:20:59: warning: ISO C99 requires rest arguments to be used cap_proc.c:40:46: warning: ISO C99 requires rest arguments to be used gcc -Dlinux -ansi -D_POSIX_SOURCE -Wall -Wwrite-strings -Wpointer-arith -Wcast-qual -Wcast-align -Wtraditional -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline -Wshadow -pedantic -mcpu=ev56 -O3 -pipe -I/usr/include/python2.2 -I/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap/include -fPIC -c cap_extint.c -o cap_extint.o In file included from cap_extint.c:12: libcap.h:57:3: warning: suggest hiding #error from traditional C with an indented # libcap.h:58:3: warning: suggest hiding #error from traditional C with an indented # libcap.h:101:25: warning: ISO C does not permit named variadic macros cap_extint.c: In function `cap_copy_int': cap_extint.c:92: warning: `cap_d' might be used uninitialized in this function gcc -Dlinux -ansi -D_POSIX_SOURCE -Wall -Wwrite-strings -Wpointer-arith -Wcast-qual -Wcast-align -Wtraditional -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline -Wshadow -pedantic -mcpu=ev56 -O3 -pipe -I/usr/include/python2.2 -I/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap/include -fPIC -c cap_flag.c -o cap_flag.o In file included from cap_flag.c:12: libcap.h:57:3: warning: suggest hiding #error from traditional C with an indented # libcap.h:58:3: warning: suggest hiding #error from traditional C with an indented # libcap.h:101:25: warning: ISO C does not permit named variadic macros cap_flag.c: In function `cap_get_flag': cap_flag.c:31: warning: cast increases required alignment of target type cap_flag.c:38:39: warning: ISO C99 requires rest arguments to be used cap_flag.c: In function `cap_set_flag': cap_flag.c:68: warning: cast increases required alignment of target type cap_flag.c:81:39: warning: ISO C99 requires rest arguments to be used cap_flag.c:101:37: warning: ISO C99 requires rest arguments to be used gcc -Dlinux -ansi -D_POSIX_SOURCE -Wall -Wwrite-strings -Wpointer-arith -Wcast-qual -Wcast-align -Wtraditional -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline -Wshadow -pedantic -mcpu=ev56 -O3 -pipe -I/usr/include/python2.2 -I/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap/include -fPIC -c cap_text.c -o cap_text.o In file included from cap_text.c:14: libcap.h:57:3: warning: suggest hiding #error from traditional C with an indented # libcap.h:58:3: warning: suggest hiding #error from traditional C with an indented # libcap.h:101:25: warning: ISO C does not permit named variadic macros cap_text.c: In function `lookupname': cap_text.c:62: warning: cast discards qualifiers from pointer target type cap_text.c:86:34: warning: ISO C99 requires rest arguments to be used cap_text.c: In function `cap_from_text': cap_text.c:100: warning: traditional C rejects automatic aggregate initialization cap_text.c:162:63: warning: ISO C99 requires rest arguments to be used cap_text.c:166:38: warning: ISO C99 requires rest arguments to be used cap_text.c:199:66: warning: ISO C99 requires rest arguments to be used cap_text.c:208:33: warning: ISO C99 requires rest arguments to be used cap_text.c: In function `cap_to_text': cap_text.c:243: warning: traditional C rejects automatic aggregate initialization gcc -Dlinux -ansi -D_POSIX_SOURCE -Wall -Wwrite-strings -Wpointer-arith -Wcast-qual -Wcast-align -Wtraditional -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline -Wshadow -pedantic -mcpu=ev56 -O3 -pipe -I/usr/include/python2.2 -I/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap/include -fPIC -c cap_sys.c -o cap_sys.o In file included from cap_sys.c:10: libcap.h:57:3: warning: suggest hiding #error from traditional C with an indented # libcap.h:58:3: warning: suggest hiding #error from traditional C with an indented # libcap.h:101:25: warning: ISO C does not permit named variadic macros ld -soname libcap.so.1 -x -shared -o libcap.so.1.10 cap_alloc.o cap_proc.o cap_extint.o cap_flag.o cap_text.o cap_sys.o ln -sf libcap.so.1.10 libcap.so.1 ln -sf libcap.so.1 libcap.so swig -python -o libcap_wrap.c include/sys/capability.h gcc -Dlinux -ansi -D_POSIX_SOURCE -Wall -Wwrite-strings -Wpointer-arith -Wcast-qual -Wcast-align -Wtraditional -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline -Wshadow -pedantic -mcpu=ev56 -O3 -pipe -I/usr/include/python2.2 -I/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap/include -fPIC -c libcap_wrap.c -o libcap_wrap.o In file included from libcap_wrap.c:13: /usr/include/python2.2/Python.h:44:5: warning: suggest hiding #error from traditional C with an indented # In file included from /usr/include/python2.2/Python.h:62, from libcap_wrap.c:13: /usr/include/python2.2/pyport.h:73:2: warning: suggest not using #elif in traditional C /usr/include/python2.2/pyport.h:77:2: warning: suggest not using #elif in traditional C /usr/include/python2.2/pyport.h:81:2: warning: suggest not using #elif in traditional C /usr/include/python2.2/pyport.h:86:5: warning: suggest hiding #error from traditional C with an indented # /usr/include/python2.2/pyport.h:162:2: warning: suggest not using #elif in traditional C /usr/include/python2.2/pyport.h:459:2: warning: suggest not using #elif in traditional C /usr/include/python2.2/pyport.h:462:2: warning: suggest hiding #error from traditional C with an indented # /usr/include/python2.2/pyport.h:480:2: warning: suggest hiding #error from traditional C with an indented # In file included from /usr/include/python2.2/Python.h:67, from libcap_wrap.c:13: /usr/include/python2.2/objimpl.h:187:5: warning: suggest hiding #error from traditional C with an indented # In file included from /usr/include/python2.2/Python.h:71, from libcap_wrap.c:13: /usr/include/python2.2/unicodeobject.h:73:2: warning: suggest hiding #error from traditional C with an indented # /usr/include/python2.2/unicodeobject.h:127:2: warning: suggest not using #elif in traditional C In file included from /usr/include/python2.2/Python.h:73, from libcap_wrap.c:13: /usr/include/python2.2/longobject.h:48: warning: ISO C89 does not support `long long' /usr/include/python2.2/longobject.h:49: warning: ISO C89 does not support `long long' /usr/include/python2.2/longobject.h:50: warning: ISO C89 does not support `long long' /usr/include/python2.2/longobject.h:51: warning: ISO C89 does not support `long long' libcap_wrap.c:341: warning: cast discards qualifiers from pointer target type libcap_wrap.c: In function `SWIG_ConvertPtr': libcap_wrap.c:494: warning: cast discards qualifiers from pointer target type libcap_wrap.c: In function `SWIG_NewPointerObj': libcap_wrap.c:569: warning: cast discards qualifiers from pointer target type libcap_wrap.c:576: warning: cast discards qualifiers from pointer target type In file included from libcap_wrap.c:662: libcap.h:57:3: warning: suggest hiding #error from traditional C with an indented # libcap.h:58:3: warning: suggest hiding #error from traditional C with an indented # libcap.h:101:25: warning: ISO C does not permit named variadic macros libcap_wrap.c: In function `_wrap_cap_dup': libcap_wrap.c:673: warning: cast discards qualifiers from pointer target type libcap_wrap.c: In function `_wrap_cap_free': libcap_wrap.c:690: warning: cast discards qualifiers from pointer target type libcap_wrap.c: In function `_wrap_cap_init': libcap_wrap.c:705: warning: cast discards qualifiers from pointer target type libcap_wrap.c: In function `_wrap_cap_get_flag': libcap_wrap.c:725: warning: cast discards qualifiers from pointer target type libcap_wrap.c: In function `_wrap_cap_set_flag': libcap_wrap.c:748: warning: cast discards qualifiers from pointer target type libcap_wrap.c: In function `_wrap_cap_clear': libcap_wrap.c:766: warning: cast discards qualifiers from pointer target type libcap_wrap.c: In function `_wrap_cap_get_proc': libcap_wrap.c:781: warning: cast discards qualifiers from pointer target type libcap_wrap.c: In function `_wrap_cap_set_proc': libcap_wrap.c:797: warning: cast discards qualifiers from pointer target type libcap_wrap.c: In function `_wrap_cap_size': libcap_wrap.c:814: warning: cast discards qualifiers from pointer target type libcap_wrap.c: In function `_wrap_cap_copy_ext': libcap_wrap.c:841: warning: cast discards qualifiers from pointer target type libcap_wrap.c: In function `_wrap_cap_copy_int': libcap_wrap.c:866: warning: cast discards qualifiers from pointer target type libcap_wrap.c: In function `_wrap_cap_from_text': libcap_wrap.c:882: warning: cast discards qualifiers from pointer target type libcap_wrap.c: In function `_wrap_cap_to_text': libcap_wrap.c:900: warning: cast discards qualifiers from pointer target type libcap_wrap.c:905: warning: cast discards qualifiers from pointer target type libcap_wrap.c: At top level: libcap_wrap.c:913: warning: cast discards qualifiers from pointer target type libcap_wrap.c:914: warning: cast discards qualifiers from pointer target type libcap_wrap.c:915: warning: cast discards qualifiers from pointer target type libcap_wrap.c:916: warning: cast discards qualifiers from pointer target type libcap_wrap.c:917: warning: cast discards qualifiers from pointer target type libcap_wrap.c:918: warning: cast discards qualifiers from pointer target type libcap_wrap.c:919: warning: cast discards qualifiers from pointer target type libcap_wrap.c:920: warning: cast discards qualifiers from pointer target type libcap_wrap.c:921: warning: cast discards qualifiers from pointer target type libcap_wrap.c:922: warning: cast discards qualifiers from pointer target type libcap_wrap.c:923: warning: cast discards qualifiers from pointer target type libcap_wrap.c:924: warning: cast discards qualifiers from pointer target type libcap_wrap.c:925: warning: cast discards qualifiers from pointer target type libcap_wrap.c:949: warning: cast discards qualifiers from pointer target type libcap_wrap.c:950: warning: cast discards qualifiers from pointer target type libcap_wrap.c:951: warning: cast discards qualifiers from pointer target type libcap_wrap.c:952: warning: cast discards qualifiers from pointer target type libcap_wrap.c:953: warning: cast discards qualifiers from pointer target type libcap_wrap.c:963: warning: no previous prototype for `init_libcap' libcap_wrap.c: In function `init_libcap': libcap_wrap.c:969: warning: cast discards qualifiers from pointer target type ld -x -shared -o libcapmodule.so libcap_wrap.o cap_alloc.o cap_proc.o cap_extint.o cap_flag.o cap_text.o cap_sys.o make[1]: Leaving directory `/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap' make -C progs CC='gcc' CFLAGS='-Dlinux -ansi -D_POSIX_SOURCE -Wall -Wwrite-strings -Wpointer-arith -Wcast-qual -Wcast-align -Wtraditional -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline -Wshadow -pedantic -mcpu=ev56 -O3 -pipe -I/usr/include/python2.2 -I/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap/include -fPIC' LD='ld' LIBS='-L/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap -lcap' LDFLAGS='-s ' VERSION='1' MINOR='10' LIBDIR='/lib' INCDIR='/usr/include' SBINDIR='/sbin' MANDIR='/usr/man' all make[1]: Entering directory `/var/tmp/portage/libcap-1.10/work/libcap-1.10/progs' make[1]: warning: jobserver unavailable: using -j1. Add `+' to parent make rule. gcc -Dlinux -ansi -D_POSIX_SOURCE -Wall -Wwrite-strings -Wpointer-arith -Wcast-qual -Wcast-align -Wtraditional -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline -Wshadow -pedantic -mcpu=ev56 -O3 -pipe -I/usr/include/python2.2 -I/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap/include -fPIC -c getpcaps.c -o getpcaps.o getpcaps.c: In function `usage': getpcaps.c:21: warning: traditional C rejects string concatenation getpcaps.c:22: warning: traditional C rejects string concatenation getpcaps.c:23: warning: traditional C rejects string concatenation getpcaps.c: In function `main': getpcaps.c:43: warning: traditional C rejects string concatenation getpcaps.c:51: warning: traditional C rejects string concatenation gcc -s -o getpcaps getpcaps.o -L/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap -lcap gcc -Dlinux -ansi -D_POSIX_SOURCE -Wall -Wwrite-strings -Wpointer-arith -Wcast-qual -Wcast-align -Wtraditional -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline -Wshadow -pedantic -mcpu=ev56 -O3 -pipe -I/usr/include/python2.2 -I/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap/include -fPIC -c setpcaps.c -o setpcaps.o setpcaps.c: In function `usage': setpcaps.c:22: warning: traditional C rejects string concatenation setpcaps.c:23: warning: traditional C rejects string concatenation setpcaps.c:24: warning: traditional C rejects string concatenation setpcaps.c:25: warning: traditional C rejects string concatenation setpcaps.c:26: warning: traditional C rejects string concatenation setpcaps.c:27: warning: traditional C rejects string concatenation gcc -s -o setpcaps setpcaps.o -L/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap -lcap gcc -Dlinux -ansi -D_POSIX_SOURCE -Wall -Wwrite-strings -Wpointer-arith -Wcast-qual -Wcast-align -Wtraditional -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline -Wshadow -pedantic -mcpu=ev56 -O3 -pipe -I/usr/include/python2.2 -I/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap/include -fPIC -c execcap.c -o execcap.o execcap.c: In function `usage': execcap.c:21: warning: traditional C rejects string concatenation execcap.c:22: warning: traditional C rejects string concatenation execcap.c:23: warning: traditional C rejects string concatenation execcap.c:24: warning: traditional C rejects string concatenation execcap.c:25: warning: traditional C rejects string concatenation execcap.c:26: warning: traditional C rejects string concatenation execcap.c:28: warning: implicit declaration of function `exit' execcap.c: At top level: execcap.c:32: warning: return type of `main' is not `int' gcc -s -o execcap execcap.o -L/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap -lcap gcc -Dlinux -ansi -D_POSIX_SOURCE -Wall -Wwrite-strings -Wpointer-arith -Wcast-qual -Wcast-align -Wtraditional -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline -Wshadow -pedantic -mcpu=ev56 -O3 -pipe -I/usr/include/python2.2 -I/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap/include -fPIC -c sucap.c -o sucap.o sucap.c: In function `usage': sucap.c:28: warning: traditional C rejects string concatenation sucap.c:29: warning: traditional C rejects string concatenation sucap.c:30: warning: traditional C rejects string concatenation sucap.c:31: warning: traditional C rejects string concatenation sucap.c:32: warning: traditional C rejects string concatenation sucap.c:33: warning: traditional C rejects string concatenation sucap.c:35: warning: implicit declaration of function `exit' sucap.c: At top level: sucap.c:52: warning: return type of `main' is not `int' gcc -s -o sucap sucap.o -L/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap -lcap make[1]: Leaving directory `/var/tmp/portage/libcap-1.10/work/libcap-1.10/progs' make -C doc CC='gcc' CFLAGS='-Dlinux -ansi -D_POSIX_SOURCE -Wall -Wwrite-strings -Wpointer-arith -Wcast-qual -Wcast-align -Wtraditional -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline -Wshadow -pedantic -mcpu=ev56 -O3 -pipe -I/usr/include/python2.2 -I/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap/include -fPIC' LD='ld' LIBS='-L/var/tmp/portage/libcap-1.10/work/libcap-1.10/libcap -lcap' LDFLAGS='-s ' VERSION='1' MINOR='10' LIBDIR='/lib' INCDIR='/usr/include' SBINDIR='/sbin' MANDIR='/usr/man' all make[1]: Entering directory `/var/tmp/portage/libcap-1.10/work/libcap-1.10/doc' make[1]: warning: jobserver unavailable: using -j1. Add `+' to parent make rule. make[1]: Nothing to be done for `all'. make[1]: Leaving directory `/var/tmp/portage/libcap-1.10/work/libcap-1.10/doc'
Should hopefully be fixed in CVS now, I don't have an alpha, so please test it.
Many of the warning are still there but it compiles.... and installs
ok, great. somebody really needs to go and clean it up properly. I don't have the time for it at all, nor access to 64bit linux boxes.