Re: [Discuss OpenCPI] Issue building OCPI components using new RCC platform based on N310 SDK

From: James Kulp <jek_at_parera.com>
Date: Mon, 15 Jul 19 15:39:50 -0400

Thanks.  Is it easy to import the SDK you are using so we can reproduce
the environment?

On 7/15/19 12:52 PM, Munro, Robert M. wrote:
> Jim,
>
> It looks like the compilation executable environment variables are being overridden. In the sourced SDK environment the CC, CXX, and LD variables are more than the executable but the OCPI environment does not appear to take in the OcpiCFlags and OcpiCXXFlags that are defined in ettus_n310_sdk.mk.
>
> Attached output from the env and printenv commands.
>
> The install-ad9361.sh script was found and followed to generate the required library for assets project compilation. The script build/build-opencpi.sh ettus_n310-sdk was run in an attempt to build the entire framework but it failed when attempting to build its first application with errors stating that ld is unable to find crt*.o and multiple libraries that it is attempting to link.
>
> Thanks,
> Robert Munro
>
> -----Original Message-----
> From: James Kulp <jek_at_parera.com>
> Sent: Monday, July 15, 2019 10:46 AM
> To: Munro, Robert M. <Robert.Munro_at_jhuapl.edu>; discuss_at_lists.opencpi.org
> Subject: Re: [Discuss OpenCPI] Issue building OCPI components using new RCC platform based on N310 SDK
>
> Yes the compiler flags are the issue - I'm just trying to figure out where they are coming from.
>
> Prerequisite build scripts are in three places:
> 1. Framework prerequisites in build/prerequisites 2. Per-project prerequisites in the prerequisites subdirectory of projects 3. Per-platform prerequisites (like installing a cross-compiler), in the rcc platform's directory.
>
>
> On 7/15/19 10:34 AM, Munro, Robert M. wrote:
>> Jim,
>>
>> Agreed that the difference between the calls from within install-prerequisites.sh and direct is the environment being used. It's likely the important difference being the parameters passed to gcc and g++ applications shown as the additional '-march=armv7-a -marm -mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9 --sysroot=/usr/local/oecore-x86_64/sysroots/cortexa9hf-neon-oe-linux-gnueabi' in the direct call. I can work on posting a more complete environment listing, but suspect this difference will be important.
>>
>> Does the install-prerequisites.sh script override the $CC and $CXX environment variables which removes the additional flags? I believed that by specifying the additional flags in the ettus_n310_sdk.mk they would be part of the environment as they are when compiling projects using 'ocpidev build project ... -rcc-platform ettus_n310_sdk' .
>>
>> The build/autotools components completed a build manually with some modifications to autotools/gen/configure. The lines where -Werror=null-dereference and -Werror=maybe-uninitialized are added to compiler flag lists needed to be commented. I was not sure how to correctly remove the compilation flags in this case.
> Any changes to compilation flags are in the .mk file for the platform,
> including overriding defaults.
>
> But those flags (the "error" ones) should only be  used with framework
> code which is clean for them.
>
> Obviously we are interested in seeing whatever patches you found as
> required.
>
>> Where are the compilation steps required for the ad9361 library described? That prerequisite is currently preventing the compilation of the assets project.
>>
>> Thanks,
>> Robert Munro
>>
>> -----Original Message-----
>> From: discuss <discuss-bounces_at_lists.opencpi.org> On Behalf Of James Kulp
>> Sent: Monday, July 15, 2019 8:52 AM
>> To: discuss_at_lists.opencpi.org
>> Subject: Re: [Discuss OpenCPI] Issue building OCPI components using new RCC platform based on N310 SDK
>>
>> Hi Robert,
>>
>> Thanks for the report.
>> So the configure commands are the same in both cases, but are run in different environments.
>> Perhaps you could dump the environment along with the set -x
>>
>> Jim
>>
>>
>> On 7/12/19 5:53 PM, Munro, Robert M. wrote:
>>> OCPI Development Team,
>>>
>>> An Ettus N310 SDK environment is being integrated into the OCPI build environment to enable building software for the N310 target. The RCC platform has been set up and the core project appears to build successfully using 'ocpidev build project projects/core -rcc -rcc-platform ettus_n310_sdk'.
>>>
>>> When attempting to build the assets project the compiler throws an error when it doesn't find some libraries from the prerequisites. I have attempted using the command 'build/install-prerequisites.sh ettus_n310_sdk' to build and install all required prerequisites, but this fails in the configure operation of gmp. By navigating to the prerequisites-build/gmp/gmp-6.1.2/ocpi-build-ettus_n310_sdk/ and running the prescribed configure, make, make install commands the build completes without error. To see the difference between the two commands 'set +x .. set -x' was added around the configure command in build/prerequisites/gmp/install-gmp.sh .
>>>
>>> Failing configure command:
>>> ../configure --host=arm-oe-linux-gnueabi
>>> --prefix=/home/me/work/me/geontech/opencpi/prerequisites/gmp
>>> --exec-prefix=/home/me/work/me/geontech/opencpi/prerequisites/gmp/ettu
>>> s_n310_sdk --enable-fat=yes --enable-cxx=yes --with-pic
>>>
>>> Failing configure output:
>>> checking whether
>>> /usr/local/oecore-x86_64/sysroots/x86_64-oesdk-linux/usr/bin/arm-oe-li
>>> nux-gnueabi/arm-oe-linux-gnueabi-gcc is gcc... yes checking compiler
>>> /usr/local/oecore-x86_64/sysroots/x86_64-oesdk-linux/usr/bin/arm-oe-li
>>> nux-gnueabi/arm-oe-linux-gnueabi-gcc -O2 -pipe -g
>>> -feliminate-unused-debug-types ... no
>>> configure: error: could not find a working compiler, see config.log
>>> for details
>>>
>>> Working configure command:
>>> ../configure --host=arm-oe-linux-gnueabi
>>> --prefix=/home/me/work/me/geontech/opencpi/prerequisites/gmp
>>> --exec-prefix=/home/me/work/me/geontech/opencpi/prerequisites/gmp/ettu
>>> s_n310_sdk --enable-fat=yes --enable-cxx=yes --with-pic
>>>
>>> Working configure output:
>>> checking whether arm-oe-linux-gnueabi-gcc -march=armv7-a -marm
>>> -mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9
>>> --sysroot=/usr/local/oecore-x86_64/sysroots/cortexa9hf-neon-oe-linux-g
>>> nueabi is gcc... yes checking compiler arm-oe-linux-gnueabi-gcc
>>> -march=armv7-a -marm -mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9
>>> --sysroot=/usr/local/oecore-x86_64/sysroots/cortexa9hf-neon-oe-linux-g
>>> nueabi -O2 -pipe -g -feliminate-unused-debug-types ... yes
>>>
>>> Since the install-prerequisites.sh script fails in gmp library, the liquid, lzma, and gtest libraries must be built and succeed using a similar manual approach. The assets project is then able to build several RCC elements until it reaches the ad9361_config_proxy.so where it is looking for the libad9361.a . After searching in similar places as the build steps for the other prerequisites (build/prerequisites/<library>) the appropriate instructions for manually building the ad9361 library are not able to be found. Where are the build steps described for this library?
>>>
>>> Likewise the build of the build/autotools/ products using this SDK requires manual configuration and is currently failing to complete.
>>>
>>> Is the use of a non-Xilinx SDK unsupported for the framework or are there more elements that can be supplied to the framework to support this use case? A copy of the RCC configuration file is attached for reference.
>>>
>>> Thank you,
>>> Robert Munro
>>> -------------- next part -------------- An HTML attachment was
>>> scrubbed...
>>> URL:
>>> <http://lists.opencpi.org/pipermail/discuss_lists.opencpi.org/attachme
>>> nts/20190712/d87a4d9e/attachment.html>
>>> -------------- next part -------------- A non-text attachment was
>>> scrubbed...
>>> Name: ettus_n310_sdk.mk
>>> Type: application/octet-stream
>>> Size: 2431 bytes
>>> Desc: ettus_n310_sdk.mk
>>> URL:
>>> <http://lists.opencpi.org/pipermail/discuss_lists.opencpi.org/attachme
>>> nts/20190712/d87a4d9e/attachment.mk>
>>> _______________________________________________
>>> discuss mailing list
>>> discuss_at_lists.opencpi.org
>>> http://lists.opencpi.org/mailman/listinfo/discuss_lists.opencpi.org
>>
>> _______________________________________________
>> discuss mailing list
>> discuss_at_lists.opencpi.org
>> http://lists.opencpi.org/mailman/listinfo/discuss_lists.opencpi.org
>




Received on Mon Jul 15 2019 - 19:39:50 CDT

This archive was generated by hypermail 2.3.0 : Fri Jun 05 2026 - 08:45:25 CDT