[Debian-in-commits] [SCM] dh-make-font.git branch, muneeb, updated. 416489ca60a83dbc766735f2533a535b570c861c
Muneeb Shaikh
iammuneeb at gmail.com
Fri Dec 23 19:25:17 UTC 2011
The following commit has been merged in the muneeb branch:
commit 416489ca60a83dbc766735f2533a535b570c861c
Author: Muneeb Shaikh <iammuneeb at gmail.com>
Date: Sat Dec 24 00:53:32 2011 +0530
better handling of fontforge dependency
Add fontforge to Build-Depends only if *.sfd file exists
else don't add
diff --git a/dh-make-font b/dh-make-font
index 6493943..6c59318 100755
--- a/dh-make-font
+++ b/dh-make-font
@@ -14,6 +14,8 @@ UPLOADERS = (os.environ.get('DEBFULLNAME') + " <" + os.environ.get('DEBEMAIL') +
PACKAGE = ""
font_reg_exp = re.compile("((.)*\.ttf|sfd|otf)") # RE to check
+font_sfd_regx = re.compile("((.)*\.sfd)") # RE to check font source file
+font_source=False
watch = """
version=3
@@ -49,12 +51,14 @@ def check_files():
-1 other wise
"""
-
+ global font_source
# We need to perform a directory traversal to find .ttf .otf or .sfd.
# Any one will do. [We are so kind arn't we]
for dirpath,dirnames,filenames in os.walk('.'):
for filename in filenames:
if font_reg_exp.search(filename):
+ if font_sfd_regx.search(filename):
+ font_source=True
return 0
return -1 # No need to go into sub directories
return -1
@@ -159,7 +163,10 @@ def update_control_file(args):
control_content += "\nUploaders: "+UPLOADERS
elif line.startswith('Build-Depends:'):
- control_content += line +"\n#,fontforge"
+ if font_source:
+ control_content += line +", fontforge"
+ else:
+ control_content += line
elif line.startswith('Architecture:'):
control_content += "Architecture: all"
elif line.startswith('Section:'):
--
dh-make-font.git
More information about the Debian-in-commits
mailing list