Skip to content

Commit 0428b5c

Browse files
authored
[actions] ccache in xcodebuild (#7855)
#changelog #actions
1 parent c6f95df commit 0428b5c

9 files changed

Lines changed: 34 additions & 14 deletions

File tree

.github/workflows/build-ios-tvos.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,11 @@ jobs:
3232
TARGET: ${{matrix.cfg.target}}
3333
steps:
3434
- uses: actions/checkout@v4
35+
- name: ccache
36+
uses: hendrikmuhs/ccache-action@v1.2.11
37+
with:
38+
key: ${{ matrix.cfg.target }}-${{ matrix.cfg.libs }}
39+
3540
- name: Download libs
3641
run: ./scripts/${{matrix.cfg.libs}}/download_libs.sh
3742
- name: install

.github/workflows/build-msys2.yml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -41,15 +41,15 @@ jobs:
4141
- uses: msys2/setup-msys2@v2
4242
with:
4343
cache: true
44-
update: true
44+
update: false
4545
msystem: ${{matrix.msystem}}
46-
install: >-
47-
unzip
46+
pacboy: assimp:p cairo:p curl:p freeglut:p FreeImage:p gcc:p gdb:p glew:p glfw:p glm:p harfbuzz:p libsndfile:p libusb:p libxml2:p mpg123:p nlohmann-json:p ntldd-git:p openal:p opencv:p pkgconf:p pugixml:p rtaudio:p uriparser:p utf8cpp:p zlib:p poco:p
47+
# boost:p tools:p
48+
# install: >-
49+
# unzip
4850
# git
4951
# rsync
5052
# wget
51-
pacboy: assimp:p cairo:p curl:p freeglut:p FreeImage:p gcc:p gdb:p glew:p glfw:p glm:p harfbuzz:p libsndfile:p libusb:p libxml2:p mpg123:p nlohmann-json:p ntldd-git:p openal:p opencv:p pkgconf:p pugixml:p rtaudio:p uriparser:p utf8cpp:p zlib:p poco:p
52-
# boost:p tools:p
5353

5454
- name: Install dependencies
5555
run: ./scripts/ci/msys2/install.sh
@@ -59,3 +59,4 @@ jobs:
5959

6060
- name: Run tests
6161
run: ./scripts/ci/msys2/run_tests.sh
62+

libs/openFrameworksCompiled/project/ios/CoreOF.xcconfig

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,3 +96,6 @@ ENABLE_BITCODE = NO
9696
ENABLE_STRICT_OBJC_MSGSEND = YES
9797

9898
CONFIGURATION_BUILD_DIR = $(SRCROOT)/bin/
99+
100+
CC = $(OF_PATH)/scripts/osx/cc.sh
101+
CXX = $(OF_PATH)/scripts/osx/cxx.sh

libs/openFrameworksCompiled/project/makefileCommon/compile.core.mk

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
################################################################################
44
ifdef MAKEFILE_DEBUG
5-
$(info ===================compile.core.make================================)
5+
$(info ===================compile.core.make================================)
66
endif
77

88
ifdef PROJECT_CXX
@@ -36,7 +36,7 @@ else
3636
endif
3737

3838
ifdef ${ccache}
39-
$(info 💿 Using CCACHE - Compile.core.mk )
39+
$(info 💿 Using CCACHE - compile.core.mk )
4040
CXX := ${ccache} $(CXX)
4141
CC := ${ccache} $(CXX)
4242
endif
@@ -187,14 +187,14 @@ OF_CORE_OBJ_FILES = $(addprefix $(OF_CORE_OBJ_OUTPUT_PATH),$(patsubst $(OF_ROOT)
187187
# DEBUG INFO
188188
################################################################################
189189
ifdef MAKEFILE_DEBUG
190-
$(info ========================= compile.core.make flags ========================)
191-
$(info OF_CORE_OBJ_OUTPUT_PATH=$(OF_CORE_OBJ_OUTPUT_PATH))
190+
$(info ========================= compile.core.make flags ========================)
191+
$(info OF_CORE_OBJ_OUTPUT_PATH=$(OF_CORE_OBJ_OUTPUT_PATH))
192192

193-
$(info ---OF_CORE_DEPENDENCY_FILES---)
194-
$(foreach v, $(OF_CORE_DEPENDENCY_FILES),$(info $(v)))
193+
$(info ---OF_CORE_DEPENDENCY_FILES---)
194+
$(foreach v, $(OF_CORE_DEPENDENCY_FILES),$(info $(v)))
195195

196-
$(info ---OF_CORE_OBJ_FILES---)
197-
$(foreach v, $(OF_CORE_OBJ_FILES),$(info $(v)))
196+
$(info ---OF_CORE_OBJ_FILES---)
197+
$(foreach v, $(OF_CORE_OBJ_FILES),$(info $(v)))
198198
endif
199199

200200

libs/openFrameworksCompiled/project/makefileCommon/compile.project.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ Release:
129129
ifndef ABIS_TO_COMPILE_RELEASE
130130
@$(MAKE) -j ReleaseABI
131131
else
132-
@$(foreach abi,$(ABIS_TO_COMPILE_RELEASE),$(MAKE) ReleaseABI ABI=$(abi) &&) echo
132+
@$(foreach abi,$(ABIS_TO_COMPILE_RELEASE),$(MAKE) -j ReleaseABI ABI=$(abi) &&) echo
133133
endif
134134

135135

libs/openFrameworksCompiled/project/osx/CoreOF.xcconfig

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,3 +113,6 @@ WRAPPER_EXTENSION = app
113113

114114
SKIP_INSTALL = YES
115115
CONFIGURATION_BUILD_DIR = $(SRCROOT)/bin/
116+
117+
CC = $(OF_PATH)/scripts/osx/cc.sh
118+
CXX = $(OF_PATH)/scripts/osx/cxx.sh

libs/openFrameworksCompiled/project/tvOS/CoreOF.xcconfig

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,3 +68,6 @@ GCC_WARN_ABOUT_INVALID_OFFSETOF_MACRO = NO
6868
GCC_WARN_ABOUT_RETURN_TYPE = YES
6969

7070
CONFIGURATION_BUILD_DIR = $(SRCROOT)/bin/
71+
72+
CC = $(OF_PATH)/scripts/osx/cc.sh
73+
CXX = $(OF_PATH)/scripts/osx/cxx.sh

scripts/osx/cc.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
#!/bin/zsh
2+
${ccache} clang "$@"

scripts/osx/cxx.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#!/bin/zsh
2+
${ccache} clang++ "$@"
3+

0 commit comments

Comments
 (0)