[PATCHES] fix build with gpfs support
Bjoern Baumbach
bb at sernet.de
Mon Jul 27 15:36:36 UTC 2015
Hi!
The build with GPFS support is broken in 4.3.0.
Particularly if the GPFS headers are not stored at "/usr/lpp/mmfs/include/".
I've attached a patch that allows to select the directory with
a --with-gpfs=PATH option (patch 2).
Furthermore the GPFS headers are also needed to build the debug.c (patch 3).
Best regards
Björn
--
SerNet GmbH, Bahnhofsallee 1b, 37081 Göttingen
phone: +49-551-370000-0, fax: +49-551-370000-9
AG Göttingen, HRB 2816, GF: Dr. Johannes Loxen
http://www.sernet.de, mailto:kontakt at sernet.de
-------------- next part --------------
From b2ef6ed9a7d25e95a7ccee9c3ca317fe8e110275 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Bj=C3=B6rn=20Baumbach?= <bb at sernet.de>
Date: Mon, 27 Jul 2015 13:20:43 +0200
Subject: [PATCH 1/3] s3:wscript: fix indentation
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Signed-off-by: Björn Baumbach <bb at sernet.de>
---
source3/wscript | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/source3/wscript b/source3/wscript
index a9a7c14..4e940fa 100644
--- a/source3/wscript
+++ b/source3/wscript
@@ -1634,7 +1634,7 @@ main() {
default_static_modules.extend(TO_LIST('charset_macosxfs'))
if conf.CONFIG_SET('HAVE_GPFS'):
- default_shared_modules.extend(TO_LIST('vfs_gpfs'))
+ default_shared_modules.extend(TO_LIST('vfs_gpfs'))
if (conf.CONFIG_SET('HAVE_LINUX_IOCTL')
and conf.CONFIG_SET('HAVE_BASENAME') and conf.CONFIG_SET('HAVE_DIRNAME')):
--
2.3.6
From 2f6c26848960a35059c6d1af62137666542534b6 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Bj=C3=B6rn=20Baumbach?= <bb at sernet.de>
Date: Mon, 27 Jul 2015 12:14:37 +0200
Subject: [PATCH 2/3] configure: add --with-gpfs option for selecting directory
with gpfs headers
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Signed-off-by: Björn Baumbach <bb at sernet.de>
---
lib/util/wscript_configure | 2 +-
source3/wscript | 4 ++++
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/lib/util/wscript_configure b/lib/util/wscript_configure
index 95a8949..e7bcbd6 100644
--- a/lib/util/wscript_configure
+++ b/lib/util/wscript_configure
@@ -135,6 +135,6 @@ else:
conf.SET_TARGET_TYPE('lttng-ust', 'EMPTY')
conf.undefine('HAVE_LTTNG_TRACEF')
-conf.env['CPPPATH_GPFS'] = '/usr/lpp/mmfs/include/'
+conf.env['CPPPATH_GPFS'] = Options.options.gpfs_headers_dir
if conf.CHECK_HEADERS('gpfs.h', False, False, "gpfs"):
conf.DEFINE('HAVE_GPFS', '1')
diff --git a/source3/wscript b/source3/wscript
index 4e940fa..5115296 100644
--- a/source3/wscript
+++ b/source3/wscript
@@ -56,6 +56,10 @@ def set_options(opt):
help=("Directory under which libcephfs is installed"),
action="store", dest='libcephfs_dir', default=None)
+ opt.add_option('--with-gpfs',
+ help=("Directory under which gpfs headers are installed"),
+ action="store", dest='gpfs_headers_dir', default="/usr/lpp/mmfs/include/")
+
opt.SAMBA3_ADD_OPTION('glusterfs', with_name="enable", without_name="disable", default=True)
opt.add_option('--enable-vxfs',
--
2.3.6
From 86d59504c2e863aa6debe14f3dbe7bf644a34a2f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Bj=C3=B6rn=20Baumbach?= <bb at sernet.de>
Date: Mon, 27 Jul 2015 15:15:07 +0200
Subject: [PATCH 3/3] build: fix build with gpfs support - add missing
dependency to samba-debug
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Pair-programmed-with: Stefan Metzmacher <metze at samba.org>
Signed-off-by: Björn Baumbach <bb at sernet.de>
---
lib/util/wscript_build | 3 +++
1 file changed, 3 insertions(+)
diff --git a/lib/util/wscript_build b/lib/util/wscript_build
index 1014c75..9663bb0 100755
--- a/lib/util/wscript_build
+++ b/lib/util/wscript_build
@@ -30,6 +30,7 @@ bld.SAMBA_SUBSYSTEM('close-low-fd',
local_include=False)
samba_debug_add_deps = ''
+samba_debug_add_inc = ''
if bld.CONFIG_SET('HAVE_GPFS'):
bld.SAMBA_SUBSYSTEM('gpfswrap',
@@ -38,12 +39,14 @@ if bld.CONFIG_SET('HAVE_GPFS'):
local_include=False,
includes=bld.CONFIG_GET('CPPPATH_GPFS'))
samba_debug_add_deps += ' gpfswrap'
+ samba_debug_add_inc += bld.CONFIG_GET('CPPPATH_GPFS')
bld.SAMBA_LIBRARY('samba-debug',
source='debug.c',
deps='replace time-basic close-low-fd talloc socket-blocking' + samba_debug_add_deps,
public_deps='systemd systemd-journal lttng-ust',
local_include=False,
+ includes=samba_debug_add_inc,
private_library=True)
bld.SAMBA_LIBRARY('socket-blocking',
--
2.3.6
More information about the samba-technical
mailing list