Skip to content

Commit

Permalink
Build fixes for BN update
Browse files Browse the repository at this point in the history
  • Loading branch information
CedricGuillemet committed Oct 2, 2023
1 parent b292711 commit 2d8fda0
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ set(BABYLON_NATIVE_BUILD_APPS OFF CACHE BOOL "")
set(BABYLON_NATIVE_USE_SWAPCHAINPANEL ON CACHE BOOL "")
set(BABYLON_NATIVE_DIR "${BABYLON_REACT_NATIVE_IOSANDROID}/submodules/BabylonNative")
add_subdirectory(${BABYLON_NATIVE_DIR} ${CMAKE_CURRENT_BINARY_DIR}/BabylonNative EXCLUDE_FROM_ALL)
# Disable Unity build for UrlLib because of conflict in header between windows.h and winrt
set_property(TARGET UrlLib PROPERTY UNITY_BUILD false)

add_library(BabylonNative
${SHARED_SOURCES})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ function Restore-CMakeProject {
}

cd $BuildDir
cmake -D CMAKE_SYSTEM_NAME=WindowsStore -D CMAKE_SYSTEM_VERSION=10.0 -A $Arch ..\..\..\windows
cmake -G "Visual Studio 16 2019" -D CMAKE_SYSTEM_NAME=WindowsStore -D CMAKE_SYSTEM_VERSION=10.0 -G "Visual Studio 16 2019" -A $Arch ..\..\..\windows

if ($? -Eq $False) {
Write-Error "cmake failed. Make sure cmake is added to your PATH variable"
Expand Down
2 changes: 1 addition & 1 deletion Package/gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ const initializeSubmodulesMostRecentBabylonNative = async () => {

const makeUWPProjectPlatform = async (name, arch) => {
shelljs.mkdir('-p', `./../Modules/@babylonjs/react-native/Build/uwp_${name}`);
exec(`cmake -D CMAKE_SYSTEM_NAME=WindowsStore -D CMAKE_SYSTEM_VERSION=10.0 -DCMAKE_UNITY_BUILD=true ${cmakeBasekitBuildDefinition} -A ${arch} ./../../../react-native-windows/windows`, `./../Modules/@babylonjs/react-native/Build/uwp_${name}`);
exec(`cmake -G "Visual Studio 16 2019" -D CMAKE_SYSTEM_NAME=WindowsStore -D CMAKE_SYSTEM_VERSION=10.0 -DCMAKE_UNITY_BUILD=true ${cmakeBasekitBuildDefinition} -A ${arch} ./../../../react-native-windows/windows`, `./../Modules/@babylonjs/react-native/Build/uwp_${name}`);
};

const makeUWPProjectx86 = async () => makeUWPProjectPlatform('x86', 'Win32');
Expand Down

0 comments on commit 2d8fda0

Please sign in to comment.