Created attachment 278773 [details] A corrected version of the blt-2.4z-darwin.patch, I hope. dev-lang/python[tk] does not compile: x86_64-pc-linux-gnu-gcc -pthread -shared -Wl,-O1 -Wl,--as-needed -L. -Wl,-O1 -Wl,--as-needed -L. -fno-strict-aliasing -march=native -O2 -pipe -fwrapv -DNDEBUG -I. -IInclude -I./Include build/temp.linux-x86_64-2.7/var/tmp/portage/dev-lang/python-2.7.2/work/Python-2.7.2/Modules/_tkinter.o build/temp.linux-x86_64-2.7/var/tmp/portage/dev-lang/python-2.7.2/work/Python-2.7.2/Modules/tkappinit.o -L/usr/X11/lib -L/usr/local/lib -L. -lBLT -ltk8.5 -ltcl8.5 -lX11 -lpython2.7 -o build/lib.linux-x86_64-2.7/_tkinter.so *** WARNING: renaming "_tkinter" since importing it failed: build/lib.linux-x86_64-2.7/_tkinter.so: undefined symbol: jpeg_stdio_src The undefined symbol comes from -lBLT through a broken symling in libdir: > ls -l /usr/lib64/*BLT* -rw-r--r-- 1 root root 1948056 Jul 1 11:44 /usr/lib64/libBLT24.a -rwxr-xr-x 1 root root 1212136 Jul 1 11:44 /usr/lib64/libBLT24so lrwxrwxrwx 1 root root 10 Jul 1 11:44 /usr/lib64/libBLT.a -> libBLT24.a -rw-r--r-- 1 root root 380650 Jul 1 11:44 /usr/lib64/libBLTlite24.a -rwxr-xr-x 1 root root 241912 Jul 1 11:44 /usr/lib64/libBLTlite24so lrwxrwxrwx 1 root root 14 Jul 1 11:44 /usr/lib64/libBLTlite.a -> libBLTlite24.a lrwxrwxrwx 1 root root 15 Jul 1 11:44 /usr/lib64/libBLTlite.so -> libBLTlite24.so lrwxrwxrwx 1 root root 11 Jul 1 11:44 /usr/lib64/libBLT.so -> libBLT24.so Instead of libBLT24.so and libBLTlite24.so there are libBLT24so and libBLTlite24so. The cause is blt-2.4z-darwin.patch in dev-tcltk/blt-2.4z-r8 (introduced silently without release number increment! I've found a blt-2.4z-r8.ebuild without that patch at one of my boxes!). The upstream developers of blt use, for reasons unknown to me, in the configure script the variable SHLIB_SUFFIX in two ways, in the first part of the script, while searching for various libraries, it contains the suffix without dot, and is concatenated as libname.${SHLIB_SUFFIX} but in the second part, while defining make rules, SHLIB_SUFFIX is supposed to contain the dot, it is concatenated as libname${SHLIB_SUFFIX}. blt-2.4z-darwin.patch introduces SHLIB_SUFFIX="dylib" for Darwin in the first part, and then removes SHLIB_SUFFIX=".so" in the second part not to overwrite the first setting, missing the change in the dot use. The result likely breaks Darwin too, only HP-UX with its SHLIB_SUFFIX=".sl" intact in the second part of the configure script is save. The patch should either unify the use throughout the configure script or leave the SHLIB_SUFFIX=".so" intact and add SHLIB_SUFFIX=".dylib" in the *-darwin*) section of the second part of the script, analogously to the *-hpux*) section there. I've used the second approach to let my python compile.
Thanks for that digging into the causes. @prefix Could you please fix this? I assume the patch is from you.
Sorry for the hassle. Analysis looks correct to me. Feel free to drop the patch for the time being (cannot fix/test right now).
I applied the fix from Honza and bumped to -r9. Sorry for the breakage, thanks for the analysis and patch!
*** Bug 373897 has been marked as a duplicate of this bug. ***