Debian Codegraph @

crt/s2n/codebuild/bin/install_python.sh

raw symbols SCIP
1 #!/bin/bash
2 # Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3 #
4 # Licensed under the Apache License, Version 2.0 (the "License").
5 # You may not use this file except in compliance with the License.
6 # A copy of the License is located at
7 #
8 # http://aws.amazon.com/apache2.0
9 #
10 # or in the "license" file accompanying this file. This file is distributed
11 # on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
12 # express or implied. See the License for the specific language governing
13 # permissions and limitations under the License.
14 #
15 #!/bin/bash
16
17 set -e
18
19 if [ "$#" -ne 3 ]; then
20 echo "install_python.sh libcrypto_root build_dir install_dir"
21 exit 1
22 fi
23
24 LIBCRYPTO_ROOT=$1
25 BUILD_DIR=$2
26 INSTALL_DIR=$3
27 source codebuild/bin/jobs.sh
28
29 cd "$BUILD_DIR"
30 # Originally from: https://www.python.org/ftp/python/3.6.0/Python-3.6.0.tgz
31 curl --retry 3 https://s3-us-west-2.amazonaws.com/s2n-public-test-dependencies/2017-08-29_Python-3.6.0.tgz --output Python-3.6.0.tgz
32 tar xzf Python-3.6.0.tgz
33 cd Python-3.6.0
34 CPPFLAGS="-I$LIBCRYPTO_ROOT/include" LDFLAGS="-Wl,-rpath,$LIBCRYPTO_ROOT/lib -L$LIBCRYPTO_ROOT/lib" ./configure --prefix="$INSTALL_DIR"
35 make -j $JOBS
36 make -j $JOBS install