https://bugs.linaro.org/show_bug.cgi?id=2510

            Bug ID: 2510
           Summary: ODP build system broken
           Product: OpenDataPlane - linux- generic reference
           Version: unspecified
          Hardware: Other
                OS: Linux
            Status: UNCONFIRMED
          Severity: critical
          Priority: ---
         Component: Build system
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected]
  Target Milestone: ---

Overview: ODP build broken by the "linux-generic: configure: add conditional
shared library support" commit.

Build of ODP fails if started from a build-folder instead of directly from the
odp-root.

Steps to Reproduce: 
<odp-root>$ ./bootstrap
<odp-root>$ mkdir mybuild-dir
<odp-root>$ cd mybuild-dir
<odp-root>/mybuild-dir$ ../configure
<odp-root>/mybuild-dir$ make
...
...
make[1]: *** No rule to make target
'../../../platform/linux-generic/include/odp/api/plat/inlines.h', needed by
'all-am'.  Stop.
 -> NOK!

The build works if compiled from the odp-root:
<odp-root>$ ./bootstrap
<odp-root>$ ./configure
<odp-root>$ make
 -> OK!

---
Also another issue was found: using the new configure option
"--enable-shared=no" breaks the build of an external application being linked
against the installed libodp:
<odp-root>$ ./bootstrap
<odp-root>$ ./configure --enable-shared=no
<odp-root>$ make
<odp-root>$ make install

<app-root>$ ./bootstrap
<app-root>$ ./configure --with-odp-path=<odp_install path>
<app-root>$ make
...
/usr/bin/ld: <odp_install>/lib/libodp-linux.a(odp_cpumask.o): relocation
R_X86_64_32 against `odp_global_data' can not be used when making a shared
object; recompile with -fPIC
<odp_install>/lib/libodp-linux.a: error adding symbols: Bad value
collect2: error: ld returned 1 exit status


Bug found when using the following ODP commit from master branch:
---------------------------------------------------------------------
Commit: da7a72e86db0cf83f7b391d8516f9b7504f4e27a [da7a72e]
Parents: a7f5589f81
Author: Bill Fischofer <[email protected]>
Date: 31. elokuuta 2016 4:37:25
Committer: Maxim Uvarov <[email protected]>
Commit Date: 7. syyskuuta 2016 16:07:37
linux-generic: configure: add conditional shared library support

Add support for the --enable-shared=[yes|no] configure options.
--enable-shared=yes is the default and results in suppressing the use
of inlines for ODP API functions to enhance ABI compatibility at
potentially some performance cost. When --enable-shared=no is specified,
inlines are allowed to boost performance at the possible loss of ABI
compatibility.

This patch addresses Bug https://bugs.linaro.org/show_bug.cgi?id=2490

Note: This patch is a port of the corresponding enhancements made to
odp-dpdk with a few changes, mainly that inlines are now part of the
odp/api/plat directory, and all ODP APIs are now treated uniformly with
regard to whether inlining is permitted.

Suggested-by: Zoltan Kiss <[email protected]>
Signed-off-by: Bill Fischofer <[email protected]>
Reviewed-by: Balakrishna Garapati <[email protected]>
Signed-off-by: Maxim Uvarov <[email protected]>
---------------------------------------------------------------------

-- 
You are receiving this mail because:
You are on the CC list for the bug.

Reply via email to