Fix mageia dependency.
authorCarl Hetherington <cth@carlh.net>
Fri, 16 Mar 2018 17:55:26 +0000 (17:55 +0000)
committerCarl Hetherington <cth@carlh.net>
Fri, 16 Mar 2018 17:55:26 +0000 (17:55 +0000)
cscript

diff --git a/cscript b/cscript
index 8120e8284b3767d6c2300c3747025145ea181dde..9d89f4962b2f2cb19c58e6096cbfa67baafde33f 100644 (file)
--- a/cscript
+++ b/cscript
@@ -220,7 +220,7 @@ def make_control(debian_version, bits, filename, debug):
         print('  This package contains the debugging symbols for dcpomatic.', file=f)
         print('', file=f)
 
-def make_spec(filename, version, target):
+def make_spec(filename, version, target, requires=None):
     """Make a .spec file for a RPM build"""
     f = open(filename, 'w')
     print('Summary:A program that generates Digital Cinema Packages (DCPs) from video and audio files', file=f)
@@ -230,6 +230,8 @@ def make_spec(filename, version, target):
     print('License:GPL', file=f)
     print('Group:Applications/Multimedia', file=f)
     print('URL:http://dcpomatic.com/', file=f)
+    if requires is not None:
+        print('Requires:%s' % requires, file=f)
     print('', file=f)
     print('%description', file=f)
     print('DCP-o-matic generates Digital Cinema Packages (DCPs) from video and audio ', file=f)
@@ -401,7 +403,11 @@ def package_rpm(target, cpu, version):
         "%s/SOURCES/dcpomatic-%s.tar.bz2" % (topdir, version)
         )
 
-    make_spec('build/platform/linux/dcpomatic2.spec', version, target)
+    requires = None
+    if target.distro == 'mageia':
+        requires = "lib64xmlsec1-devel"
+    
+    make_spec('build/platform/linux/dcpomatic2.spec', version, target, requires)
     cmd = 'rpmbuild --define "_topdir %s" -bb build/platform/linux/dcpomatic2.spec' % topdir
     target.command(cmd)
     rpms = []