Skip to content

Commit 120ae28

Browse files
authored
Merge pull request #202 from Apteryks/fix-icons-installation-directory
build: Add an 'iconsdir' option.
2 parents 784ea33 + ffa806a commit 120ae28

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

SConstruct

+6-2
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ opts.Add(BoolVariable('verbose', 'Show verbose compiling output', 1))
2929
cppdefines = []
3030
default_settingsdir = ".vdrift"
3131
default_prefix = "/usr/local"
32+
default_iconsdir = "share/icons/hicolor"
3233
default_datadir = "share/games/vdrift/data"
3334
default_localedir = "share/locale"
3435
default_bindir = "bin"
@@ -161,8 +162,9 @@ if ARGUMENTS.get('verbose') != "1":
161162
#-------------------------------#
162163
opts.Add('settings', 'Directory under user\'s home dir where settings will be stored', default_settingsdir )
163164
opts.Add('prefix', 'Path prefix.', default_prefix)
164-
# in most case datadir doesn't exsist => do not use PathOption (Fails on build)
165-
opts.Add('datadir', 'Path suffix where where VDrift data will be installed', default_datadir)
165+
# in most case datadir doesn't exist => do not use PathOption (Fails on build)
166+
opts.Add('datadir', 'Path suffix where VDrift data will be installed', default_datadir)
167+
opts.Add('iconsdir', 'Path suffix where VDrift icons will be installed', default_iconsdir)
166168
opts.Add('localedir', 'Path where VDrift locale will be installed', default_localedir)
167169
opts.Add('bindir', 'Path suffix where VDrift binary executable will be installed', default_bindir)
168170

@@ -335,6 +337,7 @@ Type: 'scons' to compile with the default options.
335337
'scons destdir=$PWD/tmp' to install to $PWD/tmp staging area.
336338
'scons datadir=' to install data files into an alternate directory.
337339
'scons bindir=games/bin' to install executable into an alternate directory.
340+
'scons iconsdir=share/icons/hicolor' to install the icons into an alternate directory.
338341
'scons localedir=/usr/share/locale' to install language files into an alternate directory.
339342
'scons release=1' to turn on compiler optimizations and disable debugging info.
340343
'scons builddir_release=build' to set release build directory.
@@ -375,6 +378,7 @@ env = conf.Finish()
375378
# directories #
376379
#-------------#
377380
env['data_directory'] = env['destdir'] + env['prefix'] + '/' + env['datadir']
381+
env['icons_directory'] = env['destdir'] + env['prefix'] + '/' + env['iconsdir']
378382
env['locale_directory'] = env['destdir'] + env['prefix'] + '/' + env['localedir']
379383
cppdefines.append(("SETTINGS_DIR", '"%s"' % env['settings']))
380384
if sys.platform in ['win32', 'msys', 'cygwin']:

0 commit comments

Comments
 (0)