error: command 'gcc' failed with exit status 1

592 views
Skip to first unread message

Carl Lundholm

unread,
Feb 5, 2016, 8:54:53 AM2/5/16
to fenics-...@googlegroups.com, pet...@student.chalmers.se
Hi!

We get the following error message when we try to install the FEniCS development version.

[ffc]   tail -f /Users/Petter/.hashdist/tmp/ffc-tu3lvr3hhaoe-3/_hashdist/build.log
[ffc|ERROR] Command '[u'/bin/bash', '_hashdist/build.sh']' returned non-zero exit status 1
[ffc|ERROR] command failed (code=1); raising
dhcp-202064:~ Petter$ less /Users/Petter/.hashdist/tmp/ffc-tu3lvr3hhaoe-3/_hashdist/build.log

2016/02/04 15:26:46 - INFO: [package:run_job] /Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/iosfwd:193:33: note: template is declared here
2016/02/04 15:26:46 - INFO: [package:run_job]     class _LIBCPP_TYPE_VIS_ONLY basic_string;
2016/02/04 15:26:46 - INFO: [package:run_job]                                 ^
2016/02/04 15:26:46 - INFO: [package:run_job] ufc/ufc_wrap.cpp:4548:49: error: implicit instantiation of undefined template 'std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >'
2016/02/04 15:26:46 - INFO: [package:run_job]   result = ((ufc::finite_element const *)arg1)->family();
2016/02/04 15:26:46 - INFO: [package:run_job]                                                 ^
2016/02/04 15:26:46 - INFO: [package:run_job] /Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/iosfwd:193:33: note: template is declared here
2016/02/04 15:26:46 - INFO: [package:run_job]     class _LIBCPP_TYPE_VIS_ONLY basic_string;
2016/02/04 15:26:46 - INFO: [package:run_job]                                 ^
2016/02/04 15:26:46 - INFO: [package:run_job] 2 errors generated.
2016/02/04 15:26:46 - INFO: [package:run_job] error: command 'gcc' failed with exit status 1
2016/02/04 15:26:46 - ERROR: [package:run_job] Command '[u'/bin/bash', '_hashdist/build.sh']' returned non-zero exit status 1
2016/02/04 15:26:46 - ERROR: [package:run_job] command failed (code=1); raising

Does anyone have any ideas on what the cause might be and/or how to fix this?

Regards
Carl 

Johannes Ring

unread,
Feb 8, 2016, 8:08:17 AM2/8/16
to Carl Lundholm, fenics-...@googlegroups.com, pet...@student.chalmers.se
It looks like you are running OS X. Which version? Your compiler might
be too old. Can you do `gcc --version` in the terminal?

Johannes
> --
> You received this message because you are subscribed to the Google Groups
> "fenics-support" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to fenics-suppor...@googlegroups.com.
> To post to this group, send email to fenics-...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/fenics-support/1D93E40BCA3A6649BAEF0B3130AF0BC7BA147B%40wrex.ita.chalmers.se.
> For more options, visit https://groups.google.com/d/optout.

Johannes Ring

unread,
Feb 9, 2016, 2:43:20 AM2/9/16
to Petter Rosander, Carl Lundholm, fenics-support
[please cc fenics-support]

Thanks. I have now reproduced the error and reported the problem here:
https://bitbucket.org/fenics-project/ffc/issues/98/ffc-fails-to-build-on-os-x

Johannes

On Mon, Feb 8, 2016 at 5:22 PM, Petter Rosander
<pet...@student.chalmers.se> wrote:
> Hello Johannes!
>
> dhcp-238076:~ Petter$ gcc --version
> Configured with: --prefix=/Library/Developer/CommandLineTools/usr
> --with-gxx-include-dir=/usr/include/c++/4.2.1
> Apple LLVM version 7.0.2 (clang-700.1.81)
> Target: x86_64-apple-darwin15.2.0
> Thread model: posix
> Version: OS X El Capitan (10.11.2)
>
> Best regards,
> Petter

