Skip to content

Commit 1d1951a

Browse files
merge branch 'llvm' into 'devel'
2 parents 3a7d077 + a25c5f3 commit 1d1951a

File tree

810 files changed

+23280
-30100
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

810 files changed

+23280
-30100
lines changed

.deploy.sh

Lines changed: 0 additions & 42 deletions
This file was deleted.

.github/FUNDING.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
patreon: ceprogramming
2+
ko_fi: ceprogramming
3+
liberapay: CE-Programming

.github/workflows/docs.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Docs
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
8+
jobs:
9+
build-and-deploy:
10+
runs-on: ubuntu-latest
11+
steps:
12+
13+
- name: Install Build Dependencies
14+
run: |
15+
cmake -E echo >> $${{env.ENV}}GITHUB_PATH $HOME/.local/bin
16+
sudo apt-get install -y doxygen
17+
pip install sphinx==3.2.1 sphinx_rtd_theme breathe
18+
19+
- name: Checkout Toolchain
20+
uses: actions/checkout@v2.3.1
21+
with:
22+
persist-credentials: false
23+
24+
- name: Build Website Documentation
25+
run: |
26+
cd docs
27+
make html
28+
cd build/html
29+
touch .nojekyll
30+
31+
- name: Upload Website Documentation
32+
uses: JamesIves/github-pages-deploy-action@3.7.1
33+
with:
34+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
35+
BRANCH: gh-pages
36+
FOLDER: docs/build/html
37+
CLEAN: true

.github/workflows/make.yml

