Bug 213867 - devel/boost-libs fails to build on arm64
Summary: devel/boost-libs fails to build on arm64
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: arm64 Any
: --- Affects Only Me
Assignee: FreeBSD Office Team
URL: http://thunderx1.nyi.freebsd.org/data...
Keywords:
Depends on: 199601 212343
Blocks: 201763
  Show dependency treegraph
 
Reported: 2016-10-28 18:45 UTC by Glen Barber
Modified: 2017-01-07 21:27 UTC (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Glen Barber freebsd_committer freebsd_triage 2016-10-28 18:45:55 UTC
clang-linux.compile.c++.without-pch bin.v2/libs/wave/build/clang-linux-3.8.0/release/link-static/threading-multi/token_ids.o
c++: warning: optimization flag '-finline-functions' is not supported
clang-linux.compile.c++.without-pch bin.v2/libs/wave/build/clang-linux-3.8.0/release/link-static/threading-multi/wave_config_constant.o
c++: warning: optimization flag '-finline-functions' is not supported
common.mkdir bin.v2/libs/wave/build/clang-linux-3.8.0/release/link-static/threading-multi/cpplexer
common.mkdir bin.v2/libs/wave/build/clang-linux-3.8.0/release/link-static/threading-multi/cpplexer/re2clex
clang-linux.compile.c++.without-pch bin.v2/libs/wave/build/clang-linux-3.8.0/release/link-static/threading-multi/cpplexer/re2clex/aq.o
c++: warning: optimization flag '-finline-functions' is not supported
clang-linux.compile.c++.without-pch bin.v2/libs/wave/build/clang-linux-3.8.0/release/link-static/threading-multi/cpplexer/re2clex/cpp_re.o
clang-linux.archive bin.v2/libs/wave/build/clang-linux-3.8.0/release/link-static/threading-multi/libboost_wave.a
common.copy stage/lib/libboost_wave.a
...failed updating 6 targets...
...skipped 11 targets...
...updated 880 targets...
*** Error code 1

Stop.
make: stopped in /usr/ports/devel/boost-libs
Comment 1 Jan Beich freebsd_committer freebsd_triage 2016-11-14 05:41:29 UTC
Boost 1.62 also fails but bug 212343 may help.

    "c++" -x assembler-with-cpp -pipe -DLIBICONV_PLUG -fno-strict-aliasing -O3 -Wno-inline -Wall -fPIC -DBOOST_ALL_NO_LIB=1 -DBOOST_CHRONO_DYN_LINK=1 -DBOOST_CONTEXT_DYN_LINK=1 -DBOOST_CONTEXT_SOURCE -DBOOST_DISABLE_ASSERTS -DBOOST_SYSTEM_DYN_LINK=1 -DBOOST_SYSTEM_NO_DEPRECATED -DBOOST_THREAD_BUILD_DLL=1 -DBOOST_THREAD_POSIX -DBOOST_THREAD_USE_DLL=1 -DNDEBUG -I"." -c -o "bin.v2/libs/context/build/clang-linux-3.8.0/release/pch-off/threading-multi/asm/make_arm64_aapcs_elf_gas.o" "libs/context/src/asm/make_arm64_aapcs_elf_gas.S"

libs/context/src/asm/make_arm64_aapcs_elf_gas.S:40:1: error: unknown directive
.cpu generic+fp+simd
^

https://github.com/boostorg/context/blob/develop/src/asm/make_arm64_aapcs_elf_gas.S
Comment 2 Dimitry Andric freebsd_committer freebsd_triage 2016-11-14 19:01:25 UTC
(In reply to Glen Barber from comment #0)
> clang-linux.compile.c++.without-pch
> bin.v2/libs/wave/build/clang-linux-3.8.0/release/link-static/threading-multi/
> token_ids.o
> c++: warning: optimization flag '-finline-functions' is not supported
> clang-linux.compile.c++.without-pch
> bin.v2/libs/wave/build/clang-linux-3.8.0/release/link-static/threading-multi/
> wave_config_constant.o
> c++: warning: optimization flag '-finline-functions' is not supported
> common.mkdir
> bin.v2/libs/wave/build/clang-linux-3.8.0/release/link-static/threading-multi/
> cpplexer
> common.mkdir
> bin.v2/libs/wave/build/clang-linux-3.8.0/release/link-static/threading-multi/
> cpplexer/re2clex
> clang-linux.compile.c++.without-pch
> bin.v2/libs/wave/build/clang-linux-3.8.0/release/link-static/threading-multi/
> cpplexer/re2clex/aq.o
> c++: warning: optimization flag '-finline-functions' is not supported
> clang-linux.compile.c++.without-pch
> bin.v2/libs/wave/build/clang-linux-3.8.0/release/link-static/threading-multi/
> cpplexer/re2clex/cpp_re.o
> clang-linux.archive
> bin.v2/libs/wave/build/clang-linux-3.8.0/release/link-static/threading-multi/
> libboost_wave.a
> common.copy stage/lib/libboost_wave.a
> ...failed updating 6 targets...
> ...skipped 11 targets...
> ...updated 880 targets...
> *** Error code 1
> 
> Stop.
> make: stopped in /usr/ports/devel/boost-libs

The first thing shown in the logs is:

clang-linux.compile.c++.without-pch bin.v2/libs/context/build/clang-linux-3.8.0/release/threading-multi/unsupported.o
c++: warning: optimization flag '-finline-functions' is not supported
libs/context/src/unsupported.cpp:7:2: error: "platform not supported"
#error "platform not supported"
 ^
1 error generated.

So this seems to simply be an unsupported configuration out of the box? Upstream will probably be able to say whether this is going to be supported.
Comment 3 Dimitry Andric freebsd_committer freebsd_triage 2016-11-14 19:04:39 UTC
(In reply to Jan Beich (mail not working) from comment #1)
> Boost 1.62 also fails but bug 212343 may help.
> 
>     "c++" -x assembler-with-cpp -pipe -DLIBICONV_PLUG -fno-strict-aliasing
> -O3 -Wno-inline -Wall -fPIC -DBOOST_ALL_NO_LIB=1 -DBOOST_CHRONO_DYN_LINK=1
> -DBOOST_CONTEXT_DYN_LINK=1 -DBOOST_CONTEXT_SOURCE -DBOOST_DISABLE_ASSERTS
> -DBOOST_SYSTEM_DYN_LINK=1 -DBOOST_SYSTEM_NO_DEPRECATED
> -DBOOST_THREAD_BUILD_DLL=1 -DBOOST_THREAD_POSIX -DBOOST_THREAD_USE_DLL=1
> -DNDEBUG -I"." -c -o
> "bin.v2/libs/context/build/clang-linux-3.8.0/release/pch-off/threading-multi/
> asm/make_arm64_aapcs_elf_gas.o"
> "libs/context/src/asm/make_arm64_aapcs_elf_gas.S"
> 
> libs/context/src/asm/make_arm64_aapcs_elf_gas.S:40:1: error: unknown
> directive
> .cpu generic+fp+simd
> ^
> 
> https://github.com/boostorg/context/blob/develop/src/asm/
> make_arm64_aapcs_elf_gas.S

I can confirm that clang 3.9.0 assembles this file, at least with a rudimentary command line:

clang-3.9.0 -target aarch64-freebsd -c make_arm64_aapcs_elf_gas.S
Comment 4 Andrew Turner freebsd_committer freebsd_triage 2016-11-14 19:54:48 UTC
It needs the FreeBSD/arm64 bits added, however I've been waiting for boost to first be updated to a version that supports arm64.
Comment 5 Andrew Turner freebsd_committer freebsd_triage 2016-11-23 18:15:05 UTC
This seems to build with the update to boost.
Comment 6 Jan Beich freebsd_committer freebsd_triage 2016-11-25 05:23:42 UTC
(In reply to Andrew Turner from comment #5)
> This seems to build with the update to boost.

thunderx1 disagrees, boost-libs still fails to build on aarch64.
Comment 7 Ed Maste freebsd_committer freebsd_triage 2016-11-25 15:31:05 UTC
For convenience, from the log:

clang-linux.compile.asm bin.v2/libs/context/build/clang-linux-3.8.0/release/link-static/pch-off/threading-multi/asm/make_arm64_aapcs_elf_gas.o

    "c++" -x assembler-with-cpp -pipe -DLIBICONV_PLUG -fno-strict-aliasing -O3 -Wno-inline -Wall -DBOOST_ALL_NO_LIB=1 -DBOOST_CHRONO_STATIC_LINK=1 -DBOOST_CONTEXT_SOURCE -DBOOST_DISABLE_ASSERTS -DBOOST_SYSTEM_NO_DEPRECATED -DBOOST_SYSTEM_STATIC_LINK=1 -DBOOST_THREAD_BUILD_LIB=1 -DBOOST_THREAD_POSIX -DBOOST_THREAD_USE_LIB=1 -DNDEBUG -I"." -c -o "bin.v2/libs/context/build/clang-linux-3.8.0/release/link-static/pch-off/threading-multi/asm/make_arm64_aapcs_elf_gas.o" "libs/context/src/asm/make_arm64_aapcs_elf_gas.S"

libs/context/src/asm/make_arm64_aapcs_elf_gas.S:40:1: error: unknown directive
.cpu generic+fp+simd
^
...failed clang-linux.compile.asm bin.v2/libs/context/build/clang-linux-3.8.0/release/link-static/pch-off/threading-multi/asm/make_arm64_aapcs_elf_gas.o...
Comment 8 commit-hook freebsd_committer freebsd_triage 2017-01-01 10:51:21 UTC
A commit references this bug:

Author: jbeich
Date: Sun Jan  1 10:50:48 UTC 2017
New revision: 430247
URL: https://svnweb.freebsd.org/changeset/ports/430247

Log:
  devel/boost-libs: unblock aarch64 and sparc64 builds

  - aarch64 requires Clang with new enough integrated assembler
  - sparc64 is no longer supported since we don't split context library
    into a separate package (unlike Debian)

  PR:		213867 214942
  MFH:		2016Q4

Changes:
  head/devel/boost-libs/Makefile
Comment 9 commit-hook freebsd_committer freebsd_triage 2017-01-01 11:46:08 UTC
A commit references this bug:

Author: jbeich
Date: Sun Jan  1 11:45:29 UTC 2017
New revision: 430248
URL: https://svnweb.freebsd.org/changeset/ports/430248

Log:
  devel/boost-libs: oops, work around ${CC} usage after r430247

  $ make -V '${MAKE_ARGS:M--toolset*}'
  /bin/sh: clang39: not found
  make: "/usr/ports/Mk/Uses/compiler.mk" line 69: warning: "clang39 --version" returned non-zero status
  make: "/usr/ports/Mk/Uses/compiler.mk" line 120: warning: "clang++39 -### /dev/null 2>&1" returned non-zero status
  --toolset=gcc

  PR:		213867
  MFH:		2016Q4 (r430247 followup)

Changes:
  head/devel/boost-libs/Makefile
Comment 10 commit-hook freebsd_committer freebsd_triage 2017-01-01 13:47:47 UTC
A commit references this bug:

Author: jbeich
Date: Sun Jan  1 13:47:20 UTC 2017
New revision: 430253
URL: https://svnweb.freebsd.org/changeset/ports/430253

Log:
  devel/boost-libs: -no-integrated-as builds faster

  aarch64 doesn't have /usr/bin/as, so it's fine to use PATH

  PR:		213867

Changes:
  head/devel/boost-libs/Makefile
Comment 12 commit-hook freebsd_committer freebsd_triage 2017-01-07 06:25:16 UTC
A commit references this bug:

Author: jbeich
Date: Sat Jan  7 06:24:45 UTC 2017
New revision: 430767
URL: https://svnweb.freebsd.org/changeset/ports/430767

Log:
  devel/boost-libs: drop -no-integrated-as on aarch64

  PR:		213867
  Obtained from:	upstream
  MFH:		2017Q1

Changes:
  head/devel/boost-libs/Makefile
  head/devel/boost-libs/files/patch-clang-as
Comment 13 commit-hook freebsd_committer freebsd_triage 2017-01-07 21:27:31 UTC
A commit references this bug:

Author: jbeich
Date: Sat Jan  7 21:27:07 UTC 2017
New revision: 430835
URL: https://svnweb.freebsd.org/changeset/ports/430835

Log:
  MFH: r430767

  devel/boost-libs: drop -no-integrated-as on aarch64

  PR:		213867
  Obtained from:	upstream
  Approved by:	ports-secteam (junovitch)

Changes:
_U  branches/2017Q1/
  branches/2017Q1/devel/boost-libs/Makefile
  branches/2017Q1/devel/boost-libs/files/patch-clang-as