Created attachment 179138 [details] science/tfel port update patch to version 3.00 I have been working with the author, who wants to support FreeBSD at the same level as linux. As a result the PYTHON option will now add all the bindings, and a bug where the package was using machine arch optimizations (and core dumping on others) is now fixed. Both patches in files/ have been upstreamed and can be removed in a future update. The new version brings important support for Abaqus(TM) and will be supported in a future release of CalculiX.
Note:french/aster is strongly tied with science/tfel, and for example the latest update to 2.0.4 broke french/aster. It was building fine with tfel-mfront-2.0.3, but with tfel-mfront-2.0.4, it produces the following error: /usr/local/bin/ld: bibcxx/mfront/MFrontBehaviour.cxx.1.o: undefined reference to symbol '_ZNSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE6__initEPKcm' //usr/local/lib/libc++.so.1: error adding symbols: DSO missing from command line collect2: error: ld returned 1 exit status and I'm still investigating how I could fix it. Besides that, I am working on upgrading Code_Aster to 12.7.0-1, but it is also breaking, caused by the same kind of errors related to MFrontBehaviour. Would it be possible to repocopy this port, with a stable version known to be working with Code_Aster, and another one to follow the new releases?
(In reply to Thierry Thomas from comment #1) To be more precise, here is the error message without an interference with /usr/local/lib/libc++.so.1: /usr/local/bin/ld: bibcxx/mfront/MFrontBehaviour.cxx.1.o: undefined reference to symbol '_ZNSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE6__initEPKcm' //usr/lib/libc++.so.1: error adding symbols: DSO missing from command line collect2: error: ld returned 1 exit status (same problem)
(In reply to Thierry Thomas from comment #1) I cc'd privately the author. I would like to get some feedback from him first but if needed we can revert the port and I can enhance the port options there. The PACKAGE_BUILDING change should be particularly important. I don't like the idea of introducing two different ports but I would like to have tfel 3.0.0 for the next CalculiX version: if for some reason it doesn't work with code Aster, we can have a tfel-calculix and a tfel-aster.
Seem with Thomas Helfer: the problem was not caused by the upgrade of tfel from 2.0.3 to 2.0.4, but caused by the upgrade of Gcc / gfortran from 4.8 to 4.9. A work-around is to link explicitly with libc++ (committed in r432159).
This version seems OK, but unfortunately, it breaks french/aster: In file included from mfront/AnisoLemaitre/src/AnisoLemaitre.cxx:15: In file included from /usr/ports/french/aster/work/install_aster.95211/aster-12.6.0/build/release/mfront/AnisoLemaitre/include/TFEL/Material/AnisoLemaitreBehaviourData.hxx:20: In file included from /usr/local/include/TFEL/Config/TFELTypes.hxx:24: /usr/local/include/TFEL/Math/Stensor/StensorSizeToDime.hxx:59:14: error: unknown type name 'constexpr' static constexpr unsigned short value = 3u; ^ /usr/local/include/TFEL/Math/Stensor/StensorSizeToDime.hxx:59:24: error: expected member name or ';' after declaration specifiers static constexpr unsigned short value = 3u; ~~~~~~~~~~~~~~~~ ^ /usr/local/include/TFEL/Math/Stensor/StensorSizeToDime.hxx:68:14: error: unknown type name 'constexpr' static constexpr unsigned short value = 4u; ^ /usr/local/include/TFEL/Math/Stensor/StensorSizeToDime.hxx:68:24: error: expected member name or ';' after declaration specifiers static constexpr unsigned short value = 4u; ~~~~~~~~~~~~~~~~ ^ /usr/local/include/TFEL/Math/Stensor/StensorSizeToDime.hxx:77:14: error: unknown type name 'constexpr' static constexpr unsigned short value = 6u; ^ /usr/local/include/TFEL/Math/Stensor/StensorSizeToDime.hxx:77:24: error: expected member name or ';' after declaration specifiers static constexpr unsigned short value = 6u; ~~~~~~~~~~~~~~~~ ^ /usr/local/include/TFEL/Math/Stensor/StensorSizeToDime.hxx:86:14: error: unknown type name 'constexpr' static constexpr unsigned short value = 1u; ^ /usr/local/include/TFEL/Math/Stensor/StensorSizeToDime.hxx:86:24: error: expected member name or ';' after declaration specifiers static constexpr unsigned short value = 1u; ~~~~~~~~~~~~~~~~ ^ /usr/local/include/TFEL/Math/Stensor/StensorSizeToDime.hxx:95:14: error: unknown type name 'constexpr' static constexpr unsigned short value = 2u; ^ /usr/local/include/TFEL/Math/Stensor/StensorSizeToDime.hxx:95:24: error: expected member name or ';' after declaration specifiers static constexpr unsigned short value = 2u; ~~~~~~~~~~~~~~~~ ^ /usr/local/include/TFEL/Math/Stensor/StensorSizeToDime.hxx:104:14: error: unknown type name 'constexpr' static constexpr unsigned short value = 3u; ^ /usr/local/include/TFEL/Math/Stensor/StensorSizeToDime.hxx:104:24: error: expected member name or ';' after declaration specifiers static constexpr unsigned short value = 3u; ~~~~~~~~~~~~~~~~ ^ In file included from mfront/AnisoLemaitre/src/AnisoLemaitre.cxx:15: In file included from /usr/ports/french/aster/work/install_aster.95211/aster-12.6.0/build/release/mfront/AnisoLemaitre/include/TFEL/Material/AnisoLemaitreBehaviourData.hxx:20: In file included from /usr/local/include/TFEL/Config/TFELTypes.hxx:25: /usr/local/include/TFEL/Math/Tensor/TensorSizeToDime.hxx:59:14: error: unknown type name 'constexpr' static constexpr unsigned short value = 3u; ^ /usr/local/include/TFEL/Math/Tensor/TensorSizeToDime.hxx:59:24: error: expected member name or ';' after declaration specifiers static constexpr unsigned short value = 3u; ~~~~~~~~~~~~~~~~ ^ /usr/local/include/TFEL/Math/Tensor/TensorSizeToDime.hxx:68:14: error: unknown type name 'constexpr' static constexpr unsigned short value = 5u; ^ /usr/local/include/TFEL/Math/Tensor/TensorSizeToDime.hxx:68:24: error: expected member name or ';' after declaration specifiers static constexpr unsigned short value = 5u; ~~~~~~~~~~~~~~~~ ^ /usr/local/include/TFEL/Math/Tensor/TensorSizeToDime.hxx:77:14: error: unknown type name 'constexpr' static constexpr unsigned short value = 9u; ^ /usr/local/include/TFEL/Math/Tensor/TensorSizeToDime.hxx:77:24: error: expected member name or ';' after declaration specifiers static constexpr unsigned short value = 9u; ~~~~~~~~~~~~~~~~ ^ /usr/local/include/TFEL/Math/Tensor/TensorSizeToDime.hxx:86:14: error: unknown type name 'constexpr' static constexpr unsigned short value = 1u; ^ fatal error: too many errors emitted, stopping now [-ferror-limit=] The problem could be that the version of Code_Aster in the tree is too old, and I have to upgrade it first.
(In reply to Thierry Thomas from comment #5) Thanks for looking. I am looking at updating CalculiX but it appears they haven't added support for this yet so I can wait. Adding this part of the patch to the existing port Makefile is a good idea though: +.ifdef PACKAGE_BUILDING +CONFIGURE_ARGS+= --enable-portable-build +.endif The tfel author reported that without it packages built on processors different than the packaging machines are broken.
This part `--enable-portable-build' is already in the Makefile, and I've just rebuilt tfel-mfront-3.0.0 with -DPACKAGE_BUILDING, but french/aster still fails with the same error.
(In reply to Thierry Thomas from comment #7) Egh ... yes, I meant we should backport the "--enable-portable-build" to the tfel-2.0.4 port. I can wait for 3.0.0: it was not needed for the new Calculix. The aster build issue seems GCC5 related: it is probably solved by specifying C++11 to the compiler.
Ah, sorry! But there is no problem with tfel-2.0.4, Code_Aster (at least the version in the tree, 12.6.0.4), builds fine with it. BTW, why do you restrict this portable-build to PACKAGE_BUILDING and not for the port?
(In reply to Thierry Thomas from comment #9) > BTW, why do you restrict this portable-build to PACKAGE_BUILDING and not for the port? Because I am fine with the port doing architecture-specific optimizations when *I* build the port. I think the build machines are Intel Xeon machines and the binaries may not work on AMD or perhaps even on Core2 or nocona. OTOH people having older CPUs have more need of the arch-specific optimizations. This way things work well for both.
OK, these are good reasons!
Created attachment 182263 [details] enhance tfel-2.0.4 May I suggest we apply this small cleanup patch to the existing 2.0.4 ... it should reduce the size of the diff for 3.00, and it fixes the packaging issue.
A commit references this bug: Author: thierry Date: Thu May 4 20:30:48 UTC 2017 New revision: 440115 URL: https://svnweb.freebsd.org/changeset/ports/440115 Log: Cleanup. PR: 216315 Submitted by: pfg Changes: head/science/tfel/Makefile
Committed thanks!
Created attachment 182309 [details] updated patch for science/tfel 3.00 Now that the older tfel-2.0.4 has been cleaned up, the 3.00 patch looks better. Still we have to hold until code aster can handle it.
(In reply to Pedro F. Giffuni from comment #15) BTW ... note that the tfel configure.ac patch has this line: COMPILER_CXXFLAGS="-std=c++11" Code Aster will likely need something like that.
Pedro, Finally, I've just upgraded Code_Aster to the latest stable version, but I have not been able to enable MFront, neither form this port nor from the one bundled with aster. Then, it's now possible to do what you want with this PR. Do you have a patch ready for 3.0?
(In reply to Thierry Thomas from comment #17) This attachment in this PR is/was meant for 3.0.0. I just noticed it needs to be updated to 3.0.2 (I will look at updating it).
Created attachment 188002 [details] Update to tfel-3.0.2 Only lightly tested... may need plist tweaking.
Created attachment 188104 [details] Update to version 3.0.2 Oops .. some cleanup to the python option
Committed, thanks!
A commit references this bug: Author: thierry Date: Sat Nov 25 10:43:57 UTC 2017 New revision: 454878 URL: https://svnweb.freebsd.org/changeset/ports/454878 Log: Upgrade to 3.0.2. The new version brings important support for Abaqus(TM) and will be supported in a future release of CalculiX. PR: 216315 Submitted by: Pedro F. Giffuni Changes: head/science/tfel/Makefile head/science/tfel/distinfo head/science/tfel/files/ head/science/tfel/pkg-plist