Lines changed: 167 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,167 @@
1+
name: Win/Mac/Linux
2+
3+
on:
4+
push:
5+
branches:
6+
- llvm
7+
pull_request:
8+
branches:
9+
- llvm
10+
11+
jobs:
12+
build:
13+
strategy:
14+
fail-fast: false
15+
matrix:
16+
runs-on: [ubuntu-latest, macos-latest, windows-latest]
17+
runs-on: ${{matrix.runs-on}}
18+
steps:
19+
- name: Bootstrap Build Environment
20+
if: runner.os == 'Windows'
21+
run: "cmake -E echo >> $env:GITHUB_ENV ENV=env:"
22+
- name: Prepare Build Environment
23+
run: |
24+
cmake -E echo >> $${{env.ENV}}GITHUB_ENV ROM=84pce_515_53.rom
25+
cmake -E echo >> $${{env.ENV}}GITHUB_ENV CEDEV=${{github.workspace}}/CEdev
26+
cmake -E echo >> $${{env.ENV}}GITHUB_PATH ${{github.workspace}}/CEdev/bin
27+
cmake -E echo >> $${{env.ENV}}GITHUB_PATH ${{github.workspace}}/CEmu/tests/autotester
28+
- name: Prepare Build Environment
29+
if: runner.os == 'Windows'
30+
run: |
31+
cmake -E echo >> $${{env.ENV}}GITHUB_ENV EXE=.exe
32+
33+
- name: Install Build Dependencies
34+
if: runner.os == 'Linux'
35+
run: sudo apt-get install -y doxygen
36+
- name: Install Build Dependencies
37+
if: runner.os == 'macOS'
38+
run: brew install doxygen
39+
40+
- name: Download ez80-clang
41+
id: ez80-clang
42+
uses: carlosperate/download-file-action@v1.0.3
43+
with:
44+
file-url: https://jacobly.com/a/llvm/ez80-clang${{env.EXE}}-${{runner.os}}Release.zip
45+
- name: Extract ez80-clang
46+
uses: DuckSoft/extract-7z-action@v1.0
47+
with:
48+
pathSource: ${{steps.ez80-clang.outputs.file-path}}
49+
pathTarget: CEdev/bin
50+
- name: Make ez80-clang Executable
51+
if: runner.os != 'Windows'
52+
run: chmod +x CEdev/bin/ez80-clang${{env.EXE}}
53+
- name: Test ez80-clang
54+
run: ez80-clang --version
55+
56+
- name: Checkout Toolchain
57+
uses: actions/checkout@v2
58+
with:
59+
path: toolchain
60+
submodules: recursive
61+
62+
- name: Setup Fasmg
63+
if: runner.os == 'Windows'
64+
run: cmake -E copy toolchain/tools/fasmg/windows/fasmg.exe CEdev/bin
65+
- name: Setup Fasmg
66+
if: runner.os == 'Linux'
67+
run: |
68+
cp toolchain/tools/fasmg/linux/fasmg CEdev/bin
69+
chmod +x CEdev/bin/fasmg
70+
- name: Setup Fasmg
71+
if: runner.os == 'macOS'
72+
run: |
73+
cp toolchain/tools/fasmg/macos/fasmg CEdev/bin
74+
chmod +x CEdev/bin/fasmg
75+
76+
- name: Build Toolchain
77+
run: make -j4 -C toolchain V=1
78+
- name: Install Toolchain
79+
env:
80+
PREFIX: ${{github.workspace}}
81+
run: make -j4 -C toolchain install release release-libs V=1
82+
- name: Build Examples
83+
run: make -j4 -C ${{env.CEDEV}}/examples V=1
84+
85+
- name: Checkout CEmu
86+
if: github.event_name == 'push'
87+
uses: actions/checkout@v2
88+
with:
89+
repository: CE-Programming/CEmu
90+
ref: latest-stable
91+
path: CEmu
92+
93+
- name: Build CEmu
94+
if: github.event_name == 'push'
95+
run: make -j4 -C CEmu/core
96+
- name: Build Autotester CLI
97+
if: github.event_name == 'push'
98+
run: make -j4 -C CEmu/tests/autotester
99+
100+
- name: Download Secrets
101+
if: github.event_name == 'push'
102+
id: download-secrets
103+
uses: carlosperate/download-file-action@v1.0.3
104+
with:
105+
file-url: https://jacobly.com/CE-Programming/secrets
106+
location: secrets
107+
- name: Decrypt Secrets
108+
if: github.event_name == 'push'
109+
env:
110+
KEY: ${{secrets.SYMMETRIC_KEY_256}}
111+
run: openssl enc -d -aes-256-cbc -iv d0583d991fcb6c3b05fb8eabc7421fb8 -K "$${{env.ENV}}KEY" -in ${{steps.download-secrets.outputs.file-path}} -out secrets/secrets.7z
112+
- name: Extract Secrets
113+
if: github.event_name == 'push'
114+
uses: DuckSoft/extract-7z-action@v1.0
115+
with:
116+
pathSource: secrets/secrets.7z
117+
pathTarget: secrets
118+
119+
- name: Test examples
120+
if: github.event_name == 'push' && runner.os != 'Windows'
121+
env:
122+
AUTOTESTER_LIBS_GROUP: ${{github.workspace}}/toolchain/clibs.8xg
123+
AUTOTESTER_ROM: ${{github.workspace}}/secrets/${{env.ROM}}
124+
run: |
125+
failed=0
126+
find ${{env.CEDEV}}/examples -name autotest.json -print0 | while read -d '' test; do
127+
cmake -E echo "Launching autotester on $test"
128+
autotester "$test"
129+
cmake -E true $((failed += $?))
130+
done
131+
exit $failed
132+
- name: Test examples
133+
if: github.event_name == 'push' && runner.os == 'Windows'
134+
env:
135+
AUTOTESTER_LIBS_GROUP: ${{github.workspace}}\toolchain\clibs.8xg
136+
AUTOTESTER_ROM: ${{github.workspace}}\secrets\${{env.ROM}}
137+
run: |
138+
$failed = 0
139+
foreach ($test in get-childitem "${{env.CEDEV}}\examples" -recurse -include autotest.json) {
140+
cmake -E echo "Launching autotester on $test"
141+
autotester "$test"
142+
$failed += $lastexitcode
143+
}
144+
Exit $failed
145+
146+
- name: Remove Secrets
147+
if: always()
148+
run: cmake -E rm -rf secrets
149+
150+
- name: Upload CEdev
151+
uses: actions/upload-artifact@v2
152+
with:
153+
name: CEdev-${{runner.os}}
154+
path: CEdev
155+
156+
- name: Upload Libraries
157+
uses: actions/upload-artifact@v2
158+
with:
159+
name: clibs
160+
path: toolchain/clibs.8xg
161+
162+
- name: Upload Windows Installer
163+
if: runner.os == 'Windows'
164+
uses: actions/upload-artifact@v2
165+
with:
166+
name: installer-${{runner.os}}
167+
path: toolchain\release\CEdev${{env.EXE}}

