summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThiago Santos <thiago.sousa.santos@collabora.com>2013-05-08 05:38:36 -0700
committerThiago Santos <thiago.sousa.santos@collabora.com>2013-05-08 10:53:22 -0300
commit8a3cf3677b26814d78c91adc6168a8ed114f65d7 (patch)
tree53749400865a71d0a0bebebbbd04c78486e6101c
parent6c18cdcdc50e94169ae7a7f847899b5256d745b9 (diff)
config: only add (x86) to program files path if arch isn't x86
For x86, windows doesn't put the (x86) suffix to the program files folder, only for other archs (x86_64)
-rw-r--r--cerbero/config.py13
1 files changed, 10 insertions, 3 deletions
diff --git a/cerbero/config.py b/cerbero/config.py
index eb5f6c2..3876eb9 100644
--- a/cerbero/config.py
+++ b/cerbero/config.py
@@ -33,13 +33,20 @@ DEFAULT_HOME = os.path.expanduser('~/cerbero')
DEFAULT_CONFIG_FILENAME = 'cerbero.%s' % CONFIG_EXT
DEFAULT_CONFIG_FILE = os.path.join(CONFIG_DIR, DEFAULT_CONFIG_FILENAME)
DEFAULT_GIT_ROOT = 'git://anongit.freedesktop.org/gstreamer-sdk'
-DEFAULT_WIX_PREFIX = \
- 'C:/Program\ Files\ \(x86\)/Windows\ Installer\ XML\ v3.5/bin'
DEFAULT_ALLOW_PARALLEL_BUILD = False
DEFAULT_PACKAGER = "Default <default@change.me>"
CERBERO_UNINSTALLED = 'CERBERO_UNINSTALLED'
CERBERO_PREFIX = 'CERBERO_PREFIX'
+DEFAULT_WIX_PREFIX = \
+ 'C:/Program\ Files%s/Windows\ Installer\ XML\ v3.5/bin'
+def get_wix_prefix(arch):
+ if arch == Architecture.X86:
+ path = ''
+ else:
+ path = ' x(86)'
+ return DEFAULT_WIX_PREFIX % path
+
Platform = enums.Platform
Architecture = enums.Architecture
@@ -257,7 +264,6 @@ class Config (object):
self.set_property('local_sources', None)
self.set_property('git_root', DEFAULT_GIT_ROOT)
self.set_property('allow_parallel_build', DEFAULT_ALLOW_PARALLEL_BUILD)
- self.set_property('wix_prefix', DEFAULT_WIX_PREFIX)
self.set_property('host', None)
self.set_property('build', None)
self.set_property('target', None)
@@ -271,6 +277,7 @@ class Config (object):
self.set_property('target_distro', distro)
self.set_property('distro_version', distro_version)
self.set_property('target_distro_version', distro_version)
+ self.set_property('wix_prefix', get_wix_prefix(self.arch))
self.set_property('packages_prefix', None)
self.set_property('packager', DEFAULT_PACKAGER)
self.set_property('py_prefix', 'lib/python%s.%s' %