summaryrefslogtreecommitdiff
path: root/net-p2p/linuxdcpp/files/patch-SConstruct
diff options
context:
space:
mode:
authorTijl Coosemans <tijl@FreeBSD.org>2013-10-24 17:31:54 +0000
committerTijl Coosemans <tijl@FreeBSD.org>2013-10-24 17:31:54 +0000
commit9608e3ad93758af28850ce24e4104bc386146fb6 (patch)
treeb60d4d8a381ecf46b9f52468becf9c927567e8f7 /net-p2p/linuxdcpp/files/patch-SConstruct
parent- Remove no longer needed patch (diff)
- Fix build on FreeBSD 10 (iconv, libc++).
- USES=scons. - Add support for startup notifications. PR: ports/183163 Submitted by: Vladimir Kondratiev <wulf@mail.mipt.ru>
Diffstat (limited to 'net-p2p/linuxdcpp/files/patch-SConstruct')
-rw-r--r--net-p2p/linuxdcpp/files/patch-SConstruct33
1 files changed, 32 insertions, 1 deletions
diff --git a/net-p2p/linuxdcpp/files/patch-SConstruct b/net-p2p/linuxdcpp/files/patch-SConstruct
index 180836446633..360a88eeced2 100644
--- a/net-p2p/linuxdcpp/files/patch-SConstruct
+++ b/net-p2p/linuxdcpp/files/patch-SConstruct
@@ -9,7 +9,15 @@
}
# ----------------------------------------------------------------------
-@@ -139,6 +139,12 @@
+@@ -106,6 +106,7 @@
+ vars.AddVariables(
+ BoolVariable('debug', 'Compile the program with debug information', 0),
+ BoolVariable('release', 'Compile the program with optimizations', 0),
++ BoolVariable('libnotify', 'Enable notifications through libnotify', 1),
+ BoolVariable('profile', 'Compile the program with profiling information', 0),
+ PathVariable('PREFIX', 'Compile the program with PREFIX as the root for installation', '/usr/local', PathVariable.PathIsDir),
+ ('FAKE_ROOT', 'Make scons install the program under a fake root', '')
+@@ -139,6 +140,12 @@
if os.environ.has_key('CFLAGS'):
env['CFLAGS'] = os.environ['CFLAGS'].split()
@@ -22,3 +30,26 @@
env['CPPDEFINES'] = [] # Initialize as a list so Append doesn't concat strings
env.SConsignFile('build/sconf/.sconsign')
+@@ -263,14 +270,15 @@
+ conf.env.Append(CPPDEFINES = 'HAVE_IFADDRS_H')
+
+ # TODO: Implement a plugin system so libnotify doesn't have compile-time dependencies
+- if not conf.CheckPKG('libnotify >= 0.4.1'):
+- print '\tlibnotify >= 0.4.1 not found, disabling notifications.'
+- print '\tNote: You might have the lib but not the headers'
+- else:
+- conf.env.Append(CPPDEFINES = 'HAVE_LIBNOTIFY')
+- conf.env.ParseConfig('pkg-config --libs libnotify')
+- if conf.CheckPKG('libnotify >= 0.7'):
+- conf.env.Append(CPPDEFINES = 'HAVE_LIBNOTIFY_0_7')
++ if conf.env.get('libnotify'):
++ if not conf.CheckPKG('libnotify >= 0.4.1'):
++ print '\tlibnotify >= 0.4.1 not found, disabling notifications.'
++ print '\tNote: You might have the lib but not the headers'
++ else:
++ conf.env.Append(CPPDEFINES = 'HAVE_LIBNOTIFY')
++ conf.env.ParseConfig('pkg-config --libs libnotify')
++ if conf.CheckPKG('libnotify >= 0.7'):
++ conf.env.Append(CPPDEFINES = 'HAVE_LIBNOTIFY_0_7')
+
+ conf.CheckBZRRevision()