Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 277466 - sci-mathematics/octave-3.2.0 fails to build: undefined reference to pthread functions
Summary: sci-mathematics/octave-3.2.0 fails to build: undefined reference to pthread f...
Status: RESOLVED DUPLICATE of bug 277068
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: High normal (vote)
Assignee: Gentoo Linux bug wranglers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-07-12 00:58 UTC by Adrian Keet
Modified: 2009-07-12 02:40 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge --info (emergeinfo,11.46 KB, text/plain)
2009-07-12 00:58 UTC, Adrian Keet
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Adrian Keet 2009-07-12 00:58:27 UTC
Building octave-3.2.0 fails when linking octave, due to undefined references to functions in libpthread. Adding -lpthread to LDFLAGS in Makeconf manually makes it build properly.

Reproducible: Always

Steps to Reproduce:




Build log:

x86_64-pc-linux-gnu-g++ -I/usr/include/freetype2 -I. -I.. -I../liboctave -I../src -I../libcruft/misc  -DHAVE_CONFIG_H  -Wall -W -Wshadow -Wold-style-cast -Wformat -O2 -pipe -I/usr/include/freetype2 -rdynamic \
        -L..  -fPIC -Wl,-O1 -o octave \
        main.o  \
        -L../liboctave -L../libcruft -L../src -Wl,-rpath -Wl,/usr/lib64/octave-3.2.0 \
        -loctinterp -loctave  -lcruft   \
             \
           -llapack -lblas   -lblas   \
           -L/usr/X11R6/lib -lGL -lGLU \
        -L/usr/lib64 -lX11  -lreadline  -lncurses -ldl -lblas   -lz -lm  -lfreetype -lz -L/usr/X11R6/lib -lGL -lGLU -L/usr/X11R6/lib -L/usr/lib/gcc/x86_64-pc-linux-gnu/4.3.3 -L/usr/lib/gcc/x86_64-pc-linux-gnu/4.3.3/../../../../lib64 -L/lib/../lib64 -L/usr/lib/../lib64 -L/usr/lib/gcc/x86_64-pc-linux-gnu/4.3.3/../../../../x86_64-pc-linux-gnu/lib -L/usr/lib/gcc/x86_64-pc-linux-gnu/4.3.3/../../.. -lz -lgfortranbegin -lgfortran -lm -lfreetype -lGL -lGLU
../liboctave/liboctave.so: undefined reference to `pthread_mutexattr_destroy'
../liboctave/liboctave.so: undefined reference to `pthread_mutexattr_init'
../liboctave/liboctave.so: undefined reference to `pthread_mutexattr_settype'
collect2: ld returned 1 exit status
make[2]: *** [octave] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: Leaving directory `/var/tmp/portage/sci-mathematics/octave-3.2.0/work/octave-3.2.0/src'
make[1]: *** [src] Error 2
make[1]: Leaving directory `/var/tmp/portage/sci-mathematics/octave-3.2.0/work/octave-3.2.0'
make: *** [all] Error 2
 *
 * ERROR: sci-mathematics/octave-3.2.0 failed.
 * Call stack:
 *               ebuild.sh, line   49:  Called src_compile
 *             environment, line 3219:  Called die
 * The specific snippet of code:
 *       emake || die "emake failed";
 *  The die message:
 *   emake failed
 *
 * If you need support, post the topmost build error, and the call stack if relevant.
 * A complete build log is located at '/var/tmp/portage/sci-mathematics/octave-3.2.0/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/sci-mathematics/octave-3.2.0/temp/environment'.
Comment 1 Adrian Keet 2009-07-12 00:58:52 UTC
Created attachment 197601 [details]
emerge --info
Comment 2 Adrian Keet 2009-07-12 01:05:16 UTC
Sorry, I meant adding -lpthread to FLIBS in Makeconf.
Comment 3 Rafał Mużyło 2009-07-12 02:40:45 UTC
Though your case seems to suggest it was not '--as-needed' problem.

*** This bug has been marked as a duplicate of bug 277068 ***