10.1.0 compile problems

Started by tom, June 22, 2009, 06:24:22 AM

Previous topic - Next topic

tom

Howdy guys.



I'm not able to build 10.1.0; I get gobs of undefined reference errors.



newlisp.o: In function `expand':
undefined reference to...
...


I'm using makefile_linuxLP64_utf8



I'll be happy to paste all the error lines if it will help.

Lutz

#1
The make file had nl-utf8.o missing in the OBJS line. Try this version:



http://www.newlisp.org/downloads/makefile_linuxLP64_utf8">http://www.newlisp.org/downloads/makefi ... xLP64_utf8">http://www.newlisp.org/downloads/makefile_linuxLP64_utf8

tom

#2
Quote from: "Lutz"The make file had nl-utf8.o missing in the OBJS line. Try this version:



http://www.newlisp.org/downloads/makefile_linuxLP64_utf8">http://www.newlisp.org/downloads/makefi ... xLP64_utf8">http://www.newlisp.org/downloads/makefile_linuxLP64_utf8


Thanks Lutz, but no change.

Lutz

#3
in order to help, please give info to all of the following questions:



- what Linux distribution and version

- what hardware (AMD or Intel etc.) (to find out, do a: uname -a )

- have you tried to compile the 32-bit version using just 'make' (what was the output?)

- post the entire compile/link output, including the command you used to invoke it

- what makefile did you use last (the one I posted?)

tom

#4
Quotewhat Linux distribution and version


Arch Linux, just updated. (there are no versions, it's a rolling release distro)


Quotewhat hardware (AMD or Intel etc.)


$ uname -a

Linux bigblessing 2.6.29-ARCH #1 SMP PREEMPT Wed May 20 06:42:43 UTC

2009 x86_64 AMD Turion(tm) 64 X2 TL-60 AuthenticAMD GNU/Linux


Quotehave you tried to compile the 32-bit version using just 'make'

(what was the output?)


Script started on Mon 22 Jun 2009 05:50:38 PM CDT
[tf@bigblessing newlisp-10.1.0]$ make

./build



Discovered Linux:

make[1]: Entering directory `/path/to/nl1010/newlisp-10.1.0'

make -f makefile_linux_utf8

make[2]: Entering directory `/path/to/nl1010/newlisp-10.1.0'

gcc -m32 -Wall -pedantic -Wno-strict-aliasing -Wno-long-long -c -O2 -g -DREADLINE -DSUPPORT_UTF8 -DLINUX nl-utf8.c

In file included from /usr/include/features.h:371,

                 from /usr/include/signal.h:29,

                 from newlisp.h:88,

                 from nl-utf8.c:25:

/usr/include/gnu/stubs.h:7:27: error: gnu/stubs-32.h: No such file or directory

make[2]: *** [nl-utf8.o] Error 1

make[2]: Leaving directory `/path/to/nl1010/newlisp-10.1.0'

make[1]: *** [linux_utf8] Error 2

