lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

I must apologize for my ignorance; the lack of recognition of lua_pushnil
was due to my failure to provide a link to the liblua.a.  I am not root on
this machine, and I have lua installed in a nonstandard directory.
However, when I corrected this, there was still a problem.

Once again with ../lua5.1/src as the current directory, I issued:

cc -bnoquiet -I/mydirectory/include -L/mydirectory/lib -llua -o
-qmkshrobj dummy.c

and this failed with problems in the pow and floor functions, viz:

(ld): halt 4
(ld): lrgpage 0
(ld): savename
(ld): filelist 3 2
(ld): setopt noprogram
(ld): noentry
NOENTRY: There is no entry point.
(ld): lib /app/sandbox/s625662/gccinstall/lib/liblua.a
(ld): i dummy.o
(ld): lib /usr/lib/libc.a
LIBRARY: Shared object libc.a[shr.o]: 2562 symbols imported.
LIBRARY: Shared object libc.a[meth.o]: 2 symbols imported.
LIBRARY: Shared object libc.a[posix_aio.o]: 17 symbols imported.
LIBRARY: Shared object libc.a[aio.o]: 11 symbols imported.
LIBRARY: Shared object libc.a[pse.o]: 5 symbols imported.
LIBRARY: Shared object libc.a[dl.o]: 4 symbols imported.
LIBRARY: Shared object libc.a[pty.o]: 1 symbols imported.
FILELIST: Number of previously inserted files processed: 3
(ld): exports /tmp/xlcSEOXyi7e
EXPORTS: Symbols exported: 1
(ld): resolve
RESOLVE: 361 of 4230 symbols were kept.
(ld): addgl /usr/lib/glink.o
ADDGL: Glink code added for 16 symbols.
(ld): er full
ld: 0711-318 ERROR: Undefined symbols were found.
             The following symbols are in error:
 Symbol                    Inpndx  TY CL Source-File(Object-File) OR
                              RLD: Address  Section  Rld-type Referencing


 .pow                      [14]    ER PR
                                   00001cc4 .text    R_RBR    [100]
 .pow                      [42]    ER PR
                                   000011e4 .text    R_RBR    [100]
                                   00002a14 .text    R_RBR    [102]
 .floor                    [12]    ER PR
                                   00001ca8 .text    R_RBR    [100]
 .floor                    [44]    ER PR
                                   00001200 .text    R_RBR    [100]
                                   000029ec .text    R_RBR    [102]
ER: The return code is 8.

I rather suspect that I still have a problem with my call to cc; but I am
not sure what it is.

Mark F. Morss
Principal Analyst, Market Risk
American Electric Power

             Luiz Henrique de                                              
             <lhf@tecgraf.puc-                                          To 
   >                   Lua list                            
             Sent by:                  <>       
             lua-bounces@bazar                                          cc 
             r                                                     Subject 
                                       Re: installing Lua 5.1 on AIX 5.2   
             02/14/2006 01:30                                              
             Please respond to                                             
                 Lua list                                                  

> The result was that ".lua_pushnil" was unrecognized during "ld".

This means that lua_pushnil is not being exported from the lua executable.
Under gcc, in several platforms, the magic to make this happen is to add
-Wl,-E when building the standalone interpreter. I don't know how to do
this with xlc, sorry. Any AIX and xlc experts around?