Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
04d851f
Build fixes/tweaks for (optional) shared libs, reduced footprint
Jul 17, 2021
0021523
Add pure cmake build system
madebr Nov 13, 2018
841d379
Export Abc_RealMain if building shared libabc
madebr Nov 13, 2018
23fc40a
new: dev: update original cmake cfg and sources, add tox/update ci files
Nov 1, 2021
06e1412
fix: make clang build work, mainly C++ type/literal errors
Nov 7, 2021
098d955
chg: dev: cleanup windows builds and sources, update workflows
Nov 7, 2021
258a83f
Silence warning about unused variables
madebr Nov 13, 2018
c2395d9
new: dev: demonstrate tox/ci workflow options, cleanup build cfg
Nov 10, 2021
cb5b5cc
fix: dev: run manual cmake commands from build dir on macos
sarnold Jul 23, 2023
2f574da
post-rebase generate/update CMakeLists.txt files, update tox file
Jul 23, 2023
2366c2e
fix timespec redefinition errors on windows
sarnold Jul 23, 2023
7b6ec99
chg: dev: add (new) generated cmake sources
sarnold Dec 1, 2023
a9d0a05
chg: dev: update python versions, add CPUS env var to tox file
sarnold Dec 1, 2023
26d49b1
fix: dev: address toolchain requirement changes
sarnold Dec 1, 2023
cba49c7
fix: dev: cleanup desktop and ci workflows
sarnold Dec 3, 2023
4bef4bf
chg: usr: update devenv file and conda-dev workflow, update win path
sarnold Dec 3, 2023
f28e4b0
chg: revert to latest action and package versions
sarnold Dec 9, 2023
783ff1e
fix: dev: relax ifdef check in cmd.c and make it windows-specific
sarnold Dec 10, 2023
4b16991
chg: dev: cleanup coverage, .gitignore, and tox cmds
sarnold Feb 3, 2025
63283fc
chg: dev: (re)generate, update all cmake build files
sarnold Feb 3, 2025
d168df0
chg: dev: update workflow actions, add dependabot.yml, bump OS versions
sarnold Feb 15, 2025
c8a0829
chg: dev: cleanup cmake and tox files, include gia tests
sarnold Feb 17, 2025
469ea53
chg: dev: install or vendor googletest as needed, set gtest libs
sarnold Feb 17, 2025
9eb943e
fix: dev: adjust for workflow environments, fix gia_test working dire…
sarnold Feb 19, 2025
1e09d3a
chg: dev: cleanup readme and xcode setup, use internal gtest for xcode
sarnold Feb 21, 2025
d188e20
fix: dev: cleanup googletest bits for consistent paths to gtest libs
sarnold Feb 23, 2025
817908b
fix: dev: try fetching googletest on windows instead of conda pkgs
sarnold Feb 23, 2025
9ea754f
fix: dev: refactor symbol visibility, use ABC_DLL to expose public API
sarnold Feb 24, 2025
79854ff
chg: dev: use static libs and local gtest in windows conda env
sarnold Feb 24, 2025
712f976
chg: dev: use C++ namespace for msys2 builds, workflow and tox cleanup
sarnold Feb 25, 2025
ac7338c
fix: dev: cleanup llvm coverage in smoke workflow, sort out version path
sarnold Mar 7, 2025
e94b0a7
fix: dev: prep msvc cl and github environment for conda on windows
sarnold Mar 8, 2025
5daf566
fix: dev: add latest modules to cmake build modules
sarnold Mar 9, 2025
0d2f02f
chg: dev: post-rebase (re)generate cmake files
sarnold Mar 25, 2025
7501f0c
fix: dev: rename conflicting Win32 symbol, cleanup whitespace
sarnold Mar 25, 2025
dbb84c5
chg: dev: post-rebase (re)generate cmake files
sarnold Mar 20, 2026
23afa03
chg: dev: update workflow actions, save updated win project files
sarnold Mar 22, 2026
0adeff0
chg: dev: adjust win32 ci config to use external pthreads
sarnold Mar 23, 2026
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
28 changes: 20 additions & 8 deletions .github/workflows/build-posix-cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ name: Build Posix CMake

on:
push:
branches:
- master
pull_request:

jobs:
Expand All @@ -13,6 +15,9 @@ jobs:
use_namespace: [false, true]

runs-on: ${{ matrix.os }}
defaults:
run:
shell: bash

env:
CMAKE_ARGS: ${{ matrix.use_namespace && '-DABC_USE_NAMESPACE=xxx' || '' }}
Expand All @@ -22,9 +27,12 @@ jobs:
steps:

- name: Git Checkout
uses: actions/checkout@v4
uses: actions/checkout@v6
with:
submodules: recursive
fetch-depth: 0

