[Mono-dev] mono 2.0, solaris x86, bootstrap

pablosantosluac at terra.es pablosantosluac at terra.es
Sun Oct 5 16:16:31 EDT 2008


Andreas,

I just followed your instructions, step by step. First downloaded and 
installed gc-7.1 (worked perfectly), then configure and make mono. But 
I'm afraid I think I'm reaching the same point.


Here's the ouput. At some point (it seems it happens after compiling 
some c# code) it starts complaining about mscorlib location...


gmake[7]: Leaving directory `/home/pablo/mono/mono-2.0/mcs/build'
gmake[6]: Leaving directory `/home/pablo/mono/mono-2.0/mcs/build'
gmake[6]: Entering directory `/home/pablo/mono/mono-2.0/mcs/jay'
gmake all-local
gmake[7]: Entering directory `/home/pablo/mono/mono-2.0/mcs/jay'
gmake[7]: Nothing to be done for `all-local'.
gmake[7]: Leaving directory `/home/pablo/mono/mono-2.0/mcs/jay'
gmake[6]: Leaving directory `/home/pablo/mono/mono-2.0/mcs/jay'
gmake[6]: Entering directory `/home/pablo/mono/mono-2.0/mcs/mcs'
gmake all-local
gmake[7]: Entering directory `/home/pablo/mono/mono-2.0/mcs/mcs'
mcs /codepage:65001  -optimize -d:NET_1_1 -d:ONLY_1_1 
-d:BOOTSTRAP_WITH_OLDLIB -debug -target:exe -out:mcs.exe cs-parser.cs  
@mcs.exe.sources
GC Warning: Large stack limit(133464064): only scanning 8 MB
cs-parser.cs(6665,7): warning CS0162: Unreachable code detected
cs-parser.cs(6667,5): warning CS0162: Unreachable code detected
expression.cs(991,14): warning CS0618: 
`Mono.CSharp.UserOperatorCall.MakeSimpleCall(Mono.CSharp.EmitContext, 
Mono.CSharp.MethodGroupExpr, Mono.CSharp.Expression, 
Mono.CSharp.Location)' is obsolete: `It may not be compatible with 
expression trees'
Compilation succeeded - 3 warning(s)
cp mcs.exe ../class/lib/basic/mcs.exe
test ! -f mcs.exe.mdb || cp mcs.exe.mdb ../class/lib/basic/mcs.exe.mdb
gmake[7]: Leaving directory `/home/pablo/mono/mono-2.0/mcs/mcs'
gmake[6]: Leaving directory `/home/pablo/mono/mono-2.0/mcs/mcs'
gmake[6]: Entering directory `/home/pablo/mono/mono-2.0/mcs/class'
gmake[7]: Entering directory `/home/pablo/mono/mono-2.0/mcs/class/corlib'
gmake all-local
gmake[8]: Entering directory `/home/pablo/mono/mono-2.0/mcs/class/corlib'
mcs /codepage:65001 -nowarn:169,612,618,649 -d:INSIDE_CORLIB -optimize 
-d:NET_1_1 -d:ONLY_1_1 -d:BOOTSTRAP_WITH_OLDLIB -debug /noconfig -unsafe 
-nostdlib -resource:resources/collation.core.bin 
-resource:resources/collation.tailoring.bin 
-resource:resources/collation.cjkCHS.bin 
-resource:resources/collation.cjkCHT.bin 
-resource:resources/collation.cjkJA.bin 
-resource:resources/collation.cjkKO.bin 
-resource:resources/collation.cjkKOlv2.bin -target:library 
-out:mscorlib.dll  @corlib.dll.sources
GC Warning: Large stack limit(133464064): only scanning 8 MB
System/WindowsConsoleDriver.cs(29,1): warning CS1635: Cannot restore 
warning `CS0169' because it was disabled globally
System.Security.Cryptography/PasswordDeriveBytes.cs(231,1): warning 
CS1691: `809' is not a valid warning number
System.Security.Cryptography/PasswordDeriveBytes.cs(237,1): warning 
CS1691: `809' is not a valid warning number
System/Int16.cs(178,3): warning CS0162: Unreachable code detected
System/Int32.cs(200,3): warning CS0162: Unreachable code detected
System/Int64.cs(181,3): warning CS0162: Unreachable code detected
System/String.cs(946,6): warning CS0162: Unreachable code detected
System/String.cs(1049,6): warning CS0162: Unreachable code detected
Mono.Globalization.Unicode/Normalization.cs(76,36): warning CS0162: 
Unreachable code detected
Compilation succeeded - 9 warning(s)
:  mscorlib.dll ../../class/mono.snk
mv mscorlib.dll ../../class/lib/basic/mscorlib.dll
test ! -f mscorlib.dll.mdb || mv mscorlib.dll.mdb 
../../class/lib/basic/mscorlib.dll.mdb
test ! -f mscorlib.pdb || mv mscorlib.pdb ../../class/lib/basic/mscorlib.pdb
gmake[8]: Leaving directory `/home/pablo/mono/mono-2.0/mcs/class/corlib'
gmake[7]: Leaving directory `/home/pablo/mono/mono-2.0/mcs/class/corlib'
gmake[7]: Entering directory `/home/pablo/mono/mono-2.0/mcs/class/System'
gmake all-local
gmake[8]: Entering directory `/home/pablo/mono/mono-2.0/mcs/class/System'
** Warning: System.dll built without parts that depend on: System.Xml.dll
MONO_PATH="../../class/lib/basic:$MONO_PATH" 
/home/pablo/mono/mono-2.0/runtime/mono-wrapper  
../../class/lib/basic/mcs.exe /codepage:65001  -optimize -d:NET_1_1 
-d:ONLY_1_1 -d:BOOTSTRAP_WITH_OLDLIB -debug /noconfig  -target:library 
-out:System.dll  @System.dll.sources
The assembly mscorlib.dll was not found or could not be loaded.
It should have been installed in the 
`/opt/mono/lib/mono/1.0/mscorlib.dll' directory.
gmake[8]: *** [../../class/lib/basic/System.dll] Error 1
gmake[8]: Leaving directory `/home/pablo/mono/mono-2.0/mcs/class/System'
gmake[7]: *** [do-all] Error 2
gmake[7]: Leaving directory `/home/pablo/mono/mono-2.0/mcs/class/System'
gmake[6]: *** [all-recursive] Error 1
gmake[6]: Leaving directory `/home/pablo/mono/mono-2.0/mcs/class'
gmake[5]: *** [all-recursive] Error 1
gmake[5]: Leaving directory `/home/pablo/mono/mono-2.0/mcs'
gmake[4]: *** [profile-do--basic--all] Error 2
gmake[4]: Leaving directory `/home/pablo/mono/mono-2.0/mcs'
gmake[3]: *** [profiles-do--all] Error 2
gmake[3]: Leaving directory `/home/pablo/mono/mono-2.0/mcs'
gmake[2]: *** [all-local] Error 2
gmake[2]: Leaving directory `/home/pablo/mono/mono-2.0/runtime'
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory `/home/pablo/mono/mono-2.0'
gmake: *** [all] Error 2


-bash-3.00$ uname -a
SunOS unknown 5.10 Generic_127128-11 i86pc i386 i86pc


Thanks again for your help

pablo




Andreas Färber escribió:
> pablosantosluac at terra.es schrieb:
>> Well, it seems building the "core" is not hard if you make sure (on 
>> Solaris 10) that you use GNU packages and not the SUN ones (gmake, 
>> libtool, and everything else). I can build "mono" from trunk or 2-0. 
>> but the problems start with mcs... I'm now following the instructions 
>> sent by Geoff (basically using 
>> http://mono.ximian.com/monobuild/preview/sources/mono/mono-2.0.tar.bz2).
>
> Having the runtime compile does not imply it'll work at runtime... 
> Whether you use a tarball or monolite usually doesn't matter, but if 
> you can, a tarball is "safer".
>
> Fwiw, I've just finished compiling mono at r114845+mcs@r114882 from
> mono at r109531+mcs@r109587 (all trunk) on OpenSolaris build 95 for i86
> using exactly this:
>
> ../mono/configure --prefix=/opt/mono --with-gc=boehm \
> --with-sigaltstack=no \
> CPPFLAGS="-I/opt/mono-gc/include" \
> LDFLAGS="-L/opt/mono-gc/lib -R/opt/mono/lib"
>
> where /opt/mono-gc is the prefix of Boehm GC 7.1, compiled with:
>
> ../gc-7.1/configure --prefix=/opt/mono-gc
>
> Works nicely there. Don't have access to S10 from here though to fetch
> my scripts or to try the latest revs there.
>
> On OpenSolaris/amd64, I use these on top:
>
> PREFIX=/opt/mono-gc
>
> ../gc-7.1/configure --prefix=$PREFIX --libdir=$PREFIX/lib/amd64 \
> CPPFLAGS=-m64 CFLAGS=-m64 CXXFLAGS=-m64 LDFLAGS=-m64
>
> and:
>
> PREFIX=/opt/mono
>
> ../mono/configure --prefix=$PREFIX --bindir=$PREFIX/bin/amd64
> --libdir=$PREFIX/lib/amd64 \
> --with-gc=boehm --with-sigaltstack=no --enable-big-arrays
> --enable-dtrace --disable-mcs-build \
> CPPFLAGS="-m64 -I/opt/mono-gc/include" CFLAGS="-m64" \
> LDFLAGS="-m64 -L/opt/mono-gc/lib/amd64 -R/opt/mono/lib/amd64" \
> PKG_CONFIG_PATH="/usr/lib/amd64/pkgconfig:$PKG_CONFIG_PATH"
>
> (Obviously I'm skipping mcs build in this script, but I've done full
> amd64 bootstraps before with post-2.0 revisions.)
>
> Note that I use dedicated /opt subdirs because that's where 3rdparty
> packages are often installed on Solarises, making it easy to rename or
> remove. $prefix/{bin,lib}/amd64 is where Sun places their amd64 files.
>
> Using a monolite from 12:05 GMT+02:00 today (with Sun's `mcs` renamed),
> there are no problems on OSol/i86 either.
> So it's definitely not mcs's or monolite's fault!!!
>
>
>>> Cetin actually mentioned OpenSolaris as opposed to Solaris 10. When 
>>> OpenSolaris 2008.05 was released I posted the following mini-guide:
>>> http://lists.ximian.com/pipermail/mono-list/2008-May/038584.html
>>>
>>> It was actually supposed to avoid questions later on. ;)
>>>
>> Following this guide the only thing I realize I missed is the LDFLAGS 
>> stuff? Is it the reason why mcs.exe can't be run?
>
> In case you mean LDFLAGS=-R/path then no, it has no influence on mcs. It
> helps with MD (libPosixHelper.so et al.).
>
>>> The often-referenced http://www.mono-project.com/Mono:Solaris page 
>>> contains a link to another post of mine, for Solaris 10:
>>> http://lists.ximian.com/pipermail/mono-list/2007-January/034101.html
>>>
>> Yes, this guide was helpful building 1.1.13 (almost two years ago 
>> already), but now all those tricks are not needed anymore... You can 
>> get the whole c code build easily...
>
> If you build using Blastwave tools you don't need some of the 
> environment variables; otherwise you still do on Solaris 10.
>
> The only thing outdated in that post to my knowledge is
> CFLAGS=-D_POSIX_PTHREAD_SEMANTICS and possibly the mono-service issue.
> Jonel's blog on the -mt pkg-config issue is almost three years old and
> mostly still applies due to the long lifetime of S10. :)
> AS=gas for instance was only needed for running `make check` so you
> won't notice during plain `make`.
>
> Andreas
>
>
>


More information about the Mono-devel-list mailing list