make[1]: Leaving directory `/path/to/nl1010/newlisp-10.1.0'

make: *** [default] Error 2

Script done on Mon 22 Jun 2009 05:50:52 PM CDT


Quotepost the entire compile/link output, including the command you

used to invoke it



gcc newlisp.o nl-symbol.o nl-math.o nl-list.o nl-liststr.o nl-string.o nl-filesys.o nl-sock.o nl-import.o nl-xml.o nl-web.o nl-matrix.o nl-debug.o pcre.o -m64 -g -lm -ldl -lreadline -lncurses -o newlisp
newlisp.o: In function `expand':
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/newlisp.c:4303: undefined reference to `utf8_wchar'
newlisp.o: In function `p_last':
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/newlisp.c:5040: undefined reference to `utf8_1st_len'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/newlisp.c:5045: undefined reference to `utf8_1st_len'
newlisp.o: In function `p_rest':
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/newlisp.c:4880: undefined reference to `utf8_1st_len'
newlisp.o: In function `p_first':
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/newlisp.c:4826: undefined reference to `utf8_1st_len'
newlisp.o: In function `dolist':
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/newlisp.c:5563: undefined reference to `utf8_wchar'
newlisp.o:(.data+0x1358): undefined reference to `p_unicode'
newlisp.o:(.data+0x1370): undefined reference to `p_utf8'
newlisp.o:(.data+0x1388): undefined reference to `p_utf8len'
newlisp.o:(.data+0x14d8): undefined reference to `p_readUTF8'
nl-math.o: In function `unifyGetType':
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-math.c:2807: undefined reference to `utf8_wchar'
nl-liststr.o: In function `p_select':
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-liststr.c:717: undefined reference to `utf8_wstr'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-liststr.c:734: undefined reference to `wstr_utf8'
nl-liststr.o: In function `pushOnString':
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-liststr.c:640: undefined reference to `utf8_wlen'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-liststr.c:656: undefined reference to `utf8_wchar'
nl-liststr.o: In function `popString':
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-liststr.c:567: undefined reference to `utf8_wlen'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-liststr.c:592: undefined reference to `utf8_1st_len'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-liststr.c:595: undefined reference to `utf8_1st_len'
nl-liststr.o: In function `p_chop':
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-liststr.c:263: undefined reference to `utf8_wlen'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-liststr.c:268: undefined reference to `utf8_1st_len'
nl-string.o: In function `p_trim':
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:1950: undefined reference to `utf8_wlen'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:1952: undefined reference to `utf8_wstr'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:1966: undefined reference to `utf8_wchar'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:1974: undefined reference to `utf8_wchar'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:2004: undefined reference to `wstr_utf8'
nl-string.o: In function `strUpperLower':
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:459: undefined reference to `utf8_wlen'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:462: undefined reference to `utf8_wstr'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:480: undefined reference to `wstr_utf8'
nl-string.o: In function `p_explode':
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:390: undefined reference to `utf8_wlen'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:392: undefined reference to `utf8_1st_len'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:403: undefined reference to `utf8_1st_len'
nl-string.o: In function `setNthStr':
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:218: undefined reference to `utf8_1st_len'
nl-string.o: In function `implicitIndexString':
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:188: undefined reference to `utf8_wlen'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:191: undefined reference to `utf8_1st_len'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:195: undefined reference to `utf8_1st_len'
nl-string.o: In function `p_char':
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:328: undefined reference to `wchar_utf8'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:265: undefined reference to `utf8_wlen'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:304: undefined reference to `utf8_1st_len'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-string.c:305: undefined reference to `utf8_wchar'
nl-filesys.o: In function `p_date':
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-filesys.c:2193: undefined reference to `utf8_wlen'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-filesys.c:2195: undefined reference to `utf8_wstr'
/the/path/to/newlisp10.1.0/src/newlisp-10.1.0/nl-filesys.c:2200: undefined reference to `wstr_utf8'
collect2: ld returned 1 exit status
make: *** [default] Error 1



Quotewhat makefile did you use last (the one I posted?)


The output above was with the makefile you provided.  did I miss anything?

Lutz

#5
Thanks for posting all the info.



I see nl-utf8.c beeing compiled in the first 32-bit compile, but not in the second (large output) 64-bit compile. This is why I posted a new makefile_linuxLP64_utf8 earlier, because it has that file added. You seem still to use the old one, because I don't see nl-utf8.o in here (beginning of large output):


gcc newlisp.o nl-symbol.o nl-math.o nl-list.o nl-liststr.o nl-string.o nl-filesys.o nl-sock.o nl-import.o nl-xml.o nl-web.o nl-matrix.o nl-debug.o pcre.o -m64 -g -lm -ldl -lreadline -lncurses -o newlisp

Take the makefile linked to from my earlier post in this thread and try again. Always do a:


make clean

before a recompile.



ps: I will not be available tomorrow until later in the afternoon or night.

tom

#6
thanks lutz, but still no luck.  I did a make clean and diffed the files to make sure I was using the new one, too.  the 32 bit  utf8 makefile doesn't work either.



it looks for /usr/include/gnu/stubs-32.h and can't find it.

TedWalther

#7
Tom, try using the new configure system.  You will find it in the util directory.



cp util/configure-alt configure
cp util/build-alt build
cp util/test-memorymodel.c .
./configure
make


Tell me what happens, if it fails, please cut and paste all the things Lutz asked you to cut and paste.
Cavemen in bearskins invaded the ivory towers of Artificial Intelligence.  Nine months later, they left with a baby named newLISP.  The women of the ivory towers wept and wailed.  \"Abomination!\" they cried.

TedWalther

#8
Lutz, in the current makefile_os2, the DEFAULT_OBJS is exactly the same as for Unix.  Am I missing something?



However, for win32 I do see I need to add win32-util.o win32-path.o.  Will do that right now.



Later...



Ok, it is done now.  I notice the configure-alt in the release isn't the latest, which has substantially better support for everything.



The new configure-alt is in my git tree (teds-tree...) and will be much more useful for testing.
Cavemen in bearskins invaded the ivory towers of Artificial Intelligence.  Nine months later, they left with a baby named newLISP.  The women of the ivory towers wept and wailed.  \"Abomination!\" they cried.

newdep

#9
hello Ted,



Yes the OS2 version is GCC based so thats oke...

I need to test the OS2 compilation still a bit behind on newlisp with OS2.



The ARM/EL GCC wont compile default with the current makefiles as

its using an older gcc that doesnt suooprt -m32



The Slackware compilate Ill test today..Ill report back..
-- (define? (Cornflakes))

Lutz

#10
Ted:
Quote I notice the configure-alt in the release isn't the latest


actually it is the latest, compared with what you have on m4, except for one line difference for the Win32 DEFAULT_OBJS.  I just compared with: teds-tree-newlisp-10.1.0.git/util/configure-alt on your machine.



Also I am adding 'make configure-alt' and 'make configure-org' to the main Makefile, to quickly switch between the new and old system.



Norman:

yes, old versions of gcc that is a problem, I am having all the time. Only on Mac OS X, I can be sure to have the latest or almost latest: gcc version 4.2.1.

tom

#11
Ted,



Whee hoo.  It builds.  However, when I try to incorporate your changes into an arch linux package building script, I get a bunch of undefined reference errors.  The problem is most likely the way and place I'm sticking it.  Feel like taking a look?  Here's an arch linux PKGBUILD that formerly worked. I tried copying the files from the util directory after the cd line in the build section.



pkgname=newlisp
pkgver=10.1.0
pkgrel=3
pkgdesc="newLISP is a LISP like, general purpose scripting language."
url="http://www.newlisp.org"
license=('GPL')
arch=('x86_64' 'i686')
options=('docs')
source=(http://newlisp.com/downloads/$pkgname-$pkgver.tgz)
md5sums=('68be7fa39714dc4022941fdb1adba559')
build() {
  cd $srcdir/$pkgname-$pkgver
   case $CARCH in
       i686) make -f makefile_linux || return 1 ;;
       x86_64) make -f makefile_linuxLP64_utf8 || return 1 ;;
       *) echo "$CARCH is not supported!" ;;
   esac
  mkdir -p $pkgdir/usr/bin
  mkdir -p $pkgdir/usr/share/man/man1
    make bindir=$pkgdir/usr/bin mandir=$pkgdir/usr/share/man datadir=$pkgdir/usr/share install
}

TedWalther

#12
Tom, can you show me all the error messages you get when you add the cp configure-alt and build-alt lines to your PKGBUILD?



Also, the new configure doesn't create new makefile_linuxLP64_utf8, etc.



You need to do this exactly:



cp util/configure-alt configure
cp util/build-alt build
cp util/test-memorymodel.c .
./configure
make


That is all.



Ted
Cavemen in bearskins invaded the ivory towers of Artificial Intelligence.  Nine months later, they left with a baby named newLISP.  The women of the ivory towers wept and wailed.  \"Abomination!\" they cried.

tom

#13
Hey Ted,



I'm not close to that machine at the moment.  doing as you suggest works perfectly. I replace the build section in the PKGBUILD with your stuff and only use configure and make.  I should have shown an edited PKGBUILD, and I will when I get home.  I'm not holding my mouth right, or something, when I try to incorporate your changes.



Thanks for your help.  Hordes of Archlinux users are anxiously waiting for me to grow a brain :-)

TedWalther

#14
Ok, I look forward to hearing how that goes for you.
Cavemen in bearskins invaded the ivory towers of Artificial Intelligence.  Nine months later, they left with a baby named newLISP.  The women of the ivory towers wept and wailed.  \"Abomination!\" they cried.