Create thin archive and convert it afterwards
While this worked fine on rawhide, the MRI script is not accepted on f37. Apparently + is a special character and something we end up trying to use libc rather than libc++.a. Avoid this by creating a thin archive first and then only using the MRI script to convert it into a fat archive. Weird that there is apparently no native way to do this.
This commit is contained in:
parent
a9f42b025d
commit
f1dbfefcca
|
@ -108,13 +108,16 @@ common_cmake_flags="\
|
|||
LIBCXX_A=`find $PWD -name libc++.a`
|
||||
mkdir results-static
|
||||
pushd results-static
|
||||
# Create thin archive
|
||||
ar cqT tmp.a $LIBCXX_A %{_libdir}/libc++abi.a
|
||||
# Convert into normal archive
|
||||
ar -M <<EOM
|
||||
CREATE libc++.a
|
||||
ADDLIB $LIBCXX_A
|
||||
ADDLIB %{_libdir}/libc++abi.a
|
||||
CREATE tmp.a
|
||||
ADDLIB tmp.a
|
||||
SAVE
|
||||
END
|
||||
EOM
|
||||
mv tmp.a libc++.a
|
||||
ranlib libc++.a
|
||||
popd
|
||||
|
||||
|
|
Loading…
Reference in New Issue