build-libcxx: Stop manually linking to -lpsapi
Since the default _WIN32_WINNT now is for Windows 7, psapi.h redirects to PSAPI version 2, which is available in kernel32.dll with a "K32" prefix on the function names (K32EnumProcessModules).
This commit is contained in:
1 parent
3d13aefc70
commit
4a4cc16393
1 file changed
-7
@@ -90,19 +90,12 @@ build_all() {
|
|||||||
-DLIBUNWIND_ENABLE_CROSS_UNWINDING=FALSE \
|
-DLIBUNWIND_ENABLE_CROSS_UNWINDING=FALSE \
|
||||||
-DCMAKE_CXX_FLAGS="-Wno-dll-attribute-on-redeclaration" \
|
-DCMAKE_CXX_FLAGS="-Wno-dll-attribute-on-redeclaration" \
|
||||||
-DCMAKE_C_FLAGS="-Wno-dll-attribute-on-redeclaration" \
|
-DCMAKE_C_FLAGS="-Wno-dll-attribute-on-redeclaration" \
|
||||||
-DCMAKE_SHARED_LINKER_FLAGS="-lpsapi" \
|
|
||||||
..
|
..
|
||||||
make -j$CORES
|
make -j$CORES
|
||||||
make install
|
make install
|
||||||
if [ "$type" = "shared" ]; then
|
if [ "$type" = "shared" ]; then
|
||||||
mkdir -p $PREFIX/$arch-w64-mingw32/bin
|
mkdir -p $PREFIX/$arch-w64-mingw32/bin
|
||||||
cp lib/libunwind.dll $PREFIX/$arch-w64-mingw32/bin
|
cp lib/libunwind.dll $PREFIX/$arch-w64-mingw32/bin
|
||||||
else
|
|
||||||
# Merge libpsapi.a into the static library libunwind.a, to
|
|
||||||
# avoid having to specify -lpsapi when linking to it.
|
|
||||||
llvm-ar qcsL \
|
|
||||||
$PREFIX/$arch-w64-mingw32/lib/libunwind.a \
|
|
||||||
$PREFIX/$arch-w64-mingw32/lib/libpsapi.a
|
|
||||||
fi
|
fi
|
||||||
cd ..
|
cd ..
|
||||||
done
|
done
|
||||||
|
|||||||
Reference in new issue
Block a user