Anders Logg

unread,
Feb 11, 2016, 10:52:29 AM2/11/16
to Johannes Ring, Petter Rosander, Carl Lundholm, fenics-support
Same / similar problem here:

gcc -fno-strict-aliasing -fno-common -dynamic -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Iufc -I/Users/logg/.hashdist/bld/profile/y7qlmbtacuwo/lib/python2.7/site-packages/numpy/core/include -I/Users/logg/.hashdist/bld/python/k3rasqqukeuc/Python.framework/Versions/2.7/include/python2.7 -c ufc/ufc_wrap.cpp -o build/temp.macosx-10.10-x86_64-2.7/ufc/ufc_wrap.o -std=c++11
ufc/ufc_wrap.cpp:4529:15: error: implicit instantiation of undefined template
      'std::__1::basic_string<char, std::__1::char_traits<char>,
      std::__1::allocator<char> >'
  std::string result;
              ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../include/c++/v1/iosfwd:193:33: note:
      template is declared here
    class _LIBCPP_TYPE_VIS_ONLY basic_string;
                                ^
ufc/ufc_wrap.cpp:4548:49: error: implicit instantiation of undefined template
      'std::__1::basic_string<char, std::__1::char_traits<char>,
      std::__1::allocator<char> >'
  result = ((ufc::finite_element const *)arg1)->family();
                                                ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../include/c++/v1/iosfwd:193:33: note:
      template is declared here
    class _LIBCPP_TYPE_VIS_ONLY basic_string;
                                ^
2 errors generated.
error: command 'gcc' failed with exit status 1

--
Anders


tis 9 feb. 2016 kl 08:43 skrev Johannes Ring <joh...@simula.no>:
[please cc fenics-support]

Thanks. I have now reproduced the error and reported the problem here:
https://bitbucket.org/fenics-project/ffc/issues/98/ffc-fails-to-build-on-os-x

Johannes

On Mon, Feb 8, 2016 at 5:22 PM, Petter Rosander
<pet...@student.chalmers.se> wrote:
> Hello Johannes!
>
> dhcp-238076:~ Petter$ gcc --version
> Configured with: --prefix=/Library/Developer/CommandLineTools/usr
> --with-gxx-include-dir=/usr/include/c++/4.2.1
> Apple LLVM version 7.0.2 (clang-700.1.81)
> Target: x86_64-apple-darwin15.2.0
> Thread model: posix
> Version:  OS X El Capitan (10.11.2)
>
> Best regards,
> Petter
>
> 8 feb. 2016 kl. 14:08 skrev Johannes Ring <joh...@simula.no>:
>

Jan Blechta

unread,
Feb 11, 2016, 11:08:49 AM2/11/16
to Anders Logg, Martin Sandve Alnæs, Johannes Ring, Petter Rosander, Carl Lundholm, fenics-support
Seems like an effect of
https://bitbucket.org/fenics-project/ffc/pull-requests/26/add-family-and-degree-to-ufc

Adding
#include <string>
to <ffc>/ufc/ufc.h could help.

Martin, there are other stringy returns handled using char*. Should we
make it uniform?

Jan

Martin Sandve Alnæs

unread,
Feb 11, 2016, 11:41:01 AM2/11/16
to Jan Blechta, Johannes Ring, fenics-support, Anders Logg, Carl Lundholm, Petter Rosander

Just commented on the issue.

I think using const char * is better, as long as we return fixed strings there is no need for the string class. Including <string> may affect compile times.

Martin

Anders Logg

unread,
Feb 12, 2016, 4:49:57 AM2/12/16
to Martin Sandve Alnæs, Jan Blechta, Johannes Ring, fenics-support, Carl Lundholm, Petter Rosander
This is fixed now.

--
Anders

Reply all
Reply to author
Forward
0 new messages