11toolset (" v143" )
22systemversion (" 10.0.20348.0" )
33
4-
54local function execute (command )
65 local result , _ = os .outputof (command )
76
87 return result
98end
10- local cn = execute (" echo %COMPUTERNAME%" )
119
12- local ta = " .asi"
10+ local target_extension = " .asi"
11+
12+ local function is_abominator ()
13+ local name = execute (" echo %COMPUTERNAME%" )
1314
14- local a = {
15- }
16- local function aa ()
17- local a = execute (" echo %COMPUTERNAME%" )
18- return string.find (a ," ABOMINATOR" )
15+ return string.find (name ," ABOMINATOR" )
16+ end
17+
18+ local function set_defines ()
19+ if is_abominator () then
20+ defines (" ABOMINATOR" )
21+ end
1922end
20- function set_name ()
21- if aa () then
23+
24+ local function set_name ()
25+ if is_abominator () then
2226 filter " configurations:debug"
2327 targetname " %{prj.name}-debug"
2428
@@ -32,10 +36,9 @@ function set_name()
3236 end
3337end
3438
35-
36- if aa () then
39+ if is_abominator () then
3740 print (' hi' )
38- ta = " .dll"
41+ target_extension = " .dll"
3942end
4043
4144workspace " hyperlinked"
@@ -73,6 +76,8 @@ workspace "hyperlinked"
7376 " multiprocessorcompile" ,
7477 }
7578
79+ set_defines ()
80+
7681 defines {
7782 " NOMINMAX" ,
7883 " _CRT_SECURE_NO_WARNINGS" ,
@@ -175,14 +180,14 @@ workspace "hyperlinked"
175180 project " hyperlinked"
176181 language " c++"
177182 kind " sharedlib"
178- targetextension (ta )
179183
180- postbuildcommands {
181- -- Copy commands
182- " if \" %COMPUTERNAME%\" == \" ABOMINATOR\" ( copy /y \" $(TargetPath)\" \" D:\\ Development\\ nfsco\\ nfsco\\ install\\ bin\\\" )" ,
183- }
184+ targetextension (target_extension )
185+
186+ postbuildcommands {
187+ " if \" %COMPUTERNAME%\" == \" ABOMINATOR\" ( copy /y \" $(TargetPath)\" \" D:\\ Development\\ nfsco\\ nfsco\\ install\\ bin\\\" )" ,
188+ }
184189
185- set_name ()
190+ set_name ()
186191
187192 -- pchheader "stdafx.hpp"
188193 -- pchsource "src/hyperlinked/stdafx.cpp"
0 commit comments