Skip to content

Commit

Permalink
Use C++17 for msvc admb builds.
Browse files Browse the repository at this point in the history
  • Loading branch information
johnoel committed Jan 30, 2024
1 parent 6b62ea7 commit 6676b92
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions scripts/admb/admb.bat
Original file line number Diff line number Diff line change
Expand Up @@ -180,9 +180,9 @@ if "!CXX!"=="cl" (
)
set LD=!CXX!
if defined CXXFLAGS (
set CXXFLAGS= /c /nologo /EHsc !CXXFLAGS!
set CXXFLAGS= /c /nologo /std:c++17 /EHsc !CXXFLAGS!
) else (
set CXXFLAGS= /c /nologo /EHsc
set CXXFLAGS= /c /nologo /std:c++17 /EHsc
)
if defined g (
set CXXFLAGS=!CXXFLAGS! /Z7
Expand Down Expand Up @@ -216,7 +216,7 @@ if "!CXX!"=="cl" (
)
)
if defined fast (
set CXXFLAGS=!CXXFLAGS! /nologo /DOPT_LIB
set CXXFLAGS=!CXXFLAGS! /nologo /std:c++17 /DOPT_LIB
if defined g (
if exist "!ADMB_HOME!\lib\admb-contribo!OSNAME!!CXXVERSION!-debug.lib" (
set libs="!ADMB_HOME!\lib\admb-contribo!OSNAME!!CXXVERSION!-debug.lib" /link
Expand Down Expand Up @@ -689,9 +689,9 @@ if not defined tpls (
) else (
if "!CXX!"=="cl" (
if defined output (
set CMD=!LD!!LDFLAGS! /nologo /Fe!output! !objs! !libs!
set CMD=!LD!!LDFLAGS! /nologo /std:c++17 /Fe!output! !objs! !libs!
) else (
set CMD=!LD!!LDFLAGS! /nologo /Fe!main!.exe !objs! !libs!
set CMD=!LD!!LDFLAGS! /nologo /std:c++17 /Fe!main!.exe !objs! !libs!
)
) else (
if defined output (
Expand Down Expand Up @@ -754,15 +754,15 @@ if not defined tpls (
if "!CXX!"=="cl" (
if defined objs (
if defined output (
set CMD=!LD!!LDFLAGS! /nologo /Fe!output! !tpl!.obj !objs! !libs!
set CMD=!LD!!LDFLAGS! /nologo /std:c++17 /Fe!output! !tpl!.obj !objs! !libs!
) else (
set CMD=!LD!!LDFLAGS! /nologo /Fe!tpl!.exe !tpl!.obj !objs! !libs!
set CMD=!LD!!LDFLAGS! /nologo /std:c++17 /Fe!tpl!.exe !tpl!.obj !objs! !libs!
)
) else (
if defined output (
set CMD=!LD!!LDFLAGS! /nologo /Fe!output! !tpl!.obj !libs!
set CMD=!LD!!LDFLAGS! /nologo /std:c++17 /Fe!output! !tpl!.obj !libs!
) else (
set CMD=!LD!!LDFLAGS! /nologo /Fe!tpl!.exe !tpl!.obj !libs!
set CMD=!LD!!LDFLAGS! /nologo /std:c++17 /Fe!tpl!.exe !tpl!.obj !libs!
)
)
) else (
Expand Down

0 comments on commit 6676b92

Please sign in to comment.