Skip to contentSkip to conversation

fftw: Remove hardcoded sysroot into binaries

PATCH In review Khem Raj 2 participants 3 messages May 14, 2023 – May 23, 2023

lore
Share & tools
lore

Khem Raj

author
#0 lore raw

PATCH 1/1 fftw: Remove hardcoded sysroot into binaries

FFTW_CC is added to image via version.o and its CC + CFLAGS however CC in OE containes --syroot compiler option which encodes buildpaths into binary, therefore remove this option from FFTW_CC in config.h

---
 meta-oe/recipes-support/fftw/fftw_3.3.10.bb | 1 +
 1 file changed, 1 insertion(+)
meta-oe/recipes-support/fftw/fftw_3.3.10.bb +1 -0
index cb45e2b91f..1fead4d029 100644
@@ -55,6 +55,7 @@ do_configure() {
 do_compile() {
     for lib in fftw fftwl fftwf; do
         cd ${WORKDIR}/build-$lib
+        sed -i -e 's|${TOOLCHAIN_OPTIONS}||g' config.h
         autotools_do_compile
     done
 }
Signature · 1 line
2.40.1
#1 lore raw

Hi,

Could it be this is causing a failure (see below)

Thanks,

DEBUG: Executing python function autotools_aclocals
DEBUG: SITE files ['endian-little', 'common-linux', 'common-glibc',
'bit-64', 'x86_64-linux', 'common']
DEBUG: Python function autotools_aclocals finished
DEBUG: Executing shell function do_compile
sed: -e expression #1, char 0: no previous regular expression
WARNING: .../build/tmp/work/x86_64-linux/fftw-native/3.3.10-r0/temp/run.do_compile.464684:153 exit 1 from 'sed -i -e 's|||g' config.h'
WARNING: Backtrace (BB generated script):

        #1: do_compile,
.../build/tmp/work/x86_64-linux/fftw-native/3.3.10-r0/temp/run.do_compile.464684,
line 153
        #2: main,

.../build/tmp/work/x86_64-linux/fftw-native/3.3.10-r0/temp/run.do_compile.464684, line 199

Quoted 34 lines · Khem Raj

FFTW_CC is added to image via version.o and its CC + CFLAGS however CC in OE containes --syroot compiler option which encodes buildpaths into binary, therefore remove this option from FFTW_CC in config.h

---
 meta-oe/recipes-support/fftw/fftw_3.3.10.bb | 1 +
 1 file changed, 1 insertion(+)
meta-oe/recipes-support/fftw/fftw_3.3.10.bb +1 -1
index cb45e2b91f..1fead4d029 100644
@@ -55,6 +55,7 @@ do_configure() {
 do_compile() {
     for lib in fftw fftwl fftwf; do
         cd ${WORKDIR}/build-$lib
+        sed -i -e 's|${TOOLCHAIN_OPTIONS}||g' config.h
         autotools_do_compile
     done
 }
--

2.40.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#102563): https://lists.openembedded.org/g/openembedded-devel/message/102563
Mute This Topic: https://lists.openembedded.org/mt/98879626/2167232
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub [[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Signature · 2 lines
Jan Vermaete
“Success is a self-correcting phenomenom.” -- Gary Hamel
author
#2 lore raw
Quoted 5 lines · jan vermaete

Hi,

Could it be this is causing a failure (see below)

Yes, it seems that we need to check for TOOLCHAIN_OPTIONS to be not empty which is the case when
building the native recipe.

Quoted 58 lines

Thanks,

DEBUG: Executing python function autotools_aclocals
DEBUG: SITE files ['endian-little', 'common-linux', 'common-glibc',
'bit-64', 'x86_64-linux', 'common']
DEBUG: Python function autotools_aclocals finished
DEBUG: Executing shell function do_compile
sed: -e expression #1, char 0: no previous regular expression
WARNING: .../build/tmp/work/x86_64-linux/fftw-native/3.3.10-r0/temp/run.do_compile.464684:153 exit 1 from 'sed -i -e 's|||g' config.h'
WARNING: Backtrace (BB generated script):

        #1: do_compile,
.../build/tmp/work/x86_64-linux/fftw-native/3.3.10-r0/temp/run.do_compile.464684,
line 153
        #2: main,

.../build/tmp/work/x86_64-linux/fftw-native/3.3.10-r0/temp/run.do_compile.464684, line 199

Quoted 26 lines · Khem Raj

FFTW_CC is added to image via version.o and its CC + CFLAGS however CC in OE containes --syroot compiler option which encodes buildpaths into binary, therefore remove this option from FFTW_CC in config.h

---
 meta-oe/recipes-support/fftw/fftw_3.3.10.bb | 1 +
 1 file changed, 1 insertion(+)
meta-oe/recipes-support/fftw/fftw_3.3.10.bb +1 -1
index cb45e2b91f..1fead4d029 100644
@@ -55,6 +55,7 @@ do_configure() {
 do_compile() {
     for lib in fftw fftwl fftwf; do
         cd ${WORKDIR}/build-$lib
+        sed -i -e 's|${TOOLCHAIN_OPTIONS}||g' config.h
         autotools_do_compile
     done
 }
--

2.40.1

Quoted 8 lines

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#102563): https://lists.openembedded.org/g/openembedded-devel/message/102563
Mute This Topic: https://lists.openembedded.org/mt/98879626/2167232
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub [[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

--
Jan Vermaete
“Success is a self-correcting phenomenom.” -- Gary Hamel