Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 293166 - dev-lang/lua-5.1.4-r2 fails to build: undefined symbols in luac
Summary: dev-lang/lua-5.1.4-r2 fails to build: undefined symbols in luac
Status: VERIFIED NEEDINFO
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: High normal
Assignee: Matti Bickel (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-11-14 12:28 UTC by Roman Zimmermann
Modified: 2011-10-24 16:01 UTC (History)
1 user (show)

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


Attachments
full build.log as requested (build.log,8.88 KB, text/plain)
2009-11-14 15:57 UTC, Roman Zimmermann
Details
paludis --info =dev-lang/lua-5.1.4-r2::gentoo (paludis-info.log,15.64 KB, text/plain)
2009-11-14 16:01 UTC, Roman Zimmermann
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Roman Zimmermann 2009-11-14 12:28:55 UTC
When I try to install dev-lang/lua it fails due to undefined symbols in luac the failing command is:

libtool --quiet --tag=CC --mode=link x86_64-pc-linux-gnu-gcc -static  -o luac luac.lo print.lo liblua.la

It is strange though, that the undefined symbols schould be provided by liblua.la .

The error does not occur when I manually compile with the vanilla sources. So the source of the problem is somewhere in the patches.

Reproducible: Always

Steps to Reproduce:
1. paludis -i1 dev-lang/lua

Actual Results:  
install fails

Expected Results:  
successful install

Here is the whole log of the installation:

make -j2 CC=x86_64-pc-linux-gnu-gcc CFLAGS=-DLUA_USE_LINUX -O2 -pipe -march=native RPATH=//usr/lib64/ LUA_LIBS=-lreadline LIB_LIBS=-lm -ldl V=5.1.4 gentoo_all                                                                                                          
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o lapi.lo lapi.c       
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o lcode.lo lcode.c     
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o ldebug.lo ldebug.c   
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o ldo.lo ldo.c         
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o ldump.lo ldump.c     
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o lfunc.lo lfunc.c     
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o lgc.lo lgc.c         
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o llex.lo llex.c       
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o lmem.lo lmem.c       
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o lobject.lo lobject.c 
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o lopcodes.lo lopcodes.c                                                                                                                                   
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o lparser.lo lparser.c 
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o lstate.lo lstate.c   
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o lstring.lo lstring.c 
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o ltable.lo ltable.c   
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o ltm.lo ltm.c         
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o lundump.lo lundump.c 
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o lvm.lo lvm.c         
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o lzio.lo lzio.c       
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o lauxlib.lo lauxlib.c 
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o lbaselib.lo lbaselib.c                                                                                                                                   
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o ldblib.lo ldblib.c   
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o liolib.lo liolib.c   
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o lmathlib.lo lmathlib.c                                                                                                                                   
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o loslib.lo loslib.c   
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o ltablib.lo ltablib.c 
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o lstrlib.lo lstrlib.c 
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o loadlib.lo loadlib.c 
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o linit.lo linit.c     
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o lua.lo lua.c         
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o luac.lo luac.c       
libtool --quiet --tag=CC --mode=compile x86_64-pc-linux-gnu-gcc -c  -DLUA_USE_LINUX -O2 -pipe -march=native -o print.lo print.c     
libtool --quiet --tag=CC --mode=link x86_64-pc-linux-gnu-gcc -version-info 6:4:1 \                                                  
            -rpath //usr/lib64/  -o liblua.la lapi.lo lcode.lo ldebug.lo ldo.lo ldump.lo lfunc.lo lgc.lo llex.lo lmem.lo lobject.lo lopcodes.lo lparser.lo lstate.lo lstring.lo ltable.lo ltm.lo lundump.lo lvm.lo lzio.lo lauxlib.lo lbaselib.lo ldblib.lo liolib.lo lmathlib.lo loslib.lo ltablib.lo lstrlib.lo loadlib.lo linit.lo -lm -ldl                                                              
libtool --quiet --tag=CC --mode=link x86_64-pc-linux-gnu-gcc -static -export-dynamic  -o lua lua.lo liblua.la -lreadline            
libtool --quiet --tag=CC --mode=link x86_64-pc-linux-gnu-gcc -static -export-dynamic  -o lua_test lua.lo liblua.la -lreadline       
libtool --quiet --tag=CC --mode=link x86_64-pc-linux-gnu-gcc -static  -o luac luac.lo print.lo liblua.la                            
.libs/luac.o: In function `pmain':                                                                                                  
luac.c:(.text+0x524): undefined reference to `luaU_dump'                                                                            
luac.c:(.text+0x564): undefined reference to `luaF_newproto'                                                                        
luac.c:(.text+0x5ae): undefined reference to `luaS_newlstr'                                                                         
luac.c:(.text+0x5d3): undefined reference to `luaM_realloc_'                                                                        
luac.c:(.text+0x5f7): undefined reference to `luaM_realloc_'                                                                        
luac.c:(.text+0x6b9): undefined reference to `luaD_growstack'                                                                       
luac.c:(.text+0x6d4): undefined reference to `luaM_toobig'                                                                          
luac.c:(.text+0x6ed): undefined reference to `luaM_toobig'                                                                          
.libs/print.o: In function `luaU_print':                                                                                            
print.c:(.text+0x542): undefined reference to `luaP_opnames'                                                                        
print.c:(.text+0x560): undefined reference to `luaP_opmodes'                                                                        
/usr/lib/gcc/x86_64-pc-linux-gnu/4.3.4/../../../../x86_64-pc-linux-gnu/bin/ld: luac: hidden symbol `luaM_realloc_' isn't defined    
/usr/lib/gcc/x86_64-pc-linux-gnu/4.3.4/../../../../x86_64-pc-linux-gnu/bin/ld: final link failed: Nonrepresentable section on output
collect2: ld returned 1 exit status                                                                                                 
make: *** [luac] Error 1                                                                                                            
/usr/libexec/paludis/utils/emake: emake returned error 2                                                                            

!!! ERROR in dev-lang/lua-5.1.4-r2::gentoo:
!!! In src_compile at line 3926            
!!! emake failed
Comment 1 Justin Lecher (RETIRED) gentoo-dev 2009-11-14 15:47:29 UTC
Please attach the full build.log and the ouput of emerge --info =dev-lang/lua-5.1.4-r2
Comment 2 Roman Zimmermann 2009-11-14 15:57:09 UTC
Created attachment 210243 [details]
full build.log as requested
Comment 3 Roman Zimmermann 2009-11-14 16:01:01 UTC
Created attachment 210244 [details]
paludis --info =dev-lang/lua-5.1.4-r2::gentoo

Sorry portage is not configured for my system, but paludis --info provides the same (if not more) information about my system.

For the meanwhile I created an alternative ebuild that leaves out the lua-5.1-make-r1.patch which works just fine (except that it does not build a dynamic linked library).
Comment 4 Justin Lecher (RETIRED) gentoo-dev 2009-11-14 17:30:55 UTC
(In reply to comment #3)
> Created an attachment (id=210244) [details]
> paludis --info =dev-lang/lua-5.1.4-r2::gentoo
> 
> Sorry portage is not configured for my system, but paludis --info provides the
> same (if not more) information about my system.

It doesn't tell me which USE you are trying to use.
Comment 5 Roman Zimmermann 2009-11-14 17:41:28 UTC
Acutally it does:

USE=readline static

It's in the seventh line from the bottom.
Comment 6 Roman Zimmermann 2009-11-14 17:42:14 UTC
(In reply to comment #5)
> Acutally it does:
> 
> USE=readline static
> 
> It's in the seventh line from the bottom.
>

I forgot to say: The same error does also occur with USE=-static.

Comment 7 Justin Lecher (RETIRED) gentoo-dev 2009-11-14 17:57:38 UTC
(In reply to comment #5)
> Acutally it does:
> 
> USE=readline static
> 
> It's in the seventh line from the bottom.
> 

and what about the deprecated emacs USE which is also in there? :)
Comment 8 Roman Zimmermann 2009-11-14 18:13:50 UTC
(In reply to comment #7)
> (In reply to comment #5)
> > USE=readline static
> 
> and what about the deprecated emacs USE which is also in there? :)
> 

USE-flags that are not set don't show up. So -emacs is indicated by emacs not being mentioned in USE. Hence USE shows only the flags that are set.
Comment 9 Justin Lecher (RETIRED) gentoo-dev 2009-11-14 18:25:59 UTC
(In reply to comment #8)
> (In reply to comment #7)
> > (In reply to comment #5)
> > > USE=readline static
> > 
> > and what about the deprecated emacs USE which is also in there? :)
> > 
> 
> USE-flags that are not set don't show up. So -emacs is indicated by emacs not
> being mentioned in USE. Hence USE shows only the flags that are set.
> 

So you use USE="deprecated -emacs readline static" ?
Comment 10 Roman Zimmermann 2009-11-14 18:49:16 UTC
(In reply to comment #7)
> 
> So you use USE="deprecated -emacs readline static" ?
> 

Sorry for making it so complicated. "deprecated" isn't mentioned either so:
USE="-deprecated -emacs readline static"

Note to self: put this in the comment next time right from the beginning ;)
Comment 11 Justin Lecher (RETIRED) gentoo-dev 2009-11-14 18:53:17 UTC
Thanks leave the rest to the maintainer
Comment 12 Matti Bickel (RETIRED) gentoo-dev 2009-11-20 07:28:27 UTC
Sorry for not replying sooner. My gentoo machine is still belly up (i.e. segfaulting all over the place). I will see if I can do anything about your problem.
Comment 13 Matti Bickel (RETIRED) gentoo-dev 2010-03-27 20:30:35 UTC
One question: is this your first install of lua AT ALL on this computer?

I don't have a definite answer to this. True, i've rewritten luas build system to match gentoo policy and i'm not a autoconf wizard, so things may have gone wrong. But since i can't reproduce this, i have a hard time figuring out what went wrong.

I'll get in touch with the paludis guys if this could be a pkg manager issue.
Comment 14 Roman Zimmermann 2010-03-27 21:49:09 UTC
Hi,

I just tried it to reproduce this error with my current setup and it seems that everything works fine now with -r4. So I'm closing this bug.

Thanks for taking the time to look into this.