Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
hsm4 committed Jul 4, 2024
2 parents 4b8bee9 + 388a299 commit 80992a6
Show file tree
Hide file tree
Showing 1,665 changed files with 161,909 additions and 122,661 deletions.
7 changes: 5 additions & 2 deletions .github/workflows/build-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,8 @@ jobs:
run: doxygen

- name: Upload documentation
working-directory: ${{ github.workspace }}/docs/html
run: tar -czf - * | sshpass -p "${{ secrets.EMSCRIPTEN_DEPLOY_PASSWORD }}" ssh -o StrictHostKeyChecking=no [email protected] "rm -rf docs && mkdir docs && cd docs && tar xzvf -"
working-directory: ${{ github.workspace }}/docs
run: |
sshpass -p "${{ secrets.EMSCRIPTEN_DEPLOY_PASSWORD }}" sftp -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null "${{ secrets.EMSCRIPTEN_DEPLOY_REMOTE }}" << EOF
put -r html public/www/docs
EOF
4 changes: 2 additions & 2 deletions .github/workflows/build-wasm-emscripten.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@ jobs:
- name: Install Emscripten
uses: mymindstorm/setup-emsdk@v11
with:
version: 3.1.46
version: 3.1.60

- name: Configure CMake
run: emcmake cmake -B ${{ github.workspace }}/build -DSL_BUILD_WAI=OFF -DSL_BUILD_WITH_OPENSSL=OFF -DSL_DOWNLOAD_DATA=OFF

- name: Build
run: cmake --build ${{ github.workspace }}/build --target app-Demo-SLProject -j $(nproc)
run: cmake --build ${{ github.workspace }}/build --target app-demo -j $(nproc)
22 changes: 17 additions & 5 deletions .github/workflows/deploy-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@ concurrency:
cancel-in-progress: false

jobs:
deploy:
build-docs:
runs-on: ubuntu-22.04

steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Install Doxygen
run: sudo apt install -y doxygen
Expand All @@ -34,13 +34,25 @@ jobs:
working-directory: ${{ github.workspace }}/docs
run: doxygen

- name: Setup GitHub Pages
uses: actions/configure-pages@v5
- name: Copy Images
run: cp -r ${{ github.workspace }}/docs/images ${{ github.workspace }}/docs/html

- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: "${{ github.workspace }}/docs/html"
path: ${{ github.workspace }}/docs/html

deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}

needs: build-docs
runs-on: ubuntu-22.04

steps:
- name: Setup GitHub Pages
uses: actions/configure-pages@v5

- name: Deploy to GitHub Pages
id: deployment
Expand Down
22 changes: 18 additions & 4 deletions .github/workflows/deploy-wasm-emscripten.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,28 @@ jobs:
- name: Install Emscripten
uses: mymindstorm/setup-emsdk@v11
with:
version: 3.1.46
version: 3.1.60

- name: Configure CMake
run: emcmake cmake -B ${{ github.workspace }}/build -DSL_BUILD_WAI=OFF -DSL_BUILD_WITH_OPENSSL=OFF -DSL_DOWNLOAD_DATA=OFF -DCMAKE_BUILD_TYPE=Release
run: |
emcmake cmake \
-B ${{ github.workspace }}/build \
-DSL_BUILD_WAI=OFF \
-DSL_BUILD_WITH_OPENSSL=OFF \
-DSL_BUILD_WITH_MEDIAPIPE=OFF \
-DSL_DOWNLOAD_DATA=OFF \
-DCMAKE_BUILD_TYPE=Release
- name: Build
run: cmake --build ${{ github.workspace }}/build --target app-Demo-SLProject -j $(nproc)
run: cmake --build ${{ github.workspace }}/build --target app-demo -j $(nproc)

- name: Upload
working-directory: ${{ github.workspace }}/build
run: sshpass -p "${{ secrets.EMSCRIPTEN_DEPLOY_PASSWORD }}" scp -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null app-Demo-SLProject.* [email protected]:.
run: |
sshpass -p "${{ secrets.EMSCRIPTEN_DEPLOY_PASSWORD }}" sftp -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null "${{ secrets.EMSCRIPTEN_DEPLOY_REMOTE }}" << EOF
put app-demo.html public/www/app-demo.html
put app-demo.js public/www/app-demo.js
put app-demo.wasm public/www/app-demo.wasm
put app-demo.worker.js public/www/app-demo.worker.js
put app-demo.ww.js public/www/app-demo.ww.js
EOF
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -92,4 +92,5 @@ Tester
/externals/prebuild_scripts/eigen
/externals/prebuild_scripts/openssl

