
git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@6413 212acab6-be3b-0410-9dea-997c60f758d6
64 lines
1 KiB
Python
64 lines
1 KiB
Python
target = 'System'
|
|
|
|
files = Split("""
|
|
Source/Buffers.c
|
|
Source/Plugin.c
|
|
Source/System.c
|
|
""")
|
|
|
|
libs = Split("""
|
|
kernel32
|
|
user32
|
|
ole32
|
|
""")
|
|
|
|
examples = Split("""
|
|
Resource.dll
|
|
System.nsi
|
|
System.nsh
|
|
SysFunc.nsh
|
|
""")
|
|
|
|
docs = Split("""
|
|
System.html
|
|
WhatsNew.txt
|
|
""")
|
|
|
|
Import('BuildPlugin env')
|
|
|
|
if env['TARGET_ARCH'] != 'amd64':
|
|
conf = env.Configure()
|
|
if conf.TryCompile('END', '.S'):
|
|
files += ['Source/Call.S']
|
|
elif conf.TryCompile('.end', '.sx'):
|
|
files += ['Source/Call.sx']
|
|
else:
|
|
print 'WARNING: unable to find assembler for Call.S'
|
|
conf.Finish()
|
|
else:
|
|
print 'WARNING: missing Win64 code, dynamic function calls not supported'
|
|
|
|
BuildPlugin(
|
|
target,
|
|
files,
|
|
libs,
|
|
examples,
|
|
docs,
|
|
nodeflib = False,
|
|
defines = ['SYSTEM_EXPORTS']
|
|
)
|
|
|
|
res = 'Resource/Resource.rc'
|
|
res_obj = 'Resource/Resource-rc.o'
|
|
res_target = env.RES(res_obj, res)
|
|
|
|
res_main = env.Object('Resource/Main.c')
|
|
|
|
resources = Split("""
|
|
Resource/Icon.ico
|
|
Resource/Resource.h
|
|
""")
|
|
|
|
env.Depends(res_target, resources)
|
|
|
|
env.SharedLibrary('Resource', res_target + res_main)
|