[csw-devel] SF.net SVN: gar:[6131] csw/mgar/gar/v2-skayser

skayser at users.sourceforge.net skayser at users.sourceforge.net
Fri Aug 28 21:16:31 CEST 2009


Revision: 6131
          http://gar.svn.sourceforge.net/gar/?rev=6131&view=rev
Author:   skayser
Date:     2009-08-28 19:16:30 +0000 (Fri, 28 Aug 2009)

Log Message:
-----------
gar/v2-skayser: move .pyc/.pyo exclude logic to gar.mk, add TEST_SCRIPTS for python category

Modified Paths:
--------------
    csw/mgar/gar/v2-skayser/categories/python/category.mk
    csw/mgar/gar/v2-skayser/gar.mk

Modified: csw/mgar/gar/v2-skayser/categories/python/category.mk
===================================================================
--- csw/mgar/gar/v2-skayser/categories/python/category.mk	2009-08-28 18:59:55 UTC (rev 6130)
+++ csw/mgar/gar/v2-skayser/categories/python/category.mk	2009-08-28 19:16:30 UTC (rev 6131)
@@ -1,13 +1,12 @@
 # Add a dependency to CSWpython
 _EXTRA_GAR_PKGS += CSWpython
 
-# Put PYCOMPILE in here for now and let gar.pkg.mk handle the usual
-# cswclassutils stuff.
-PYCOMPILE = .*\.py
+# We just set PYCOMPILE, gar.mk then excludes the corresponding .py{c,o} 
+# files. Only thing we explicitly exclude here are the egg-info files. 
+# gar.pkg.mk handles the usual cswclassutils stuff. 
 
-# Could we have "setup.py install" just _not_ compile .py{c,o} files
-# in the first place?
-_MERGE_EXCLUDE_CATEGORY = .*\.pyo .*\.pyc .*\.egg-info.*
+PYCOMPILE = /opt/csw/lib/python/site-packages/.*\.py
+_MERGE_EXCLUDE_CATEGORY += .*\.egg-info.*
 
 # Haven't seen a python module with a configure phase so far
 CONFIGURE_SCRIPTS ?=
@@ -16,5 +15,6 @@
 BUILD_SCRIPTS ?= $(WORKSRC)/setup.py
 INSTALL_SCRIPTS ?= $(WORKSRC)/setup.py
 INSTALL_ARGS ?= --root=$(DESTDIR) --prefix=$(prefix)
+TEST_SCRIPTS ?= $(WORKSRC)/setup.py
 
 include gar/gar.mk

Modified: csw/mgar/gar/v2-skayser/gar.mk
===================================================================
--- csw/mgar/gar/v2-skayser/gar.mk	2009-08-28 18:59:55 UTC (rev 6130)
+++ csw/mgar/gar/v2-skayser/gar.mk	2009-08-28 19:16:30 UTC (rev 6131)
@@ -559,11 +559,18 @@
 # This can be defined in category.mk
 MERGE_EXCLUDE_CATEGORY ?= $(_MERGE_EXCLUDE_CATEGORY)
 
+# Support for cswpycompile, skip pre-compiled python files (.pyc, .pyo)
+# during the merge phase.
+ifneq ($(PYCOMPILE),)
+MERGE_EXCLUDE_PYCOMPILE += $(addsuffix c,$(PYCOMPILE))
+MERGE_EXCLUDE_PYCOMPILE += $(addsuffix o,$(PYCOMPILE))
+endif
+
 MERGE_EXCLUDE_INFODIR ?= $(sharedstatedir)/info/dir
 MERGE_EXCLUDE_LIBTOOL ?= $(libdir)/.*\.la
 MERGE_EXCLUDE_BACKUPFILES ?= .*\~
 MERGE_EXCLUDE_STATICLIBS ?= $(libdir)/.*\.a
-MERGE_EXCLUDE_DEFAULT ?= $(MERGE_EXCLUDE_CATEGORY) $(MERGE_EXCLUDE_INFODIR) $(MERGE_EXCLUDE_LIBTOOL) $(MERGE_EXCLUDE_BACKUPFILES) $(MERGE_EXCLUDE_STATICLIBS)
+MERGE_EXCLUDE_DEFAULT ?= $(MERGE_EXCLUDE_CATEGORY) $(MERGE_EXCLUDE_INFODIR) $(MERGE_EXCLUDE_LIBTOOL) $(MERGE_EXCLUDE_BACKUPFILES) $(MERGE_EXCLUDE_STATICLIBS) $(MERGE_EXCLUDE_PYCOMPILE)
 
 # Exclude these files
 ifeq ($(origin MERGE_EXCLUDE_FILES_$(MODULATION)), undefined)


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.



More information about the devel mailing list