summaryrefslogtreecommitdiffstats
path: root/buildtools
diff options
context:
space:
mode:
authorThomas Nagy <tnagy2pow10@gmail.com>2013-09-17 00:00:40 +0200
committerJeremy Allison <jra@samba.org>2015-01-09 02:02:07 +0100
commit115eb94215f4d9c73d05606de2ad978f6b48d07f (patch)
tree0b7e94cfe8a68c45e348ddb1d4db7b213607566b /buildtools
parent9f2979a1a42f4714bdc49d09e4b5094333409834 (diff)
downloadsamba-115eb94215f4d9c73d05606de2ad978f6b48d07f.tar.gz
samba-115eb94215f4d9c73d05606de2ad978f6b48d07f.tar.xz
samba-115eb94215f4d9c73d05606de2ad978f6b48d07f.zip
wafadmin: backported the openbsd fixes from waf 1.7
This is a backport from waf 1.5... Reviewed-by: Michael Adam <obnox@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Fri Jan 9 02:02:07 CET 2015 on sn-devel-104
Diffstat (limited to 'buildtools')
-rw-r--r--buildtools/wafadmin/Tools/ccroot.py18
-rw-r--r--buildtools/wafadmin/Tools/gcc.py4
-rw-r--r--buildtools/wafadmin/Tools/gxx.py4
3 files changed, 20 insertions, 6 deletions
diff --git a/buildtools/wafadmin/Tools/ccroot.py b/buildtools/wafadmin/Tools/ccroot.py
index 264bdc7f0f..d59cf26633 100644
--- a/buildtools/wafadmin/Tools/ccroot.py
+++ b/buildtools/wafadmin/Tools/ccroot.py
@@ -177,10 +177,14 @@ def get_target_name(self):
dir, name = os.path.split(self.target)
- if self.env.DEST_BINFMT == 'pe' and getattr(self, 'vnum', None) and 'cshlib' in self.features:
- # include the version in the dll file name,
- # the import lib file name stays unversionned.
- name = name + '-' + self.vnum.split('.')[0]
+ if 'cshlib' in self.features and getattr(self, 'vnum', None):
+ nums = self.vnum.split('.')
+ if self.env.DEST_BINFMT == 'pe':
+ # include the version in the dll file name,
+ # the import lib file name stays unversionned.
+ name = name + '-' + nums[0]
+ elif self.env.DEST_OS == 'openbsd':
+ pattern = '%s.%s.%s' % (pattern, nums[0], nums[1])
return os.path.join(dir, pattern % name)
@@ -598,14 +602,16 @@ def apply_vnum(self):
if not path: return
if self.env.DEST_OS == 'openbsd':
- bld.install_as(path + os.sep + name2, node, env=self.env, chmod=self.link_task.chmod)
+ libname = self.link_task.outputs[0].name
+ bld.install_as('%s%s%s' % (path, os.sep, libname), node, env=self.env)
else:
bld.install_as(path + os.sep + name3, node, env=self.env)
bld.symlink_as(path + os.sep + name2, name3)
bld.symlink_as(path + os.sep + libname, name3)
# the following task is just to enable execution from the build dir :-/
- self.create_task('vnum', node, [node.parent.find_or_declare(name2), node.parent.find_or_declare(name3)])
+ if self.env.DEST_OS != 'openbsd':
+ self.create_task('vnum', node, [node.parent.find_or_declare(name2), node.parent.find_or_declare(name3)])
def exec_vnum_link(self):
for x in self.outputs:
diff --git a/buildtools/wafadmin/Tools/gcc.py b/buildtools/wafadmin/Tools/gcc.py
index 420b44fd8f..a6be0b28db 100644
--- a/buildtools/wafadmin/Tools/gcc.py
+++ b/buildtools/wafadmin/Tools/gcc.py
@@ -114,6 +114,10 @@ def gcc_modifier_aix(conf):
v['SHLIB_MARKER'] = ''
@conftest
+def gcc_modifier_openbsd(conf):
+ conf.env['SONAME_ST'] = []
+
+@conftest
def gcc_modifier_platform(conf):
# * set configurations specific for a platform.
# * the destination platform is detected automatically by looking at the macros the compiler predefines,
diff --git a/buildtools/wafadmin/Tools/gxx.py b/buildtools/wafadmin/Tools/gxx.py
index 8f4a0bfef0..4984122e5e 100644
--- a/buildtools/wafadmin/Tools/gxx.py
+++ b/buildtools/wafadmin/Tools/gxx.py
@@ -112,6 +112,10 @@ def gxx_modifier_aix(conf):
v['SHLIB_MARKER'] = ''
@conftest
+def gxx_modifier_openbsd(conf):
+ conf.env['SONAME_ST'] = []
+
+@conftest
def gxx_modifier_platform(conf):
# * set configurations specific for a platform.
# * the destination platform is detected automatically by looking at the macros the compiler predefines,