CI: Fix testing for Windows DLL builds + fix broken DLL build. (#3603, #3601)

This commit is contained in:
Borislav Stanimirov 2020-11-18 22:05:52 +02:00 committed by ocornut
parent 2e64ee050d
commit fcc2b71724
3 changed files with 13 additions and 11 deletions

View File

@ -49,7 +49,8 @@ jobs:
shell: cmd shell: cmd
run: | run: |
cd examples\example_null cd examples\example_null
"%VS_PATH%\VC\Auxiliary\Build\vcvarsall.bat" x64 && .\build_win32.bat /W4 call "%VS_PATH%\VC\Auxiliary\Build\vcvars64.bat"
.\build_win32.bat /W4
- name: Build example_null (single file build) - name: Build example_null (single file build)
shell: bash shell: bash
@ -71,14 +72,14 @@ jobs:
- name: Build example_null (as DLL) - name: Build example_null (as DLL)
shell: cmd shell: cmd
run: | run: |
"%VS_PATH%\VC\Auxiliary\Build\vcvarsall.bat" x64 call "%VS_PATH%\VC\Auxiliary\Build\vcvars64.bat"
echo '#ifdef _EXPORT' > example_single_file.cpp echo #ifdef _EXPORT > example_single_file.cpp
echo '# define IMGUI_API __declspec(dllexport)' >> example_single_file.cpp echo # define IMGUI_API __declspec(dllexport) >> example_single_file.cpp
echo '#else' >> example_single_file.cpp echo #else >> example_single_file.cpp
echo '# define IMGUI_API __declspec(dllimport)' >> example_single_file.cpp echo # define IMGUI_API __declspec(dllimport) >> example_single_file.cpp
echo '#endif' >> example_single_file.cpp echo #endif >> example_single_file.cpp
echo '#define IMGUI_IMPLEMENTATION' >> example_single_file.cpp echo #define IMGUI_IMPLEMENTATION >> example_single_file.cpp
echo '#include "misc/single_file/imgui_single_file.h"' >> example_single_file.cpp echo #include "misc/single_file/imgui_single_file.h" >> example_single_file.cpp
cl.exe /D_USRDLL /D_WINDLL /D_EXPORT /I. example_single_file.cpp /LD /FeImGui.dll /link cl.exe /D_USRDLL /D_WINDLL /D_EXPORT /I. example_single_file.cpp /LD /FeImGui.dll /link
cl.exe /I. ImGui.lib /Feexample_null.exe examples/example_null/main.cpp cl.exe /I. ImGui.lib /Feexample_null.exe examples/example_null/main.cpp

View File

@ -89,6 +89,7 @@ Other Changes:
- Backends: OSX: Fix keypad-enter key not working on MacOS. (#3554) [@rokups, @lfnoise] - Backends: OSX: Fix keypad-enter key not working on MacOS. (#3554) [@rokups, @lfnoise]
- Examples: Apple+Metal: Consolidated/simplified to get closer to other examples. (#3543) [@warrenm] - Examples: Apple+Metal: Consolidated/simplified to get closer to other examples. (#3543) [@warrenm]
- Examples: Apple+Metal: Forward events down so OS key combination like Cmd+Q can work. (#3554) [@rokups] - Examples: Apple+Metal: Forward events down so OS key combination like Cmd+Q can work. (#3554) [@rokups]
- CI: Fix testing for Windows DLL builds. (#3603, #3601) [@iboB]
- Docs: Split examples/README.txt into docs/BACKENDS.md and docs/EXAMPLES.md improved them. - Docs: Split examples/README.txt into docs/BACKENDS.md and docs/EXAMPLES.md improved them.
- Docs: Consistently renamed all occurences of "binding" and "back-end" to "backend" in comments and docs. - Docs: Consistently renamed all occurences of "binding" and "back-end" to "backend" in comments and docs.

View File

@ -1127,8 +1127,8 @@ struct IMGUI_API ImGuiStackSizes
short SizeOfBeginPopupStack; short SizeOfBeginPopupStack;
ImGuiStackSizes() { memset(this, 0, sizeof(*this)); } ImGuiStackSizes() { memset(this, 0, sizeof(*this)); }
IMGUI_API void SetToCurrentState(); void SetToCurrentState();
IMGUI_API void CompareWithCurrentState(); void CompareWithCurrentState();
}; };
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------