| 1 |
--- |
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
version: 0.2 |
| 15 |
|
| 16 |
env: |
| 17 |
variables: |
| 18 |
MUSL_DIR: "test-deps/musl" |
| 19 |
LIBCRYPTO_DIR: "test-deps/musl-awslc" |
| 20 |
|
| 21 |
phases: |
| 22 |
pre_build: |
| 23 |
on-failure: ABORT |
| 24 |
commands: |
| 25 |
|
| 26 |
- git clone --depth=1 https://git.musl-libc.org/git/musl $MUSL_DIR |
| 27 |
- echo "Installing musl to $CODEBUILD_SRC_DIR/$MUSL_DIR" |
| 28 |
- cd $MUSL_DIR |
| 29 |
- ./configure --prefix=$CODEBUILD_SRC_DIR/$MUSL_DIR |
| 30 |
- make install |
| 31 |
- cd $CODEBUILD_SRC_DIR |
| 32 |
|
| 33 |
|
| 34 |
|
| 35 |
- CFLAGS="-U_FORTIFY_SOURCE -D_FILE_OFFSET_BITS=32" |
| 36 |
- ./codebuild/bin/install_awslc.sh $(mktemp -d) $CODEBUILD_SRC_DIR/$LIBCRYPTO_DIR |
| 37 |
build: |
| 38 |
on-failure: ABORT |
| 39 |
commands: |
| 40 |
- CC="$CODEBUILD_SRC_DIR/$MUSL_DIR/bin/musl-gcc" |
| 41 |
- cmake . -Bbuild -DCMAKE_PREFIX_PATH=$CODEBUILD_SRC_DIR/$LIBCRYPTO_DIR |
| 42 |
- cmake --build ./build |
| 43 |
post_build: |
| 44 |
on-failure: ABORT |
| 45 |
commands: |
| 46 |
- CTEST_OUTPUT_ON_FAILURE=1 CTEST_PARALLEL_LEVEL=$(nproc) make -C build test |