File tree Expand file tree Collapse file tree 4 files changed +14
-13
lines changed
Expand file tree Collapse file tree 4 files changed +14
-13
lines changed Original file line number Diff line number Diff line change 3737
3838def _get_handler (handler ):
3939 try :
40- modname , fname = handler .rsplit ("." , 1 )
40+ ( modname , fname ) = handler .rsplit ("." , 1 )
4141 except ValueError as e :
4242 raise FaultException (
4343 FaultException .MALFORMED_HANDLER_NAME ,
Original file line number Diff line number Diff line change 1414 exit 1
1515fi
1616
17+ skip () {
18+ [ " $( uname) " = " Darwin" ]
19+ }
20+
1721cd deps
1822. ./versions
1923
2024CURL_VERSION=" ${CURL_MAJOR_VERSION} .${CURL_MINOR_VERSION} .${CURL_PATCH_VERSION} "
2125
22- rm -rf ./curl-$CURL_VERSION
26+ skip || rm -rf ./curl-$CURL_VERSION
2327rm -rf ./aws-lambda-cpp-$AWS_LAMBDA_CPP_RELEASE
2428
2529# unpack dependencies
26- tar xzf ./curl-$CURL_VERSION .tar.gz --no-same-owner && \
30+ skip || tar xzf ./curl-$CURL_VERSION .tar.gz --no-same-owner && \
2731tar xzf ./aws-lambda-cpp-$AWS_LAMBDA_CPP_RELEASE .tar.gz --no-same-owner
2832
29- (
33+ skip || (
3034 # Build Curl
31- export CFLAGS=" $CFLAGS -Wno-deprecated-declarations"
3235 cd curl-$CURL_VERSION && \
3336 ./buildconf && \
3437 ./configure \
3538 --prefix " $ARTIFACTS_DIR " \
3639 --disable-shared \
37- --disable-ldap \
38- --disable-ldaps \
3940 --without-ssl \
4041 --with-pic \
41- --without-zlib \
42- --without-nghttp2 \
43- --without-nghttp3 \
44- --without-ngtcp2 &&
42+ --without-zlib && \
4543 make && \
4644 make install
4745)
@@ -52,7 +50,7 @@ tar xzf ./aws-lambda-cpp-$AWS_LAMBDA_CPP_RELEASE.tar.gz --no-same-owner
5250 cd ./aws-lambda-cpp-$AWS_LAMBDA_CPP_RELEASE /build
5351
5452 $CMAKE .. \
55- -DCMAKE_CXX_FLAGS=" -fPIC -Wno-deprecated-declarations " \
53+ -DCMAKE_CXX_FLAGS=" -fPIC" \
5654 -DCMAKE_INSTALL_PREFIX=" $ARTIFACTS_DIR " \
5755 -DENABLE_LTO=$ENABLE_LTO \
5856 -DCMAKE_MODULE_PATH=" $ARTIFACTS_DIR " /lib/pkgconfig && \
Original file line number Diff line number Diff line change @@ -19,7 +19,10 @@ def get_curl_extra_linker_flags():
1919 check_call (["./scripts/preinstall.sh" ])
2020
2121 # call curl-config to get the required linker flags
22- cmd = ["./deps/artifacts/bin/curl-config" , "--static-libs" ]
22+ if platform .system () in {"Darwin" }:
23+ cmd = ["curl-config" , "--libs" ]
24+ else :
25+ cmd = ["./deps/artifacts/bin/curl-config" , "--static-libs" ]
2326 curl_config = check_output (cmd ).decode ("utf-8" ).replace ("\n " , "" )
2427
2528 # It is expected that the result of the curl-config call is similar to
You can’t perform that action at this time.
0 commit comments