Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
48 commits
Select commit Hold shift + click to select a range
2fa89fe
Add python3 support
crazyhappygame Dec 1, 2021
242f91d
Update download-deps.py
crazyhappygame Dec 1, 2021
0be91a8
main.yml
crazyhappygame Dec 1, 2021
490e32c
download deps
crazyhappygame Dec 1, 2021
97cf6b3
linux, windows
crazyhappygame Dec 1, 2021
f049c5e
python
crazyhappygame Dec 1, 2021
6ac9bcc
python
crazyhappygame Dec 1, 2021
22b4455
Fix builds
crazyhappygame Dec 1, 2021
c7beb3d
Add macos
crazyhappygame Dec 1, 2021
61cad35
Add macos
crazyhappygame Dec 1, 2021
b2206c5
Fix linux
crazyhappygame Dec 1, 2021
4b874cc
ios, android
crazyhappygame Dec 1, 2021
6b3cc2e
Fix ios
crazyhappygame Dec 1, 2021
80cdde8
ubuntu 18,4
crazyhappygame Dec 1, 2021
b9ded51
Fix ios platform cmake
crazyhappygame Dec 1, 2021
9dafbcc
cpp-tests only
crazyhappygame Dec 1, 2021
a522ac5
--parallel
crazyhappygame Dec 1, 2021
ed8aeb1
linux parallel
crazyhappygame Dec 1, 2021
fdc740c
remove linux parallel
crazyhappygame Dec 1, 2021
1f851bd
ios:
crazyhappygame Dec 1, 2021
a18de89
quiet
crazyhappygame Dec 1, 2021
6393bc2
Enable all
crazyhappygame Dec 1, 2021
d56ac70
a
crazyhappygame Dec 1, 2021
d988746
arm64
crazyhappygame Dec 2, 2021
6e92cb4
ios
crazyhappygame Dec 2, 2021
38d1ebd
new line
crazyhappygame Dec 2, 2021
db8061c
Update CDAudioManager.m
crazyhappygame Dec 2, 2021
a59bfab
Update CDXMacOSXSupport.h
crazyhappygame Dec 2, 2021
261ac6b
Merge branch 'cocos2d:v3' into v3
crazyhappygame Dec 2, 2021
fa39792
Merge pull request #1 from crazyhappygame/crazyhappygame-patch-1
crazyhappygame Dec 2, 2021
7925a6e
cmake pch
crazyhappygame Dec 2, 2021
07e7401
change path
crazyhappygame Dec 2, 2021
5cf95bb
add xcode
crazyhappygame Dec 2, 2021
6a26d8c
mac cpp-tests only
crazyhappygame Dec 2, 2021
312e437
pch
crazyhappygame Dec 2, 2021
e19b486
xcode
crazyhappygame Dec 2, 2021
7428990
xcode
crazyhappygame Dec 2, 2021
9ebb125
xcode
crazyhappygame Dec 2, 2021
6b4ed13
android pch
crazyhappygame Dec 2, 2021
22b2689
3.18.0+
crazyhappygame Dec 2, 2021
713eb63
a
crazyhappygame Dec 2, 2021
a4919ea
Merge branch 'cocos2d:v3' into v3
crazyhappygame Dec 3, 2021
84cf7bc
Merge branch 'v3' into cmake_pch
crazyhappygame Dec 3, 2021
6572a71
andoid at front
crazyhappygame Dec 3, 2021
e7b39c5
ONLY_ACTIVE_ARCH 'YES'
crazyhappygame Dec 3, 2021
b99910e
rollback
crazyhappygame Dec 3, 2021
0908cd8
Remove --target
crazyhappygame Dec 3, 2021
c9b88db
a
crazyhappygame Dec 3, 2021
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
37 changes: 19 additions & 18 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,15 @@ jobs:
- run: cmake -B b -S .
- run: cmake --build b

ubuntu-20_04:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- run: python download-deps.py --r no
- run: echo -e "y" | bash build/install-deps-linux.sh
- run: cmake -B b -S .
- run: cmake --build b
# https://github.com/cocos2d/cocos2d-x/issues/20471
# ubuntu-20_04:
# runs-on: ubuntu-20.04
# steps:
# - uses: actions/checkout@v2
# - run: python download-deps.py --r no
# - run: echo -e "y" | bash build/install-deps-linux.sh
# - run: cmake -B b -S .
# - run: cmake --build b

windows-2019:
runs-on: windows-2019
Expand All @@ -51,34 +52,34 @@ jobs:
steps:
- uses: actions/checkout@v2
- run: python download-deps.py --r no
- run: cmake -B b -S .
- run: cmake --build b
- run: cmake -B b -S . -GXcode
- run: cmake --build b --target cpp-tests

