This repository has been archived by the owner on Dec 19, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
wscript
48 lines (40 loc) · 1.6 KB
/
wscript
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
APPNAME = 'keysafe'
VERSION = '0.5'
top = '.'
out = '_build'
import TaskGen
import os.path
def set_options(opt):
opt.tool_options('compiler_cxx')
opt.tool_options('python')
opt.tool_options('misc')
def configure(conf):
conf.check_tool('compiler_cxx')
conf.check_tool('python')
conf.check_tool('misc')
conf.check_tool('gnome')
conf.check_python_headers()
conf.check_cfg(package='botan-1.8', args='--cflags --libs', uselib_store='botan')
conf.find_program('cython', var='CYTHON', mandatory=True)
conf.env.KEYSAFE_PATH = os.path.join(conf.env.PREFIX, 'lib', 'keysafe')
conf.env.KEYSAFE_PY_PATH = os.path.join(conf.env.PREFIX, 'lib', 'keysafe', 'libkeysafe')
conf.env.KEYSAFE_GLADE_PATH = os.path.join(conf.env.PREFIX, 'lib', 'keysafe', 'gui')
conf.env.KEYSAFE_BIN_PATH = os.path.join(conf.env.PREFIX, 'bin')
conf.env.KEYSAFE_GNOME_DATA_PATH = os.path.join(conf.env.PREFIX, 'share', 'applications')
conf.env.KEYSAFE_GNOME_SCHEMA_PATH = os.path.join(conf.env.PREFIX, 'etc', 'gconf', 'schemas')
def build(bld):
bld.add_subdirs('src gnome libkeysafe tools gui')
for fil in ['keysafe', 'ksed']:
bld(
features='subst',
source=fil+'.in',
target=fil,
chmod=0755,
dict={
'KEYSAFE_PATH' : bld.env.KEYSAFE_PATH,
'KEYSAFE_GLADE_PATH' : bld.env.KEYSAFE_GLADE_PATH,
'KEYSAFE_BIN_PATH' : bld.env.KEYSAFE_BIN_PATH,
},
install_path = '${KEYSAFE_BIN_PATH}',
)
# vim: set ft=python :