- name: Update CMake
uses: jwlawson/actions-setup-cmake@v2

- name: Install brew dependencies
run: |
Expand All @@ -37,8 +45,13 @@ jobs:
if: ${{ !contains(matrix.os, 'macos') }}

- name: Configure CMake
run: |
cmake -G Ninja -DCMAKE_BUILD_TYPE=Release ${CMAKE_ARGS} -B build
run: >
cmake -S . -B build
-G Ninja
${CMAKE_ARGS}
-DCMAKE_BUILD_TYPE=Release
-DCMAKE_INSTALL_PREFIX=./staging
-DVENDOR_GTEST=ON

- name: Build CMake
run: |
Expand All @@ -50,7 +63,7 @@ jobs:

- name: Test Executable
run: |
./build/abc -c "r i10.aig; b; ps; b; rw -l; rw -lz; b; rw -lz; b; ps; cec"
./build/src/base/main/abc -c "r i10.aig; b; ps; b; rw -l; rw -lz; b; rw -lz; b; ps; cec"

- name: Test Library
run: |
Expand All @@ -60,11 +73,10 @@ jobs:

- name: Stage Executable
run: |
mkdir staging
cp build/abc build/libabc.a staging/
cmake --build build --target install

- name: Upload pacakge artifact
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@v6
with:
name: package-cmake-${{ matrix.os }}-${{ matrix.use_namespace }}
path: staging/
11 changes: 7 additions & 4 deletions .github/workflows/build-posix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ name: Build Posix

on:
push:
branches:
- master
pull_request:

jobs:
Expand All @@ -22,7 +24,7 @@ jobs:
steps:

- name: Git Checkout
uses: actions/checkout@v4
uses: actions/checkout@v6
with:
submodules: recursive

Expand All @@ -33,12 +35,13 @@ jobs:

- name: Install APT dependencies
run: |
sudo apt install -y libreadline-dev
sudo apt-get -y -qq update
sudo apt-get install -y libreadline-dev
if: ${{ !contains(matrix.os, 'macos') }}

- name: Build Executable
run: |
make -j3 ${MAKE_ARGS} abc
make -j3 ABC_USE_PIC=1 ${MAKE_ARGS} abc

- name: Test Executable
run: |
Expand All @@ -60,7 +63,7 @@ jobs:
cp abc libabc.a staging/

- name: Upload pacakge artifact
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@v6
with:
name: package-posix-${{ matrix.os }}-${{ matrix.use_namespace }}
path: staging/
18 changes: 11 additions & 7 deletions .github/workflows/build-windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ name: Build Windows

on:
push:
branches:
- master
pull_request:

jobs:
Expand All @@ -13,7 +15,7 @@ jobs:
steps:

- name: Git Checkout
uses: actions/checkout@v4
uses: actions/checkout@v6
with:
submodules: recursive

Expand All @@ -33,9 +35,9 @@ jobs:
# Parse source files from abclib.dsp
$dspContent = Get-Content "abclib.dsp" -Raw
$sourceFiles = [regex]::Matches($dspContent, 'SOURCE=\.\\([^\r\n]+)') | ForEach-Object { $_.Groups[1].Value } | Sort-Object -Unique

Write-Host "Found $($sourceFiles.Count) source files"

