forked from CartoDB/mobile-sdk
-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
89ea214
commit fffbab5
Showing
2 changed files
with
74 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
name: Build CartoMobileSDK css2xml tool | ||
|
||
on: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
build: | ||
strategy: | ||
matrix: | ||
variant: ['android', 'ios'] | ||
runs-on: ${{ matrix.variant == 'android' && 'ubuntu-latest' || 'macos-latest' }} | ||
name: css2xml ${{ matrix.variant }} | ||
steps: | ||
|
||
- name: Runner platform name | ||
run: | | ||
export PLATFORM_UP=${{ runner.os }} | ||
echo "PLATFORM_UP=$PLATFORM_UP" | ||
echo "PLATFORM=$(echo "$PLATFORM_UP" | tr "[:upper:]" "[:lower:]")" >>${GITHUB_ENV} | ||
echo "PLATFORM=${{ env.PLATFORM }}" | ||
- name: ensure dist | ||
run: | | ||
mkdir dist | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 1 | ||
|
||
- uses: maxim-lobanov/setup-xcode@v1 | ||
if: matrix.variant != 'android' | ||
|
||
|
||
- name: Setup cmake | ||
uses: jwlawson/actions-setup-cmake@v2 | ||
|
||
- name: fetch externals | ||
run: | | ||
git submodule update --init --remote --recursive | ||
- name: Install build tools | ||
if: matrix.variant == 'android' | ||
run: | | ||
sudo apt-get install autoconf automake libtool build-essential | ||
- name: Install build tools | ||
if: matrix.variant != 'android' | ||
run: | | ||
brew install autoconf automake libtool | ||
- name: prepare boost | ||
run: | | ||
wget https://boostorg.jfrog.io/artifactory/main/release/1.85.0/source/boost_1_85_0.zip | ||
unzip boost_1_85_0.zip | ||
ln -s ../boost_1_85_0 libs-external/boost | ||
cd boost_1_85_0 | ||
./bootstrap.sh | ||
./b2 headers | ||
- name: Build CSS2XML | ||
run: | | ||
cd libs-carto/cartocss/util | ||
cmake -B build -DCMAKE_BUILD_TYPE=Release -DCMAKE_OSX_ARCHITECTURES="arm64;x86_64" | ||
cd build | ||
make css2xml | ||
mv css2xml css2xml_${{ env.PLATFORM }} | ||
zip ../../../../dist/css2xml_${{ env.PLATFORM }}.zip css2xml_${{ env.PLATFORM }} | ||
- name: Upload Artifacts | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
path: dist/css2xml_*.zip |