This repository has been archived by the owner on Nov 7, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 123
/
MakeWindows
36 lines (28 loc) · 1.44 KB
/
MakeWindows
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
URHO3D_SRC_DIR=Urho3D/Source
VS_VER=15
ARCH=Win64
RENDERER=OPENGL
CONFIG=Release
TARGET=Visual Studio $(VS_VER) $(ARCH)
TOOLS_DIR=../../Bin/Tools/Win64
ifeq ($(ARCH), Win64)
TARGET=Visual Studio $(VS_VER) Win64
else
TARGET=Visual Studio $(VS_VER)
endif
ifeq ($(RENDERER), D3D11)
RENDERER_FLAGS=-DURHO3D_OPENGL=0 -DURHO3D_D3D11=1
else
RENDERER_FLAGS=-DURHO3D_OPENGL=1
endif
ifeq ($(CONFIG), Debug)
LIB_PREFIX=_d
endif
Urho3D_Windows:
rm -rf Urho3D/Urho3D_Windows/CMakeFiles && rm -rf Urho3D/Urho3D_Windows/CMakeCache.txt && cd $(URHO3D_SRC_DIR) && cmake -E make_directory ../Urho3D_Windows && cmake -E chdir ../Urho3D_Windows cmake -G "$(TARGET)" ../Urho3D_Windows $(RENDERER_FLAGS) -DURHO3D_WEBP=0 -DURHO3D_PCH=0 -DURHO3D_LUA=0 -DURHO3D_ANGELSCRIPT=0 -VS=$(VS_VER) ../../$(URHO3D_SRC_DIR)
libUrho3D.a: Urho3D_Windows
cd Urho3D/Urho3D_Windows && cmake --build . --target Urho3D --config $(CONFIG) && cmake --build . --target PackageTool --config Release && cp lib/Urho3D$(LIB_PREFIX).lib lib/Urho3D$(LIB_PREFIX)_$(ARCH)_$(RENDERER).lib
CoreData.pak:
Urho3D/Urho3D_Windows/bin/tool/PackageTool.exe Urho3D/CoreData Urho3D/CoreData.pak -q
Tools: Urho3D_Windows
cd Urho3D/Urho3D_Windows && cmake --build . --target AssetImporter --config Release && cmake --build . --target PackageTool --config Release && mkdir -p $(TOOLS_DIR) && cp bin/tool/AssetImporter.exe $(TOOLS_DIR)/AssetImporter_Win64.exe && cp bin/tool/PackageTool.exe $(TOOLS_DIR)/PackageTool_Win64.exe