NEW BUILD SYSTEM: Cannot build rtems-libbsd

Christian Mauderer christian.mauderer at embedded-brains.de
Wed Jul 8 08:47:25 UTC 2020


On 08/07/2020 10:29, Sebastian Huber wrote:
> On 29/06/2020 21:39, Niteesh G. S. wrote:
> 
>> Hello,
>>
>> I tried compiling RTEMS-libBSD with RTEMS6 toolchain and the new build
>> system
>> but failed. I get errors when compiling RTEMS-libBSD
>>
>> The new build system is pulled from Sebastian's branch
>> HEAD: e4c193ddc163d6adb1b003254af9cc6b5d174a6f
>>
>> RTEMS was configured with the following options:
>> 1) ./waf bsp_defaults --rtems-bsps=arm/beagleboneblack > config.ini
>> 2) Enabled posix since libBSD complained about it during configuration.
>> 3) ./waf configure --prefix=$HOME/development/rtems/6
>> 4) ./waf -j32
> 
> This didn't work for me. I got:
> 
> [1391/1410] Linking
> build/arm/beagleboneblack/testsuites/samples/iostream.exe
> /opt/rtems/6/lib/gcc/arm-rtems6/10.0.1/../../../../arm-rtems6/bin/ld:
> ./librtemsbsp.a(bbb-i2c.c.1.o): in function `am335x_i2c_reset':
> /home/EB/sebastian_h/src/rtems/build/arm/beagleboneblack/../../../bsps/arm/beagle/i2c/bbb-i2c.c:202:
> undefined reference to `__wrap_puts'
> collect2: error: ld returned 1 exit status
> 

That's another problem: There is a puts in the bbb-i2c that maybe should
be a printk instead. Haven't found the time yet to post a patch. I'll
send one in a few minutes.

> This error is related to this change:
> 
> https://git.rtems.org/sebh/rtems.git/commit/?h=build&id=9e3a23e4dde96fca2fc5855995527e10a4a119cb
> 
> 
> I guess I made this during the work to get rid of the bsp_specs. The
> problem is that we have a cyclic reference: librtemstest depends on
> librtemscpu which depends on librtemstest (via the wrapped output
> functions). The librtemscpu and librtemsbsp are implicitly given at the
> end via the -qrtems flag. I reverted the change since it seems to work
> without it. Afterwards, I was able to install the BSP.
> 
>> 5) ./waf install
>>
>> RTEMS-libBSD was configured with the following options:
>> 1) ./waf configure --prefix=$HOME/development/rtems/6
>> --rtems-bsps=arm/beagleboneblack --buildset=buildset/minimal.ini
>> --rtems-version=6
>> 2) ./waf -j16
>> I have attached the error log file.
> 
> I got a different error:
> 
> [1163/1163] Linking build/arm-rtems6-beagleboneblack-minimal/zerocopy01.exe
> /opt/rtems/6/lib/gcc/arm-rtems6/10.0.1/../../../../arm-rtems6/bin/ld:
> testsuite/zerocopy01/test_main.c.96.o: in function `.LANCHOR0':
> /home/EB/sebastian_h/src/rtems-libbsd/build/arm-rtems6-beagleboneblack-minimal/../../rtemsbsd/include/machine/rtems-bsd-config.h:238:
> undefined reference to `_bsd_ip6_mroutemodule_sys_init'
> 
> I fixed this with this commit:
> 
> https://git.rtems.org/rtems-libbsd/commit/?h=5-freebsd-12&id=26866d2c1f2432b25b5db71995bce2035187c715
> 
> 
> Which branch do you use for libbsd?
> 
> It seems the master branch. Here I get also your error:
> 
> [1084/1184] Linking build/arm-rtems6-beagleboneblack-minimal/condvar01.exe
> /opt/rtems/6/lib/gcc/arm-rtems6/10.0.1/../../../../arm-rtems6/bin/ld:
> ./libbsd.a(uipc_mbuf.c.16.o): in function `m_unmappedtouio':
> /home/EB/sebastian_h/src/rtems-libbsd/build/arm-rtems6-beagleboneblack-minimal/../../freebsd/sys/kern/uipc_mbuf.c:1813:
> undefined reference to `PHYS_TO_VM_PAGE'
> /opt/rtems/6/lib/gcc/arm-rtems6/10.0.1/../../../../arm-rtems6/bin/ld:
> /home/EB/sebastian_h/src/rtems-libbsd/build/arm-rtems6-beagleboneblack-minimal/../../freebsd/sys/kern/uipc_mbuf.c:1814:
> undefined reference to `uiomove_fromphys'
> 
> Could you please use the 5-freebsd-12 branch with the default build set.
> This is what I use normally.
> 

-- 
--------------------------------------------
embedded brains GmbH
Herr Christian Mauderer
Dornierstr. 4
D-82178 Puchheim
Germany
email: christian.mauderer at embedded-brains.de
Phone: +49-89-18 94 741 - 18
Fax:   +49-89-18 94 741 - 08
PGP: Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.


More information about the devel mailing list