ucarp: fix build error with gcc-10
PATCH 1/1 ucarp: fix build error with gcc-10
gcc-10 uses '-fno-common' by default, causing multiple definition error. Use '-fcommon' to fix this problem.
--- meta-cgl-common/recipes-cgl/ucarp/ucarp_1.5.2.bb | 3 +++ 1 file changed, 3 insertions(+)
meta-cgl-common/recipes-cgl/ucarp/ucarp_1.5.2.bb +3 -0
@@ -37,6 +37,9 @@ SYSTEMD_AUTO_ENABLE = "disable" export FETCHCMD_wget = "/usr/bin/env wget --secure-protocol=TLSv1_2 -t 2 -T 30 --passive-ftp --no-check-certificate" EXTRA_OECONF += "--sysconfdir=${sysconfdir}/${BPN}" +# Fix build error with gcc-10 +CFLAGS_append = " -fcommon" + # fix the perms for config.rpath do_configure_prepend() { chmod 755 ${S}/config.rpath
Signature · 1 line
2.17.1
Quoted 14 lines · Chen Qi
gcc-10 uses '-fno-common' by default, causing multiple definition error. Use '-fcommon' to fix this problem.
Signed-off-by Chen Qi <[email protected]>--- meta-cgl-common/recipes-cgl/ucarp/ucarp_1.5.2.bb | 3 +++ 1 file changed, 3 insertions(+)meta-cgl-common/recipes-cgl/ucarp/ucarp_1.5.2.bb +0
-0
meta-cgl-common/recipes-cgl/ucarp/ucarp_1.5.2.bb SYSTEMD_AUTO_ENABLE = "disable" · line 42
Quoted 7 lines
meta-cgl-common/recipes-cgl/ucarp/ucarp_1.5.2.bb +3
-1@@ -37,6 +37,9 @@ SYSTEMD_AUTO_ENABLE = "disable" export FETCHCMD_wget = "/usr/bin/env wget --secure-protocol=TLSv1_2 -t 2 -T 30 --passive-ftp --no-check-certificate" EXTRA_OECONF += "--sysconfdir=${sysconfdir}/${BPN}" +# Fix build error with gcc-10 +CFLAGS_append = " -fcommon" +
Why are you not patching the source to use "extern" where it is needed, like in pacemaker? How many errors does ucarp give? Then it might also a patch that upstream will take, solving the issue forever in a proper way.
Quoted 5 lines
meta-cgl-common/recipes-cgl/ucarp/ucarp_1.5.2.bb +0
-0# fix the perms for config.rpath do_configure_prepend() { chmod 755 ${S}/config.rpath
Quoted 19 lines · Bas Mevissen
Quoted 18 lines · Chen Qi
gcc-10 uses '-fno-common' by default, causing multiple definition error. Use '-fcommon' to fix this problem.
Signed-off-by Chen Qi <[email protected]>--- meta-cgl-common/recipes-cgl/ucarp/ucarp_1.5.2.bb | 3 +++ 1 file changed, 3 insertions(+)meta-cgl-common/recipes-cgl/ucarp/ucarp_1.5.2.bb +0
-1@@ -37,6 +37,9 @@ SYSTEMD_AUTO_ENABLE = "disable" export FETCHCMD_wget = "/usr/bin/env wget --secure-protocol=TLSv1_2 -t 2 -T 30 --passive-ftp --no-check-certificate" EXTRA_OECONF += "--sysconfdir=${sysconfdir}/${BPN}"
Quoted 7 lines
meta-cgl-common/recipes-cgl/ucarp/ucarp_1.5.2.bb SYSTEMD_AUTO_ENABLE = "disable" · line 42
Quoted 3 lines
meta-cgl-common/recipes-cgl/ucarp/ucarp_1.5.2.bb +3
-0+# Fix build error with gcc-10 +CFLAGS_append = " -fcommon" +Why are you not patching the source to use "extern" where it is needed, like in pacemaker? How many errors does ucarp give? Then it might also a patch that upstream will take, solving the issue forever in a proper way.
Could you please send out one?
Quoted 7 lines
Quoted 5 lines
meta-cgl-common/recipes-cgl/ucarp/ucarp_1.5.2.bb +0
-0# fix the perms for config.rpath do_configure_prepend() { chmod 755 ${S}/config.rpath
Quoted 28 lines · ChenQi
Quoted 19 lines · Bas Mevissen
Quoted 18 lines · Chen Qi
gcc-10 uses '-fno-common' by default, causing multiple definition error. Use '-fcommon' to fix this problem.
Signed-off-by Chen Qi <[email protected]>--- meta-cgl-common/recipes-cgl/ucarp/ucarp_1.5.2.bb | 3 +++ 1 file changed, 3 insertions(+)meta-cgl-common/recipes-cgl/ucarp/ucarp_1.5.2.bb +0
-1@@ -37,6 +37,9 @@ SYSTEMD_AUTO_ENABLE = "disable" export FETCHCMD_wget = "/usr/bin/env wget --secure-protocol=TLSv1_2 -t 2 -T 30 --passive-ftp --no-check-certificate" EXTRA_OECONF += "--sysconfdir=${sysconfdir}/${BPN}"Quoted 7 lines
meta-cgl-common/recipes-cgl/ucarp/ucarp_1.5.2.bb SYSTEMD_AUTO_ENABLE = "disable" · line 42
Quoted 3 lines
meta-cgl-common/recipes-cgl/ucarp/ucarp_1.5.2.bb +3
-0+# Fix build error with gcc-10 +CFLAGS_append = " -fcommon" +Why are you not patching the source to use "extern" where it is needed, like in pacemaker? How many errors does ucarp give? Then it might also a patch that upstream will take, solving the issue forever in a proper way.
Quoted 2 lines
Could you please send out one?
I don't have a tree with this layer in front of me. I just reviewed your proposed fix by setting the compiler flag, while you demonstrated in the pacemaker patch that the issue is easily solved by adding some "exern"s where they need to be. So I wondered why you didn't do that for ucarp.
Quoted 7 lines
Quoted 7 lines
Quoted 5 lines
meta-cgl-common/recipes-cgl/ucarp/ucarp_1.5.2.bb +0
-0# fix the perms for config.rpath do_configure_prepend() { chmod 755 ${S}/config.rpath