[Git][NTPsec/ntpsec][master] 2 commits: Improve Python installation. It's still doing too much work.

Eric S. Raymond gitlab at mg.gitlab.com
Sun Nov 6 03:30:49 UTC 2016


Eric S. Raymond pushed to branch master at NTPsec / ntpsec


Commits:
3d5c8bb2 by Eric S. Raymond at 2016-11-05T22:29:06-04:00
Improve Python installation.  It's still doing too much work.

- - - - -
e48d1be5 by Eric S. Raymond at 2016-11-05T23:05:28-04:00
Make autorevision use a cache file.

- - - - -


1 changed file:

- pylib/wscript


Changes:

=====================================
pylib/wscript
=====================================
--- a/pylib/wscript
+++ b/pylib/wscript
@@ -8,6 +8,7 @@ def configure(conf):
 
 def build(ctx):
     srcnode = ctx.srcnode.make_node('pylib')
+    #bldnode = ctx.bldnode.make_node('pylib')
     target1 = ctx.srcnode.make_node('pylib/ntp_control.py')
     target2 = ctx.srcnode.make_node('pylib/ntp_magic.py')
     target3 = ctx.srcnode.make_node('pylib/version.py')
@@ -18,6 +19,7 @@ def build(ctx):
 	rule        = '../wafhelpers/pythonize-header ${SRC} >${TGT}',
 	source      = "../include/ntp_control.h",
 	target      = target1,
+	install_path ='${PYTHONDIR}/ntp'
 	)
 
     ctx(
@@ -26,14 +28,22 @@ def build(ctx):
 	rule        = '../wafhelpers/pythonize-header ${SRC} >${TGT}',
 	source      = "../include/ntp.h",
 	target      = target2,
+	install_path ='${PYTHONDIR}/ntp'
 	)
 
     ctx(
 	before      = ['pyc', 'pyo'],
 	cwd         = srcnode,
-	rule        = 'VERSION=`cat ../VERSION` ../wafhelpers/autorevision.sh -t python >${TGT}',
+	rule        = 'VERSION=`cat ../VERSION` ../wafhelpers/autorevision.sh -o ../wafhelpers/.autorevision-cache -t python >${TGT}',
 	source      = "../VERSION",
-	target      = target3,
+	target      = [target3, '../wafhelpers/.autorevision-cache'],
+	install_path ='${PYTHONDIR}/ntp'
 	)
 
-    ctx(features='py', source=ctx.path.ant_glob('*.py'), install_from='.', install_path='${PYTHONDIR}/ntp')
+    ctx(
+	after       = ['pyc', 'pyo'],
+	features     ='py',
+	source       = ctx.path.ant_glob('*.py'),
+	install_from = '.',
+	install_path ='${PYTHONDIR}/ntp'
+	)



View it on GitLab: https://gitlab.com/NTPsec/ntpsec/compare/530f8e2a45da941ad1a8652ca99af6da0f4786c0...e48d1be5c0af793720cf098f0b95824a7a35ebd8
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ntpsec.org/pipermail/vc/attachments/20161106/665b0567/attachment.html>


More information about the vc mailing list