Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 44 additions & 0 deletions .github/workflows/cosmo.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: Build cxx with Cosmopolitan Libc

on:
workflow_dispatch:
release:
types: [created]
push:
tags:
- "*.*.*"

permissions:
contents: read

jobs:

release-cosmo:
permissions:
contents: write # for softprops/action-gh-release to create GitHub release
name: Build release binaries for Cosmo
runs-on: ubuntu-latest
steps:
- name: Checkout the repository
uses: actions/checkout@master
- name: setup cosmocc
run: |
sudo mkdir -p /sc
sudo chmod -R 0777 /sc
cd /sc
wget https://github.com/jart/cosmopolitan/releases/download/3.3.3/cosmocc-3.3.3.zip
mkdir cosmo
cd cosmo
unzip ../cosmocc-3.3.3.zip
sudo cp ./bin/ape-x86_64.elf /usr/bin/ape
sudo sh -c "echo ':APE:M::MZqFpD::/usr/bin/ape:' >/proc/sys/fs/binfmt_misc/register"
- name: build APE binary of cxx
run: |
make -j CC="/sc/cosmo/bin/cosmocc"
chmod +x src/cxx
- name: push binary to github
uses: softprops/action-gh-release@v1
with:
draft: true
files: |
src/cxx