vcpkg/ports/minifb/fix-build-error.patch
NancyLi1013 408990caef [minifb] Add new port (#7766)
* [minifb] Add new port

* Fix arm build error

* Add fix-arm-build-error.patch file

* Update fix-arm-build-error.patch file
2019-08-27 15:53:18 -07:00

26 lines
957 B
Diff

diff --git a/src/windows/WinMiniFB.c b/src/windows/WinMiniFB.c
index 84ed0cb..b33f252 100644
--- a/src/windows/WinMiniFB.c
+++ b/src/windows/WinMiniFB.c
@@ -19,7 +19,7 @@ LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
{
LRESULT res = 0;
- SWindowData *window_data = (SWindowData *) GetWindowLongPtr(hWnd, GWL_USERDATA);
+ SWindowData *window_data = (SWindowData *) GetWindowLongPtr(hWnd, GWLP_USERDATA);
SWindowData_Win *window_data_win = 0x0;
if(window_data != 0x0) {
window_data_win = (SWindowData_Win *) window_data->specific;
diff --git a/tests/multiple_windows.c b/tests/multiple_windows.c
index 4b301c0..29276be 100644
--- a/tests/multiple_windows.c
+++ b/tests/multiple_windows.c
@@ -1,6 +1,7 @@
#include <MiniFB.h>
#include <stdio.h>
#include <stdint.h>
+#define _USE_MATH_DEFINES
#include <math.h>
#define kUnused(var) (void) var;