macos-11:
runs-on: macos-11
steps:
- uses: actions/checkout@v2
- run: python download-deps.py --r no
- run: cmake -B b -S .
- run: cmake --build b
- run: cmake -B b -S . -GXcode
- run: cmake --build b --target cpp-tests

macos-10_15_ios:
ios_macos-10_15:
runs-on: macos-10.15
steps:
- uses: actions/checkout@v2
- run: python download-deps.py --r no
- run: cmake -B b -S . -GXcode -DCMAKE_SYSTEM_NAME=iOS -DCMAKE_OSX_SYSROOT=iphonesimulator
- run: cmake -B b -S . -GXcode -DCMAKE_SYSTEM_NAME=iOS -DCMAKE_OSX_SYSROOT=iphonesimulator -DCMAKE_SYSTEM_PROCESSOR=arm64
- run: cmake --build b --config Release --target cpp-tests -- -quiet

macos-11_ios:
ios_macos-11:
runs-on: macos-11
steps:
- uses: actions/checkout@v2
- run: python download-deps.py --r no
- run: cmake -B b -S . -GXcode -DCMAKE_SYSTEM_NAME=iOS -DCMAKE_OSX_SYSROOT=iphonesimulator
- run: cmake -B b -S . -GXcode -DCMAKE_SYSTEM_NAME=iOS -DCMAKE_OSX_SYSROOT=iphonesimulator -DCMAKE_SYSTEM_PROCESSOR=arm64
- run: cmake --build b --config Release --target cpp-tests -- -quiet -destination "platform=iOS Simulator,name=iPhone Retina (4-inch)"

windows-2019-android:
android_windows-2019:
runs-on: windows-2019
steps:
- uses: actions/checkout@v2
Expand All @@ -87,7 +88,7 @@ jobs:
shell: bash
working-directory: tests/cpp-tests/proj.android

ubuntu-20_04-android:
android_ubuntu-20_04:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
Expand Down
11 changes: 4 additions & 7 deletions cocos/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -162,11 +162,8 @@ if(XCODE OR VS)
cocos_mark_code_files("cocos2d")
endif()

if(WINDOWS)
# precompiled header. Compilation time speedup ~4x.
target_sources(cocos2d PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/precheader.cpp")
set_target_properties(cocos2d PROPERTIES COMPILE_FLAGS "/Yuprecheader.h /FIprecheader.h")
set_source_files_properties("${CMAKE_CURRENT_SOURCE_DIR}/precheader.cpp" PROPERTIES COMPILE_FLAGS "/Ycprecheader.h")
# compile c as c++. needed for precompiled header
set_source_files_properties(${COCOS_SPINE_SRC} base/ccFPSImages.c PROPERTIES LANGUAGE CXX)
if(${CMAKE_VERSION} VERSION_GREATER "3.16.0")
message("CMake 3.16 target_precompile_headers")
target_precompile_headers(cocos2d PRIVATE
"$<$<COMPILE_LANGUAGE:CXX>:cocos2d.h>")
endif()
9 changes: 4 additions & 5 deletions cocos/scripting/js-bindings/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -180,9 +180,8 @@ if(XCODE OR VS)
cocos_mark_code_files("jscocos2d")
endif()

if(WINDOWS)
# precompiled header
target_sources(jscocos2d PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/precheader.cpp")
set_target_properties(jscocos2d PROPERTIES COMPILE_FLAGS "/Yuprecheader.h /FIprecheader.h")
set_source_files_properties("${CMAKE_CURRENT_SOURCE_DIR}/precheader.cpp" PROPERTIES COMPILE_FLAGS "/Ycprecheader.h")
if(${CMAKE_VERSION} VERSION_GREATER "3.16.0")
message("CMake 3.16 target_precompile_headers")
target_precompile_headers(jscocos2d PRIVATE
"$<$<COMPILE_LANGUAGE:CXX>:precheader.h>")
endif()
9 changes: 4 additions & 5 deletions tests/cpp-tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -486,9 +486,8 @@ if(LINUX OR WINDOWS)
cocos_copy_target_res(${APP_NAME} COPY_TO ${APP_RES_DIR} FOLDERS ${GAME_RES_FOLDER})
endif()

if(WINDOWS)
# precompiled header. Compilation time speedup ~4x.
target_sources(${APP_NAME} PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/Classes/precheader.cpp")
set_target_properties(${APP_NAME} PROPERTIES COMPILE_FLAGS "/Yuprecheader.h /FIprecheader.h")
set_source_files_properties("${CMAKE_CURRENT_SOURCE_DIR}/Classes/precheader.cpp" PROPERTIES COMPILE_FLAGS "/Ycprecheader.h")
if(${CMAKE_VERSION} VERSION_GREATER "3.16.0")
message("CMake 3.16 target_precompile_headers")
target_precompile_headers(${APP_NAME} PRIVATE
"$<$<COMPILE_LANGUAGE:CXX>:precheader.h>")
endif()