You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by "Marton Szasz (Jira)" <ji...@apache.org> on 2020/07/22 14:02:00 UTC

[jira] [Resolved] (MINIFICPP-1301) Cannot compile with GCC 10

     [ https://issues.apache.org/jira/browse/MINIFICPP-1301?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Marton Szasz resolved MINIFICPP-1301.
-------------------------------------
      Assignee: Marton Szasz
    Resolution: Invalid

After things started to improve on every related change, I realized that ccache might be at fault. A local ccache purge solved the issue, it has nothing to do with minifi.

> Cannot compile with GCC 10
> --------------------------
>
>                 Key: MINIFICPP-1301
>                 URL: https://issues.apache.org/jira/browse/MINIFICPP-1301
>             Project: Apache NiFi MiNiFi C++
>          Issue Type: Bug
>            Reporter: Marton Szasz
>            Assignee: Marton Szasz
>            Priority: Major
>
> Compilation with GCC 10 fails, most likely due to the switch from {{-fcommon}} to {{-fno-common}} behavior.
> see: [https://wiki.gentoo.org/wiki/Gcc_10_porting_notes/fno_common] and [https://gcc.gnu.org/gcc-10/porting_to.html]
> Error:
> {{[ 52%] Linking CXX executable minifi}}
>  {{/usr/lib/gcc/x86_64-pc-linux-gnu/10.1.0/../../../../x86_64-pc-linux-gnu/bin/ld: ../libminifi/libcore-minifi.a(SSLContextService.cpp.o): in function `sk_X509_num':}}
>  {{/usr/include/openssl/x509.h:99: undefined reference to `OPENSSL_sk_num'}}
>  {{/usr/lib/gcc/x86_64-pc-linux-gnu/10.1.0/../../../../x86_64-pc-linux-gnu/bin/ld: ../libminifi/libcore-minifi.a(SSLContextService.cpp.o): in function `sk_X509_pop':}}
>  {{/usr/include/openssl/x509.h:99: undefined reference to `OPENSSL_sk_pop'}}
>  {{/usr/lib/gcc/x86_64-pc-linux-gnu/10.1.0/../../../../x86_64-pc-linux-gnu/bin/ld: ../libminifi/libcore-minifi.a(SSLContextService.cpp.o): in function `sk_X509_pop_free':}}
>  {{/usr/include/openssl/x509.h:99: undefined reference to `OPENSSL_sk_pop_free'}}
>  {{collect2: error: ld returned 1 exit status}}
>  {{gmake[2]: *** [main/CMakeFiles/minifiexe.dir/build.make:178: main/minifi] Error 1}}
>  {{gmake[1]: *** [CMakeFiles/Makefile2:3567: main/CMakeFiles/minifiexe.dir/all] Error 2}}
>  {{gmake: *** [Makefile:183: all] Error 2}}
>  
>  Workaround: Add {{-fcommon}} to your CFLAGS and CXXFLAGS



--
This message was sent by Atlassian Jira
(v8.3.4#803005)