.gitignore

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ doxygen/
1212
*.obj
1313
*.elf
1414
*.bin
15+
*.inc
1516
obj/
1617
release/
1718
build/
@@ -23,9 +24,6 @@ linker_script
2324
# precompiled headers
2425
*.gch
2526
*.pch
26-
relocation_table
27-
*_header.asm
28-
*_equates.asm
2927

3028
# libraries
3129
*.lib
@@ -56,7 +54,7 @@ relocation_table
5654
*.log
5755

5856
# fasmg files
57+
src/include/*.alm
5958
src/include/ez80.inc
60-
src/include/ld.fasmg
6159
src/include/ti84pceg.inc
6260
src/include/tiformat.inc

.gitmodules

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,3 +10,4 @@
1010
[submodule "tools/convimg"]
1111
path = tools/convimg
1212
url = https://github.com/mateoconlechuga/convimg.git
13+
ignore = dirty

.travis.yml

Lines changed: 0 additions & 48 deletions
This file was deleted.

CMakeLists.txt

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,23 @@
33

44
cmake_minimum_required(VERSION 3.2)
55

6-
project(toolchain)
6+
project(toolchain C CXX)
77

8-
list(APPEND CMAKE_C_FLAGS "-std=c99 -W -Wall -Wno-incompatible-library-redeclaration -Wno-parentheses -Wno-pointer-sign -Wno-incompatible-pointer-types")
8+
set(COMMON_FLAGS "-W -Wall -Wextra -Wno-incompatible-library-redeclaration -Wno-parentheses -Wno-pointer-sign -Wno-incompatible-pointer-types")
9+
list(APPEND CMAKE_C_FLAGS "-std=c99 ${COMMON_FLAGS}")
10+
list(APPEND CMAKE_CXX_FLAGS "-std=c++14 ${COMMON_FLAGS}")
911

12+
set(INCLUDE_DIRECTORIES "")
1013
include_directories(${CMAKE_SOURCE_DIR}/src/ce
1114
${CMAKE_SOURCE_DIR}/src/fatdrvce
1215
${CMAKE_SOURCE_DIR}/src/fileioc
1316
${CMAKE_SOURCE_DIR}/src/fontlibc
1417
${CMAKE_SOURCE_DIR}/src/graphx
1518
${CMAKE_SOURCE_DIR}/src/keypadc
1619
${CMAKE_SOURCE_DIR}/src/usbdrvce
17-
${CMAKE_SOURCE_DIR}/src/std
18-
${CMAKE_SOURCE_DIR}/src/compatibility)
20+
${CMAKE_SOURCE_DIR}/src/std)
1921

20-
file(GLOB_RECURSE SOURCE_FILES src false *.h *.c)
21-
file(GLOB_RECURSE EXAMPLES_FILES examples false *.h *.c)
22+
file(GLOB_RECURSE SOURCE_FILES src true *.h *.hpp *.c *.cpp)
23+
file(GLOB_RECURSE EXAMPLES_FILES examples true *.h *.hpp *.c *.cpp)
2224

2325
add_executable(toolchain ${SOURCE_FILES} ${EXAMPLES_FILES})

0 commit comments

Comments
 (0)