Created

Embed URL

HTTPS clone URL

SSH clone URL

You can clone with HTTPS or SSH.

Download Gist
View sourceurl.patch
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38
Index: haikuporter
===================================================================
--- haikuporter (revision 1265)
+++ haikuporter (working copy)
@@ -933,7 +933,32 @@
if self.bepKeys['COPYRIGHT']:
for copyright in self.bepKeys['COPYRIGHT']:
opd.write('Copyright:\t' + copyright + '\n')
-
+
+ if ' '.join(self.bepKeys['LICENSE'][0].split()[:2]) in ['GNU GPL',
+ 'GNU LGPL']:
+ #
+ # srcurl = self.bepKeys['SRC_URI'][0]
+ # if '+' in srcurl[:10]:
+ # srcurl = srcurl.split('+', 1)[1]
+ date = time.strftime('-%Y-%m-%d', time.localtime())
+ if os.getenv('HAIKUVERSION'):
+ haiku_name = os.getenv('HAIKUVERSION')
+ else:
+ haiku_name = 'development'
+ srcurl= 'http://haiku-files.org/files/releases/%s/sources/%s-%s_haiku%s.tar.xz' % (haiku_name, self.portName, self.portVersion, date)
+ bepurl_base = 'http://ports.haiku-files.org/' + \
+ 'browser/haikuports/trunk/' + self.portCategory
+
+ bepurl = bepurl_base + '/' + self.portName+ '-'\
+ + self.portVersion + '.bep'
+
+ opd.write('SourceURL:\t' + 'Download <' + srcurl + '>' +'\n')
+ opd.write('SourceURL:\t' + 'Bep-file <' + bepurl + '>' +'\n')
+ patchFilePath = self.patchesDir + '/' + self.portName + '-'\
+ + self.portVersion + '.patch'
+ if os.path.exists(patchFilePath):
+ patchurl = bepurl_base + '/patches'
+ opd.write('SourceURL:\t' + 'Patches <' + patchurl + '>' +'\n')
opd.close()
def makePackage(self):
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.