-
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.
* Latest code * Code builds again * Create ci.yml Added start of CI * Make sure to install libsdl2-dev * Build with -j32 and added -ldl * Use checkout@v4 as v3 seems deprecated * Print out availible gcc versions * Test building with multiple gcc versions * Missing stuff * gcc 12 seems missing? * Start with gcc 9 * Better naming * Try gcc 12 on a different linux image * Print clang versions * Add clang building * Clang fixes for CI * Another Clang fix * More clang versions
- Loading branch information
Showing
167 changed files
with
37,336 additions
and
163 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,98 @@ | ||
name: C/C++ CI | ||
|
||
on: | ||
push: | ||
branches: [ "master", "dev" ] | ||
pull_request: | ||
branches: [ "master", "dev" ] | ||
|
||
jobs: | ||
linux_ubuntu_20_04: | ||
name: (Ubuntu 20.04) GCC ${{ matrix.gcc-version }}.x | ||
runs-on: ubuntu-20.04 | ||
strategy: | ||
matrix: | ||
gcc-version: [9, 10, 11, 13] # 12 doesn't work for some reason | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Install GCC ${{ matrix.gcc-version }} | ||
run: | | ||
sudo add-apt-repository ppa:ubuntu-toolchain-r/test -y | ||
sudo apt update | ||
sudo apt install -y gcc-${{ matrix.gcc-version }} g++-${{ matrix.gcc-version }} | ||
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-${{ matrix.gcc-version }} 100 --slave /usr/bin/g++ g++ /usr/bin/g++-${{ matrix.gcc-version }} | ||
sudo update-alternatives --set gcc /usr/bin/gcc-${{ matrix.gcc-version }} | ||
- name: Install dependencies | ||
run: sudo apt-get update && sudo apt-get install -y libsdl2-dev | ||
|
||
- name: Build quaesar | ||
run: make -j$(nproc) | ||
|
||
linux_clang_ubuntu_20_04: | ||
runs-on: ubuntu-20.04 | ||
name: (Ubuntu 20.04) Clang ${{ matrix.clang-version }}.x | ||
strategy: | ||
matrix: | ||
clang-version: [8, 9, 10, 11] | ||
|
||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install Clang ${{ matrix.clang-version }} | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y clang-${{ matrix.clang-version }} | ||
sudo apt-get install -y clang++-${{ matrix.clang-version }} | ||
- name: Select Clang ${{ matrix.clang-version }} | ||
run: | | ||
sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-${{ matrix.clang-version }} 100 | ||
sudo update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-${{ matrix.clang-version }} 100 | ||
clang --version # Display the version of clang for debugging | ||
clang++ --version # Display the version of clang for debugging | ||
- name: Install dependencies | ||
run: sudo apt-get install -y libsdl2-dev | ||
|
||
- name: Build quaesar | ||
env: | ||
CC: clang-${{ matrix.clang-version }} | ||
CXX: clang++-${{ matrix.clang-version }} | ||
run: make -j$(nproc) | ||
|
||
linux_clang_ubuntu_22_04: | ||
runs-on: ubuntu-22.04 | ||
name: (Ubuntu 22.04) Clang ${{ matrix.clang-version }}.x | ||
strategy: | ||
matrix: | ||
clang-version: [12, 13, 14, 15] | ||
|
||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install Clang ${{ matrix.clang-version }} | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y clang-${{ matrix.clang-version }} | ||
sudo apt-get install -y clang++-${{ matrix.clang-version }} | ||
- name: Select Clang ${{ matrix.clang-version }} | ||
run: | | ||
sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-${{ matrix.clang-version }} 100 | ||
sudo update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-${{ matrix.clang-version }} 100 | ||
clang --version # Display the version of clang for debugging | ||
clang++ --version # Display the version of clang for debugging | ||
- name: Install dependencies | ||
run: sudo apt-get install -y libsdl2-dev | ||
|
||
- name: Build quaesar | ||
env: | ||
CC: clang-${{ matrix.clang-version }} | ||
CXX: clang++-${{ matrix.clang-version }} | ||
run: make -j$(nproc) | ||
|
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 |
---|---|---|
|
@@ -61,3 +61,10 @@ packages.config | |
**/.vs | ||
*.7z | ||
*.zip | ||
*.d | ||
build68k | ||
genblitter | ||
gencomp | ||
gencpu | ||
genlinetoscr | ||
quaesar |
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,77 @@ | ||
.PHONY: all clean | ||
|
||
all: quaesar | ||
|
||
# build68k | ||
|
||
build68k: FORCE | ||
$(MAKE) -f build/Makefile.build68k | ||
|
||
src/cpudefs.cpp: build68k src/table68k | ||
./build68k < src/table68k > $@ | ||
|
||
generated += src/cpudefs.cpp | ||
|
||
# gencomp | ||
|
||
gencomp: FORCE $(generated) | ||
$(MAKE) -f build/Makefile.gencomp | ||
|
||
src/jit/comptbl.h: gencomp | ||
./gencomp | ||
|
||
generated += src/jit/comptbl.h | ||
|
||
# gencpu | ||
|
||
gencpu: FORCE $(generated) | ||
$(MAKE) -f build/Makefile.gencpu | ||
|
||
src/cputbl.h: gencpu | ||
cd src && ../gencpu && cd .. | ||
|
||
generated += src/cputbl.h | ||
|
||
# genblitter | ||
|
||
genblitter: FORCE | ||
$(MAKE) -f Makefile.genblitter | ||
|
||
blit.h: genblitter | ||
./genblitter i > src/$@ | ||
blitfunc.cpp: genblitter | ||
./genblitter f > src/$@ | ||
blitfunc.h: genblitter | ||
./genblitter h > src/$@ | ||
blittable.cpp: genblitter | ||
./genblitter t > src/$@ | ||
|
||
generated += src/blit.h src/blitfunc.cpp src/blitfunc.h src/blittable.cpp | ||
|
||
# genlinetoscr | ||
|
||
genlinetoscr: FORCE | ||
$(MAKE) -f build/Makefile.genlinetoscr | ||
|
||
linetoscr.cpp: genlinetoscr | ||
./genlinetoscr > src/linetoscr.cpp | ||
|
||
generated += src/linetoscr.cpp | ||
|
||
# quasar | ||
|
||
quaesar: FORCE $(generated) | ||
$(MAKE) -f build/Makefile.quaesar | ||
|
||
# clean | ||
|
||
clean: | ||
make -f build/Makefile.build68k clean | ||
make -f build/Makefile.genblitter clean | ||
make -f build/Makefile.gencomp clean | ||
make -f build/Makefile.gencpu clean | ||
make -f build/Makefile.genlinetoscr clean | ||
make -f build/Makefile.quaesar clean | ||
rm -rf out | ||
|
||
FORCE: ; |
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
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,6 @@ | ||
# ./build68k < table68k > cpudefs.cpp | ||
|
||
target = build68k | ||
srcs = src/build68k.cpp | ||
|
||
include build/Makefile.inc |
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,9 @@ | ||
# ./genblitter i > blit.h | ||
# ./genblitter f > blitfunc.c | ||
# ./genblitter h > blitfunc.h | ||
# ./genblitter t > blittable.c | ||
|
||
target = genblitter | ||
srcs = src/blitops.cpp src/genblitter.cpp | ||
|
||
include build/Makefile.inc |
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,7 @@ | ||
# ./gencomp | ||
|
||
target = gencomp | ||
srcs = src/cpudefs.cpp jit/gencomp.cpp src/missing.cpp src/readcpu.cpp od-cross/unicode.cpp | ||
|
||
include build/Makefile.inc | ||
|
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,6 @@ | ||
# ./gencpu | ||
|
||
target = gencpu | ||
srcs = src/cpudefs.cpp src/gencpu.cpp src/missing.cpp src/readcpu.cpp od-cross/unicode.cpp | ||
|
||
include build/Makefile.inc |
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,6 @@ | ||
# ./genlinetoscr > linetoscr.cpp | ||
|
||
target = genlinetoscr | ||
srcs = src/genlinetoscr.cpp | ||
|
||
include build/Makefile.inc |
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,28 @@ | ||
CPPFLAGS += -g -DFSUAE -I . -I include -I od-cross -MMD | ||
|
||
OUT=out/$(target) | ||
|
||
objs = $(srcs:%.cpp=$(OUT)/%.o) | ||
deps = $(objs:.o=.d) | ||
|
||
# bash Create Dir rule | ||
MD = mkdir -p $(1) > /dev/null | ||
|
||
# Create output dirs | ||
dirs:=$(sort $(OUT) $(patsubst %/,%,$(dir $(objs)))) | ||
$(foreach dir,$(dirs),$(shell $(call MD,$(dir)))) | ||
|
||
.PHONY: all clean | ||
|
||
all: $(target) | ||
|
||
clean: | ||
rm -f $(objs) $(deps) $(target) -r $(OUT) | ||
|
||
$(objs): $(OUT)/%.o : %.cpp | ||
$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(TARGET_ARCH) -c -o $@ $< | ||
|
||
$(target) : $(objs) | ||
$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(LDFLAGS) $(TARGET_ARCH) $^ $(LOADLIBES) $(LDLIBS) -o $@ | ||
|
||
-include $(objs:.o=.d) |
Oops, something went wrong.