-
Notifications
You must be signed in to change notification settings - Fork 16
/
Copy pathBuildAllBindings.bat
64 lines (53 loc) · 1.09 KB
/
BuildAllBindings.bat
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
@echo off
setlocal enableDelayedExpansion
rem Path to Dear ImGui files
set IMGUI_PATH=..\imgui
rem Output path
set OUTPUT_PATH=generated
if not exist "generated" mkdir "generated"
if not exist "generated\backends" mkdir "generated\backends"
rem Process main imgui.h header
echo.
echo Processing imgui.h
echo.
python dear_bindings.py -o %OUTPUT_PATH%\dcimgui %IMGUI_PATH%\imgui.h
IF ERRORLEVEL 1 GOTO fail
rem Process imgui_internal.h header
echo.
echo Processing imgui_internal.h
echo.
python dear_bindings.py -o %OUTPUT_PATH%\dcimgui_internal --include %IMGUI_PATH%\imgui.h %IMGUI_PATH%\imgui_internal.h
IF ERRORLEVEL 1 GOTO fail
rem Process backends
for %%n in (
allegro5
android
dx9
dx10
dx11
dx12
glfw
glut
opengl2
opengl3
sdl2
sdlrenderer2
sdl3
sdlrenderer3
vulkan
wgpu
win32
) do (
echo.
echo Processing %%n
echo.
python dear_bindings.py --backend --imconfig-path %IMGUI_PATH%\imconfig.h -o %OUTPUT_PATH%\backends\dcimgui_impl_%%n %IMGUI_PATH%\backends\imgui_impl_%%n.h
IF ERRORLEVEL 1 GOTO fail
)
echo.
echo Processing completed
goto end
:fail
echo.
echo Processing failed
:end