# Build source file items
$sourceItems = ""
foreach ($src in $sourceFiles) {
Expand All @@ -47,12 +49,12 @@ jobs:
$sourceItems += " <ClInclude Include=`"$src`" />`r`n"
}
}

# Read template and replace placeholder
$template = Get-Content ".github\scripts\abclib.vcxproj.template" -Raw
$vcxproj = $template -replace '\{\{SOURCE_FILES\}\}', $sourceItems
Set-Content "abclib.vcxproj" $vcxproj -NoNewline

Write-Host "abclib.vcxproj generated successfully"

- name: Build
Expand All @@ -69,10 +71,12 @@ jobs:
- name: Stage Executable
run: |
mkdir staging
copy abcspace.sln staging\
copy abclib.vcxproj staging\
copy _TEST\abc.exe staging\

- name: Upload package artifact
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@v6
with:
name: package-windows
path: staging/
path: staging/
176 changes: 176 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,176 @@
name: ci

on:
workflow_dispatch:
pull_request:
push:
branches:
- master
- develop
paths-ignore:
- '**.md'
- '**.rst'
- '**.sh'

jobs:
ci_build:

name: ${{ matrix.name }}
runs-on: ${{ matrix.os }}
defaults:
run:
shell: bash

strategy:
fail-fast: false
matrix:
python-version: ['3.10']

name: [
windows-2025-cl,
ubuntu-22.04-gcc-12,
ubuntu-24.04-gcc-14,
ubuntu-22.04-clang-15,
macOS-15-gcc,
macOS-15-clang,
]

include:
- name: windows-2025-cl
os: windows-2025
compiler: cl

- name: ubuntu-22.04-gcc-12
os: ubuntu-22.04
compiler: gcc
version: "12"
toxcmd: soname,tests

- name: ubuntu-24.04-gcc-14
os: ubuntu-24.04
compiler: gcc
version: "14"
toxcmd: libs

- name: ubuntu-22.04-clang-15
os: ubuntu-22.04
compiler: clang
version: "15"
toxcmd: clang

- name: macOS-15-gcc
os: macOS-15
compiler: gcc
version: "13"
toxcmd: abc,tests

- name: macOS-15-clang
os: macOS-15
compiler: xcode
version: "16.4"
toxcmd: "ctestwin -- Xcode"

steps:
- uses: actions/checkout@v6
with:
fetch-depth: 0

- uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}

- name: Update CMake
uses: jwlawson/actions-setup-cmake@v2
if: runner.os == 'Windows'

- name: Install Tox
run: |
python -m pip install --upgrade pip
pip install tox

- name: Install and setup Linux packages
if: runner.os == 'Linux'
run: |
sudo apt-get -y -qq update
sudo apt-get install -yqq software-properties-common
sudo add-apt-repository ppa:ubuntu-toolchain-r/ppa
sudo apt-get -qq update
sudo apt-get install -y libreadline-dev ncurses-dev libgtest-dev
if [ "${{ matrix.compiler }}" = gcc ]; then
sudo apt-get install -y g++-${{ matrix.version }} g++-${{ matrix.version }}-multilib
echo "CC=gcc-${{ matrix.version }}" >> $GITHUB_ENV
echo "CXX=g++-${{ matrix.version }}" >> $GITHUB_ENV
else
sudo apt-get install -y clang-${{ matrix.version }} clang++-${{ matrix.version }} llvm-${{ matrix.version }}-tools lld-${{ matrix.version }}
echo "CC=clang-${{ matrix.version }}" >> $GITHUB_ENV
echo "CXX=clang++-${{ matrix.version }}" >> $GITHUB_ENV
echo "LLVM_VER_DIR=/usr/lib/llvm-${{ matrix.version }}" >> $GITHUB_ENV
fi

- name: Build and test Linux
if: runner.os == 'Linux'
env:
CC: ${{ env.CC }}
CXX: ${{ env.CXX }}
LLVM_VER_DIR: ${{ env.LLVM_VER_DIR }}
PREFIX: ../staging
run: |
tox -e ${{ matrix.toxcmd }}

- uses: actions/upload-artifact@v6
if: matrix.name == 'ubuntu-22.04-clang-15'
with:
name: src_coverage_data
path: |
build/coverage/html
build/coverage/lcov.info

- name: Install and setup MacOS packages
if: runner.os == 'macOS'
run: |
brew update
#brew upgrade
if [ "${{ matrix.compiler }}" = xcode ]; then
sudo xcode-select -s /Applications/Xcode_${{ matrix.version }}.app/Contents/Developer
ls -ls /Applications/
else
brew install gcc@${{ matrix.version }}
echo "CC=gcc-${{ matrix.version }}" >> $GITHUB_ENV
echo "CXX=g++-${{ matrix.version }}" >> $GITHUB_ENV
fi

- name: Build and test MacOS
if: runner.os == 'macOS'
run: |
if [ "${{ matrix.compiler }}" = gcc ]; then
CC=${{ env.CC }} CXX=${{ env.CXX }} tox -e ${{ matrix.toxcmd }}
else
tox -e ${{ matrix.toxcmd }}
fi

- name: Configure Windows
if: runner.os == 'Windows'
run: >
cmake -S . -B build
-DBUILD_SHARED_LIBS=OFF
-DABC_USE_NO_PTHREADS=OFF
-DABC_USE_EXTERNAL_PTHREAD=OFF
-DABC_USE_VENDORED_PTHREAD=OFF
-DABC_USE_NO_READLINE=ON
-DCMAKE_BUILD_TYPE=Release
-DCMAKE_INSTALL_PREFIX=${{ env.PREFIX }}
-DVENDOR_GTEST=ON
env:
CC: cl
CXX: cl
PREFIX: staging

- name: Build Windows
if: runner.os == 'Windows'
run: cmake --build build --config Release -j 2 --target install

- name: Test Windows
if: runner.os == 'Windows'
run: |
ctest -V -C Release --test-dir build/
ls -lh staging/ || true
Loading
Loading