[Mono-list] mono-build-w32.sh fails with missing symbol
Jon Watte
hplus@b500.com
Thu, 24 Jun 2004 11:22:45 -0700
I finally got enough holes through the corporate firewall
to use the download installer for Cygwin, get anonymous
CVS going, find all the packages I REALLY needed, and now
am using the build script.
Alas, it seems that the pedump tool uses assemblies, and
assemblies require a function mono_set_rootdir, but the
right library to provide it isn't part of the link line.
This symbol is supposed to come from mono/os/win32/util.c
but it appears the library that goes into isn't properly
referenced for some reason.
I'm reasonable friends with gcc, GNU make, and perl, but
I'm not even on speaking terms with libtool, autoconf, or
pkgconfig, so I'm afraid I'll need at least a few
pointers on how packages/libraries are defined with these
tools to be able to make progress.
I can say that the call to mono_set_rootdir() was introduced
to assembly.c in change 1.95 (anonymous CVS), but that was
done on May 1, and I can't believe I'm the only one trying
to use build-mono-w32.sh since then...
There were some Makefile.am changes made on 6/16 which might
have caused this, as it re-arranged some library things. It
seems as if this symbol is supposed to come from
../os/libmonoos.la (based on naming) which in turn, I THINK,
is intended to be included in libmetadata.a -- but the symbol
is actually undefined in there:
bash-2.05b$ nm ./.libs/libmetadata.a | grep set_root
U _mono_set_rootdir
bash-2.05b$
The relevant link error is included below.
Cheers,
/ h+
Making all in metadata
make[3]: Entering directory `/usr/local/mono/mono/metadata'
/bin/bash ../../libtool --mode=link gcc -mno-cygwin -O -I
/usr/local/install/include -I
/usr/local/install/icu/include -fno-strict-aliasing -g -Wall -Wunused -Wmiss
ing-prototypes -Wmissing-declarations -Wstrict-prototypes -Wmissing-prototy
pes -Wnested-externs -Wpointer-arith -Wno-cast-qual -Wcast-align -Wwrite-str
ings -L/usr/local/install/lib -L/usr/local/install/icu/lib -o pedump.exe
pedump.o libmetadata.la ../io-layer/libwapi.la
./utils/libmonoutils.la -lgc -L/usr/local/install/lib -lgthread-2.0 -lglib-
2.0 -lintl -liconv -Wl,--export-dynamic -L/usr/local/install/lib -lgmodule
-2.0 -lgl
ib-2.0 -lintl -liconv -lm -lws2_32 -lpsapi
gcc -mno-cygwin -O -I /usr/local/install/include -I
/usr/local/install/icu/include -fno-strict-aliasing -g -Wall -Wunused -Wmiss
ing-prototypes -Wmissing-declarations -Wstrict-prototypes -Wmissing-prototyp
es -Wnested-externs -Wpointer-arith -Wno-cast-qual -Wcast-align -Wwrite-stri
ngs -o pedump.exe
pedump.o -Wl,--export-dynamic -L/usr/local/install/lib -L/usr/local/install
/icu/lib ./.libs/libmetadata.a ../io-layer/.libs/libwapi.a
../utils/.libs/libmonoutils.a -lgc -lgthread-2.0 -lgmodule-2.0 -lglib-2.0
/usr/lib/libintl.dll.a -L/usr/lib /usr/lib/libiconv.dll.a -lws2_32 -lpsapi
./.libs/libmetadata.a(assembly.o)(.text+0x40b): In function
`mono_assemblies_init':
/usr/local/mono/mono/metadata/assembly.c:238: undefined reference to
`_mono_set_rootdir'
collect2: ld returned 1 exit status
make[3]: *** [pedump.exe] Error 1
make[3]: Leaving directory `/usr/local/mono/mono/metadata'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/usr/local/mono/mono'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/local/mono'
make: *** [all] Error 2