docs/html
docs/html
.clangd
38 changes: 28 additions & 10 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,21 @@ endif ()
include(cmake/SetGitBranchNameAndCommitID.cmake)
include(cmake/CompileOptions.cmake)

# Determine the platform that apps will run on.
# On desktop operating systems, the platform is GLFW.
# On Android, iOS, and Emscripten, the platform name is just directly the system name.
if(SYSTEM_NAME_UPPER MATCHES "^(WINDOWS|DARWIN|LINUX)$")
set(SL_PLATFORM "GLFW")
elseif(SYSTEM_NAME_UPPER STREQUAL "ANDROID")
set(SL_PLATFORM "ANDROID")
elseif(SYSTEM_NAME_UPPER STREQUAL "IOS")
set(SL_PLATFORM "IOS")
elseif(SYSTEM_NAME_UPPER STREQUAL "EMSCRIPTEN")
set(SL_PLATFORM "EMSCRIPTEN")
else()
set(SL_PLATFORM "UNKNOWN")
endif()

option(SL_DOWNLOAD_DATA "Specifies if the data ZIP file should be downloaded" ON)
option(SL_DOWNLOAD_PREBUILTS "Specifies if prebuilt libraries should be downloaded" ON)
option(SL_BUILD_WAI "Specifies if the WAI library should be built" ON)
Expand All @@ -54,18 +69,22 @@ option(SL_BUILD_WITH_OPTIX "Specifies if Optix renderer should be built" OFF)
option(SL_BUILD_WITH_KTX "Specifies if Kronos Texture library (ktx) should be used" ON)
option(SL_BUILD_WITH_OPENSSL "Specifies if OpenSSL should be used" ON)
option(SL_BUILD_WITH_ASSIMP "Specifies if Assimp should be used" ON)

if ("${SYSTEM_NAME_UPPER}" MATCHES "IOS" OR "${SYSTEM_NAME_UPPER}" MATCHES "EMSCRIPTEN")
option(SL_BUILD_WITH_MEDIAPIPE "Specifies if MediaPipe should be used" OFF)
else ()
option(SL_BUILD_WITH_MEDIAPIPE "Specifies if MediaPipe should be used" ON)
endif ()
option(SL_BUILD_WITH_MEDIAPIPE "Specifies if MediaPipe should be used" ON)

option(LIBIGL_USE_STATIC_LIBRARY "Specifies if LibIGL should be built statically" ON)

if(SYSTEM_NAME_UPPER STREQUAL "IOS")
set(SL_BUILD_WITH_MEDIAPIPE OFF)
elseif(SYSTEM_NAME_UPPER STREQUAL "EMSCRIPTEN")
set(SL_BUILD_WAI OFF)
set(SL_BUILD_WITH_OPENSSL OFF)
set(SL_BUILD_WITH_MEDIAPIPE OFF)
endif()

message(STATUS "----------------------------------------------------------------")
message(STATUS "System: ${SYSTEM_NAME_UPPER}")
message(STATUS "Architecture: ${CMAKE_SYSTEM_PROCESSOR}")
message(STATUS "Platform: ${SL_PLATFORM}")
message(STATUS "----------------------------------------------------------------")
message(STATUS "SL_DOWNLOAD_PREBUILTS: ${SL_DOWNLOAD_PREBUILTS}")
message(STATUS "SL_BUILD_WAI: ${SL_BUILD_WAI}")
Expand All @@ -83,16 +102,15 @@ message(STATUS "----------------------------------------------------------------

if (SL_DOWNLOAD_DATA)
include(cmake/DownloadData.cmake)
message(STATUS "----------------------------------------------------------------")
endif ()

message(STATUS "----------------------------------------------------------------")

if (SL_DOWNLOAD_PREBUILTS)
include(cmake/DownloadPrebuilts.cmake)
message(STATUS "Finished downloading prebuilts")
message(STATUS "----------------------------------------------------------------")
endif ()

message(STATUS "----------------------------------------------------------------")

if ("${CMAKE_SYSTEM_NAME}" MATCHES "Android")
message(STATUS "SL_APP: ${SL_APP}")
option(SL_APP
Expand Down
Loading

0 comments on commit 80992a6

Please sign in to comment.