64bit Genode and Fiasco.OC

Norman Feske norman.feske at ...1...
Sat Mar 12 13:11:04 CET 2011


Hi David,

as outlined by Stefan, the 'linux_x86' platform looks for the host
system and automatically decides whether to build for 32bit or 64bit. If
the host system is 64bit, then Genode is built for 64bit. This is
because our only current use case for the linux version is running
Genode on the host. However, in your case, this causes trouble.

I'll try to briefly describe what is going on: You can find the
detection-magic at 'base-linux/etc/specs.conf'. Depending on the host
system, the 'spec.conf' file will set the 'linux_x86_64' or
'linux_x86_32' spec value, which triggers the inclusion of
'base-linux/mk/spec-linux_x86_32.mk' or
'base-linux/mk/spec-linux_x86_64.mk' respectively. In these files, the
spec value 'x86_32' (or 'x86_64') get defined, which gets further broken
up in 'base/mk/spec-x86_32.mk' (analogously for 64bit). This spec file
adds the '32bit' spec value. If you like to peek onto the result of the
successive spec decomposition, you might add the following line to
'<build-dir>/Makefile' (right after the 'export SPECS' line:

  $(warning SPECS=$(SPECS))

As Stefan already mentioned, you can override the default SPECS
definition by a custom '<build-dir>/etc/specs.conf' file. Note the use
of the assignment in contrast to the version found in
'base-linux/etc/specs.conf'.

> I tried to force LIB_MK to the right syscall.mk but it then followed 
> with a load of redefinition errors.  Below is the make VERBOSE_DIR= output.
>
> ...
> /home/dwaddington/git/omnios/genode/base-linux/../base-linux/sr
/platform/x86_64/lx_clone.S:21:
> Error: bad register name `%rsi'

It seems that the build system has not picked up your custom SPECS
definition and still tries to use the SPECS as defined in
'base-linux/etc/specs.conf'. Hence, the build system keeps trying to
build the 64bit code with the 32bit compiler. As a quick work-around,
just to see if the code works, you may modify the
'base-linux/etc/specs.conf' file. But we should investigate why the
build system ignores your '<build-dir>/etc/specs.conf' file. Could I
have a look at your version of the file?

Best regards
Norman

-- 
Dr.-Ing. Norman Feske
Genode Labs

http://www.genode-labs.com · http://genode.org

Genode Labs GmbH · Amtsgericht Dresden · HRB 28424 · Sitz Dresden
Geschäftsführer: Dr.-Ing. Norman Feske, Christian Helmuth




More information about the users mailing list