Skip to content

Commit

Permalink
Update C and CRT dependencies (#102)
Browse files Browse the repository at this point in the history
* Update C and CRT dependencies
  • Loading branch information
bretambrose authored Mar 26, 2020
1 parent 327605b commit f0ab8fc
Show file tree
Hide file tree
Showing 4 changed files with 136 additions and 1 deletion.
92 changes: 92 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
name: CI

on:
push:
branches:
- '*'
- '!master'

env:
BUILDER_VERSION: v0.6.0
BUILDER_SOURCE: releases
BUILDER_HOST: https://d19elf31gohf1l.cloudfront.net
PACKAGE_NAME: aws-iot-device-sdk-cpp-v2
LINUX_BASE_IMAGE: ubuntu-16-x64
RUN: ${{ github.run_id }}-${{ github.run_number }}

jobs:
linux-compat:
runs-on: ubuntu-latest
strategy:
matrix:
image:
- manylinux1-x64
- manylinux1-x86
- manylinux2014-x64
- manylinux2014-x86
steps:
# We can't use the `uses: docker://image` version yet, GitHub lacks authentication for actions -> packages
- name: Build ${{ env.PACKAGE_NAME }}
run: |
echo "${{ secrets.GITHUB_TOKEN }}" | docker login docker.pkg.github.com -u awslabs --password-stdin
export DOCKER_IMAGE=docker.pkg.github.com/awslabs/aws-crt-builder/aws-crt-${{ matrix.image }}:${{ env.BUILDER_VERSION }}
docker pull $DOCKER_IMAGE
docker run --env GITHUB_REF $DOCKER_IMAGE build -p ${{ env.PACKAGE_NAME }}
al2:
runs-on: ubuntu-latest
steps:
# We can't use the `uses: docker://image` version yet, GitHub lacks authentication for actions -> packages
- name: Build ${{ env.PACKAGE_NAME }} + consumers
run: |
echo "${{ secrets.GITHUB_TOKEN }}" | docker login docker.pkg.github.com -u awslabs --password-stdin
export DOCKER_IMAGE=docker.pkg.github.com/awslabs/aws-crt-builder/aws-crt-al2-x64:${{ env.BUILDER_VERSION }}
docker pull $DOCKER_IMAGE
docker run --env GITHUB_REF $DOCKER_IMAGE build -p ${{ env.PACKAGE_NAME }} al2-default-default-default-default-downstream
clang-compat:
runs-on: ubuntu-latest
strategy:
matrix:
version: [3, 6, 8, 9]
steps:
# We can't use the `uses: docker://image` version yet, GitHub lacks authentication for actions -> packages
- name: Build ${{ env.PACKAGE_NAME }}
run: |
echo "${{ secrets.GITHUB_TOKEN }}" | docker login docker.pkg.github.com -u awslabs --password-stdin
export DOCKER_IMAGE=docker.pkg.github.com/awslabs/aws-crt-builder/aws-crt-${{ env.LINUX_BASE_IMAGE }}:${{ env.BUILDER_VERSION }}
docker pull $DOCKER_IMAGE
docker run --env GITHUB_REF $DOCKER_IMAGE build -p ${{ env.PACKAGE_NAME }} linux-clang-${{ matrix.version }}-linux-x64 --config Debug
gcc-compat:
runs-on: ubuntu-latest
strategy:
matrix:
version: [4.8, 5, 6, 7, 8]
steps:
# We can't use the `uses: docker://image` version yet, GitHub lacks authentication for actions -> packages
- name: Build ${{ env.PACKAGE_NAME }}
run: |
echo "${{ secrets.GITHUB_TOKEN }}" | docker login docker.pkg.github.com -u awslabs --password-stdin
export DOCKER_IMAGE=docker.pkg.github.com/awslabs/aws-crt-builder/aws-crt-${{ env.LINUX_BASE_IMAGE }}:${{ env.BUILDER_VERSION }}
docker pull $DOCKER_IMAGE
docker run --env GITHUB_REF $DOCKER_IMAGE build -p ${{ env.PACKAGE_NAME }} linux-gcc-${{ matrix.version }}-linux-x64
windows:
runs-on: windows-latest
steps:
- name: Build ${{ env.PACKAGE_NAME }} + consumers
run: |
python -c "from urllib.request import urlretrieve; urlretrieve('${{ env.BUILDER_HOST }}/${{ env.BUILDER_SOURCE }}/${{ env.BUILDER_VERSION }}/builder.pyz', 'builder.pyz')"
python builder.pyz build -p ${{ env.PACKAGE_NAME }} default-downstream
osx:
runs-on: macos-latest
steps:
- name: Build ${{ env.PACKAGE_NAME }} + consumers
run: |
python3 -c "from urllib.request import urlretrieve; urlretrieve('${{ env.BUILDER_HOST }}/${{ env.BUILDER_SOURCE }}/${{ env.BUILDER_VERSION }}/builder.pyz', 'builder')"
chmod a+x builder
./builder build -p ${{ env.PACKAGE_NAME }} default-downstream
18 changes: 18 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Lint

on: [push]

jobs:
clang-format:

runs-on: ubuntu-latest

steps:
- name: Checkout Sources
uses: actions/checkout@v1

- name: clang-format lint
uses: DoozyX/clang-format-lint-action@v0.3.1
with:
# List of extensions to check
extensions: c,h
2 changes: 1 addition & 1 deletion aws-common-runtime/aws-crt-cpp
25 changes: 25 additions & 0 deletions builder.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
"name": "aws-iot-device-sdk-cpp-v2",
"!cmake_args": [
"-DBUILD_DEPS=ON",
"-DPERFORM_HEADER_CHECK=OFF",
"-DS2N_NO_PQ_ASM=ON"
],
"targets": {
"linux" : {
"imports": [
"s2n"
]
}
},
"search_dirs": ["aws-common-runtime"],
"hosts": {
"manylinux": {
"architectures": {
"x86": {
"!yum_compiler_packages": []
}
}
}
}
}

0 comments on commit f0ab8fc

Please sign in to comment.