Skip to content

Commit 9488653

Browse files
committed
Fix nmake build
1 parent 834d83c commit 9488653

File tree

6 files changed

+15
-8
lines changed

6 files changed

+15
-8
lines changed

sources/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
# Microsoft make utility
88
MAKE=nmake
99
# Borland make utility
10-
BMAKE=C:\Program Files\Borland\CBuilder5\Bin\make
10+
BMAKE="C:\Program Files\Borland\CBuilder5\Bin\make"
1111

1212
all:
1313
md ..\binaries

sources/ParamDesk/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ SOURCES = Application/StdAfx.cpp Application/ParamDesk.cpp common/ParamPageEvent
2222
Params/KnockPageDlg.cpp Params/MiscPageDlg.cpp Params/ParamDeskDlg.cpp Params/StarterPageDlg.cpp \
2323
Params/TemperPageDlg.cpp Params/IORemappingDlg.cpp Params/SecurPageDlg.cpp Tables/TablesDeskDlg.cpp \
2424
Tables/TDContextMenuManager.cpp Params/InjectorPageDlg.cpp Params/LambdaPageDlg.cpp Params/AccelEnrPageDlg.cpp \
25-
common/ParamTabBaseDlg.cpp
25+
common/ParamTabBaseDlg.cpp Params/UniOutPageDlg.cpp
2626

2727
# DLL building
2828
all: paramdesk

sources/secu3man/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ CC = cl
66
# resource compiler
77
RC = rc
88
# compiler flags
9-
CFLAGS = /nologo /W3 /GX /GR /O2 /Ob2 /DWIN32 /D_WINDOWS -I.. -I../secu3man -I../secu3man/Application /MD -D_AFXDLL /Ycstdafx.h
9+
CFLAGS = /nologo /W3 /GX /GR /O2 /Ob2 /DWIN32 /D_WINDOWS -I.. -I../secu3man -I../secu3man/Application -I../ParamDesk /MD -D_AFXDLL /Ycstdafx.h
1010
CFLAGS = $(CFLAGS) -D_CRT_NON_CONFORMING_SWPRINTFS -D_CRT_SECURE_NO_WARNINGS -D_SCL_SECURE_NO_WARNINGS
1111
CFLAGS = $(CFLAGS) /D NDEBUG
1212
CFLAGS = $(CFLAGS) -D_WIN32_WINDOWS=0x0501 -DWINVER=0x0501

sources/ui-core/AnalogMeter.cpp

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,9 @@
2424
#include <math.h>
2525
#include "AnalogMeter.h"
2626

27+
#undef min //fucking stuff
28+
#undef max
29+
2730
//IF You use _UNICODE:
2831
//In the Output category of the Link tab in the Project Settings dialog box,
2932
//set the Entry Point Symbol to wWinMainCRTStartup.
@@ -698,8 +701,8 @@ void CAnalogMeter::DrawNeedle()
698701
}
699702

700703
dAngleRad = (m_dNeedlePos - m_dMinScale)*m_dRadiansPerValue - m_dLimitAngleRad;
701-
dAngleRad = max(dAngleRad, -m_dLimitAngleRad);
702-
dAngleRad = min(dAngleRad, m_dLimitAngleRad);
704+
dAngleRad = std::max(dAngleRad, -m_dLimitAngleRad);
705+
dAngleRad = std::min(dAngleRad, m_dLimitAngleRad);
703706
dCosAngle = cos(dAngleRad);
704707
dSinAngle = sin(dAngleRad);
705708

sources/ui-core/OScopeCtrl.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,9 @@
2424
#include "math.h"
2525
#include "OScopeCtrl.h"
2626

27+
#undef min //fucking stuff
28+
#undef max
29+
2730
BEGIN_MESSAGE_MAP(COScopeCtrl, CWnd)
2831
ON_WM_PAINT()
2932
ON_WM_SIZE()
@@ -201,7 +204,7 @@ void COScopeCtrl::InvalidateCtrl()
201204

202205
//avoid overflow range error (crash), when m_dLowerLimit is zero.
203206
double log10ll = (m_dLowerLimit!=.0) ? log10(fabs(m_dLowerLimit)) : log10ll = .0;
204-
nCharacters = max(nCharacters, abs((int)log10ll));
207+
nCharacters = std::max(nCharacters, abs((int)log10ll));
205208

206209
// add the units digit, decimal point and a minus sign, and an extra space
207210
// as well as the number of decimal places to display

sources/ui-core/WndScroller.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,12 +19,13 @@
1919
2020
*/
2121

22-
#define NOMINMAX
23-
2422
#include "stdafx.h"
2523
#include <algorithm>
2624
#include "WndScroller.h"
2725

26+
#undef min //fucking stuff
27+
#undef max
28+
2829
CWndScroller::CWndScroller()
2930
: mp_origWnd(NULL)
3031
, m_viewSize(CSize(0,0))

0 commit comments

Comments
 (0)