summaryrefslogtreecommitdiffstats
blob: a1b3d18f759007f400d2f71dc9115d3987526a17 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
Import("env")

env["SWIFTOOLS_FLAGS"] = {
		"LIBPATH": [Dir(".")],
		"LIBS": ["SwifTools"]
	}

myenv = env.Clone()
myenv.MergeFlags(myenv["BOOST_FLAGS"])

sources = [
		"Idle/IdleDetector.cpp",
		"Idle/ActualIdleDetector.cpp",
		"Idle/IdleQuerier.cpp",
		"Idle/PlatformIdleQuerier.cpp",
		"AutoUpdater/AutoUpdater.cpp",
		"AutoUpdater/PlatformAutoUpdaterFactory.cpp",
		"Linkify.cpp",
	]

if myenv.get("HAVE_SPARKLE", 0) :
	myenv.MergeFlags(myenv["SPARKLE_FLAGS"])
	myenv.Append(CPPDEFINES = ["HAVE_SPARKLE"])
	sources += ["AutoUpdater/SparkleAutoUpdater.mm"]

if myenv["PLATFORM"] == "win32" :
	sources += ["Idle/WindowsIdleQuerier.cpp"]
elif myenv["PLATFORM"] == "darwin" :
	sources += ["Idle/MacOSXIdleQuerier.cpp"]
elif myenv["HAVE_XSS"] :
	myenv.Append(CPPDEFINES = ["HAVE_XSS"])
	sources += ["Idle/XSSIdleQuerier.cpp"]
else :
  sources += ["Idle/DummyIdleQuerier.cpp"]

myenv.StaticLibrary("SwifTools", sources)

SConscript(dirs = [
		"Idle/IdleQuerierTest",
		"Idle/UnitTest",
		"UnitTest"
	])