Commit 2a22994d authored by Drake Arconis's avatar Drake Arconis
Browse files

Fix macos build for sdk 10.14, deploy 10.13 and our build requirements

parent 1bcdf8cc
......@@ -63,6 +63,7 @@ Copyright (c) 2012, 2014, 2015, 2016 nghttp2 contributors</string>
</map>
<key>manifest</key>
<array>
<string>lib/debug/libnghttp2*.dylib</string>
<string>lib/release/libnghttp2*.dylib</string>
</array>
<key>name</key>
......@@ -82,6 +83,7 @@ Copyright (c) 2012, 2014, 2015, 2016 nghttp2 contributors</string>
</map>
<key>manifest</key>
<array>
<string>lib/debug/libnghttp2.*</string>
<string>lib/release/libnghttp2.*</string>
</array>
<key>name</key>
......
......@@ -86,24 +86,36 @@ pushd "$top/nghttp2"
;;
darwin*)
opts="${TARGET_OPTS:--arch $AUTOBUILD_CONFIGURE_ARCH $LL_BUILD_RELEASE}"
opts="${TARGET_OPTS:--arch $AUTOBUILD_CONFIGURE_ARCH -gdwarf-2}"
## # Release configure and build
## ./configure --enable-lib-only CFLAGS="$opts" CXXFLAGS="$opts"
## make
## make check
cmake . -DCMAKE_C_FLAGS:STRING="$opts" \
-DCMAKE_CXX_FLAGS:STRING="$opts" \
-DCMAKE_INSTALL_PREFIX="$stage"
cmake --build . --config Release
mv "$top/nghttp2/lib"/libnghttp2*.dylib "$stage/lib/release/"
mkdir -p "build"
pushd "build"
cmake -G "Xcode" .. -DCMAKE_C_FLAGS:STRING="$opts" \
-DCMAKE_CXX_FLAGS:STRING="$opts" \
-DCMAKE_INSTALL_PREFIX="$stage" \
-DCMAKE_OSX_SYSROOT="macosx10.14" \
-DCMAKE_OSX_DEPLOYMENT_TARGET="10.13" \
-DENABLE_LIB_ONLY=ON
cmake --build . --config Debug
cmake --build . --config Release
mv lib/Debug/libnghttp2*.dylib "$stage/lib/debug/"
mv lib/Release/libnghttp2*.dylib "$stage/lib/release/"
cp -a lib/includes/nghttp2/nghttp2ver.h "$stage/include/nghttp2"
popd
rm -rf "build"
# SL-807: fix_dylib_id doesn't really handle symlinks, even though
# it's coded to try to do so. Chase the multiple levels of
# indirection to find the real dylib.
pushd "$stage/lib/debug"
dylib="libnghttp2.dylib"
while [ -L "$dylib" ]
do dylib="$(readlink "$dylib")"
done
fix_dylib_id "$dylib"
popd
pushd "$stage/lib/release"
dylib="libnghttp2.dylib"
while [ -L "$dylib" ]
......@@ -111,8 +123,6 @@ pushd "$top/nghttp2"
done
fix_dylib_id "$dylib"
popd
# make distclean
;;
linux*)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment