summaryrefslogtreecommitdiffstats
blob: c34abe82cf0d15082999b94eb3dacb94d8077906 (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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
Import("env")

if env.get("UNBOUND_BUNDLED", False) :

	if env["PLATFORM"] == "win32" :
		cppflags = ["/I" + Dir("#/3rdParty/Unbound/src/src").abspath]
	else :
		cppflags = [("-isystem", Dir("#/3rdParty/Unbound/src/src").abspath)]


################################################################################
# Flags
################################################################################
    
	if env["SCONS_STAGE"] == "flags" :
		env["UNBOUND_FLAGS"] = {
				"CPPPATH":  [Dir("src/src/libunbound")],
				"CPPFLAGS": cppflags,
				"LIBPATH": [env.Dir(".")],
				"LIBS": ["Swiften_Unbound"],
			}

################################################################################
# Build
################################################################################

	if env["SCONS_STAGE"] == "build" :
		myenv = env.Clone()
		myenv.Append(CPPDEFINES = [("UNBOUND_STATICLIB")])
		myenv.Append(CPPPATH = ["../Ldns/src/include", "src/src", "."])

		myenv.Install("include", [
            
			])
		myenv.StaticLibrary("Swiften_Unbound", [
            "src/src/daemon/acl_list.c",
            "src/src/daemon/cachedump.c",
            "src/src/daemon/daemon.c",
            "src/src/daemon/remote.c",
            "src/src/daemon/stats.c",
            "src/src/daemon/unbound.c",
            # duplicate symbols: "src/src/daemon/worker.c",
            "src/src/iterator/iter_delegpt.c",
            "src/src/iterator/iter_donotq.c",
            "src/src/iterator/iter_fwd.c",
            "src/src/iterator/iter_hints.c",
            "src/src/iterator/iter_priv.c",
            "src/src/iterator/iter_resptype.c",
            "src/src/iterator/iter_scrub.c",
            "src/src/iterator/iter_utils.c",
            "src/src/iterator/iterator.c",
            "src/src/libunbound/context.c",
            "src/src/libunbound/libunbound.c",
            "src/src/libunbound/libworker.c",
            "src/src/services/cache/dns.c",
            "src/src/services/cache/infra.c",
            "src/src/services/cache/rrset.c",
            "src/src/services/listen_dnsport.c",
            "src/src/services/localzone.c",
            "src/src/services/mesh.c",
            "src/src/services/modstack.c",
            "src/src/services/outbound_list.c",
            "src/src/services/outside_network.c",
            "src/src/util/alloc.c",
            "src/src/util/config_file.c",
            "src/src/util/configlexer.c",
            "src/src/util/configparser.c",
            "src/src/util/data/dname.c",
            "src/src/util/data/msgencode.c",
            "src/src/util/data/msgparse.c",
            "src/src/util/data/msgreply.c",
            "src/src/util/data/packed_rrset.c",
            "src/src/util/fptr_wlist.c",
            "src/src/util/locks.c",
            "src/src/util/log.c",
            "src/src/util/mini_event.c",
            "src/src/util/module.c",
            "src/src/util/net_help.c",
            "src/src/util/netevent.c",
            "src/src/util/random.c",
            "src/src/util/rbtree.c",
            "src/src/util/regional.c",
            "src/src/util/rtt.c",
            "src/src/util/storage/dnstree.c",
            "src/src/util/storage/lookup3.c",
            "src/src/util/storage/lruhash.c",
            "src/src/util/storage/slabhash.c",
            "src/src/util/timehist.c",
            "src/src/util/tube.c",
            #src/src/util/winsock_event.c
            "src/src/validator/autotrust.c",
            "src/src/validator/val_anchor.c",
            "src/src/validator/val_kcache.c",
            "src/src/validator/val_kentry.c",
            "src/src/validator/val_neg.c",
            "src/src/validator/val_nsec.c",
            "src/src/validator/val_nsec3.c",
            "src/src/validator/val_sigcrypt.c",
            "src/src/validator/val_utils.c",
            "src/src/validator/validator.c",
            
			])