summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Stahl <mstahl@redhat.com>2017-06-02 15:26:05 +0200
committerMichael Stahl <mstahl@redhat.com>2017-06-02 16:34:53 +0200
commit203c12c7ce5f54971755fb6fb2f04ec36e7797c4 (patch)
treed60a81509f96c89c710a4272b950f6802984f2ea
parentbda955398d38f8f7d2de5e03cc5ad4908b85c0d9 (diff)
gbuild: AutoInstall: allow per-module Package template
Change-Id: I83404709ae7bd3f4683ea9dab8d3f0e0875bc10f
-rw-r--r--scp2/AutoInstall.mk52
-rw-r--r--solenv/gbuild/AutoInstall.mk6
-rw-r--r--solenv/gbuild/gen-autoinstall.py25
3 files changed, 49 insertions, 34 deletions
diff --git a/scp2/AutoInstall.mk b/scp2/AutoInstall.mk
index 2065de0b7367..a4bd01cdafd0 100644
--- a/scp2/AutoInstall.mk
+++ b/scp2/AutoInstall.mk
@@ -13,39 +13,39 @@ $(eval $(call gb_AutoInstall_add_module,activexbinarytable,LIBO_LIB_FILE_BINARYT
$(eval $(call gb_AutoInstall_add_module,activex,LIBO_LIB_FILE))
$(eval $(call gb_AutoInstall_add_module,activexwin64,LIBO_LIB_FILE_COMPONENTCONDITION,,,"VersionNT64"))
$(eval $(call gb_AutoInstall_add_module,base,LIBO_LIB_FILE,LIBO_EXECUTABLE))
-$(eval $(call gb_AutoInstall_add_module,base_brand,,LIBO_EXECUTABLE))
-$(eval $(call gb_AutoInstall_add_module,brand,,LIBO_EXECUTABLE))
-$(eval $(call gb_AutoInstall_add_module,calc,LIBO_LIB_FILE))
-$(eval $(call gb_AutoInstall_add_module,calc_brand,,LIBO_EXECUTABLE))
-$(eval $(call gb_AutoInstall_add_module,draw_brand,,LIBO_EXECUTABLE))
-$(eval $(call gb_AutoInstall_add_module,extensions_ct2n,,,,))
+$(eval $(call gb_AutoInstall_add_module,base_brand,,LIBO_EXECUTABLE,,PACKAGE_FILELIST))
+$(eval $(call gb_AutoInstall_add_module,brand,,LIBO_EXECUTABLE,,PACKAGE_FILELIST))
+$(eval $(call gb_AutoInstall_add_module,calc,LIBO_LIB_FILE,,,PACKAGE_FILELIST))
+$(eval $(call gb_AutoInstall_add_module,calc_brand,,LIBO_EXECUTABLE,,PACKAGE_FILELIST))
+$(eval $(call gb_AutoInstall_add_module,draw_brand,,LIBO_EXECUTABLE,,PACKAGE_FILELIST))
+$(eval $(call gb_AutoInstall_add_module,extensions_ct2n,,,,PACKAGE_FILELIST))
$(eval $(call gb_AutoInstall_add_module,extensions_bsh,,,LIBO_JAR_FILE))
-$(eval $(call gb_AutoInstall_add_module,extensions_numbertext,,,,))
+$(eval $(call gb_AutoInstall_add_module,extensions_numbertext,,,,PACKAGE_FILELIST))
$(eval $(call gb_AutoInstall_add_module,extensions_rhino,,,LIBO_JAR_FILE))
-$(eval $(call gb_AutoInstall_add_module,firebirdsdbc,LIBO_LIB_FILE))
+$(eval $(call gb_AutoInstall_add_module,firebirdsdbc,LIBO_LIB_FILE,,,PACKAGE_FILELIST))
$(eval $(call gb_AutoInstall_add_module,gnome,LIBO_LIB_FILE,LIBO_EXECUTABLE))
$(eval $(call gb_AutoInstall_add_module,graphicfilter,LIBO_LIB_FILE))
-$(eval $(call gb_AutoInstall_add_module,impress,LIBO_LIB_FILE))
-$(eval $(call gb_AutoInstall_add_module,impress_brand,,LIBO_EXECUTABLE))
+$(eval $(call gb_AutoInstall_add_module,impress,LIBO_LIB_FILE,,,PACKAGE_FILELIST))
+$(eval $(call gb_AutoInstall_add_module,impress_brand,,LIBO_EXECUTABLE,,PACKAGE_FILELIST))
$(eval $(call gb_AutoInstall_add_module,kde,LIBO_LIB_FILE,LIBO_EXECUTABLE))
-$(eval $(call gb_AutoInstall_add_module,libreofficekit,LIBO_LIB_FILE,LIBO_EXECUTABLE))
+$(eval $(call gb_AutoInstall_add_module,libreofficekit,LIBO_LIB_FILE,LIBO_EXECUTABLE,,PACKAGE_FILELIST))
$(eval $(call gb_AutoInstall_add_module,math,LIBO_LIB_FILE))
-$(eval $(call gb_AutoInstall_add_module,math_brand,,LIBO_EXECUTABLE))
-$(eval $(call gb_AutoInstall_add_module,ogltrans,LIBO_LIB_FILE))
-$(eval $(call gb_AutoInstall_add_module,onlineupdate,LIBO_LIB_FILE_COMPONENTCONDITION,LIBO_EXECUTABLE_COMPONENTCONDITION,,"ISCHECKFORPRODUCTUPDATES=1"))
-$(eval $(call gb_AutoInstall_add_module,ooo,LIBO_LIB_FILE,LIBO_EXECUTABLE,LIBO_JAR_FILE))
-$(eval $(call gb_AutoInstall_add_module,ooo_images,,,,))
+$(eval $(call gb_AutoInstall_add_module,math_brand,,LIBO_EXECUTABLE,,PACKAGE_FILELIST))
+$(eval $(call gb_AutoInstall_add_module,ogltrans,LIBO_LIB_FILE,,,PACKAGE_FILELIST))
+$(eval $(call gb_AutoInstall_add_module,onlineupdate,LIBO_LIB_FILE_COMPONENTCONDITION,LIBO_EXECUTABLE_COMPONENTCONDITION,,PACKAGE_FILELIST,"ISCHECKFORPRODUCTUPDATES=1"))
+$(eval $(call gb_AutoInstall_add_module,ooo,LIBO_LIB_FILE,LIBO_EXECUTABLE,LIBO_JAR_FILE,PACKAGE_FILELIST))
+$(eval $(call gb_AutoInstall_add_module,ooo_images,,,,PACKAGE_FILELIST))
$(eval $(call gb_AutoInstall_add_module,ooobinarytable,LIBO_LIB_FILE_BINARYTABLE))
-$(eval $(call gb_AutoInstall_add_module,python,LIBO_LIB_FILE,LIBO_EXECUTABLE))
-$(eval $(call gb_AutoInstall_add_module,python_scriptprovider,))
-$(eval $(call gb_AutoInstall_add_module,python_librelogo,))
-$(eval $(call gb_AutoInstall_add_module,postgresqlsdbc,LIBO_LIB_FILE))
-$(eval $(call gb_AutoInstall_add_module,pdfimport,LIBO_LIB_FILE,LIBO_EXECUTABLE))
+$(eval $(call gb_AutoInstall_add_module,python,LIBO_LIB_FILE,LIBO_EXECUTABLE,,PACKAGE_FILELIST))
+$(eval $(call gb_AutoInstall_add_module,python_scriptprovider,,,,PACKAGE_FILELIST))
+$(eval $(call gb_AutoInstall_add_module,python_librelogo,,,,PACKAGE_FILELIST))
+$(eval $(call gb_AutoInstall_add_module,postgresqlsdbc,LIBO_LIB_FILE,,,PACKAGE_FILELIST))
+$(eval $(call gb_AutoInstall_add_module,pdfimport,LIBO_LIB_FILE,LIBO_EXECUTABLE,,PACKAGE_FILELIST))
$(eval $(call gb_AutoInstall_add_module,quickstart,,LIBO_EXECUTABLE))
-$(eval $(call gb_AutoInstall_add_module,reportbuilder,LIBO_LIB_FILE,,LIBO_JAR_FILE))
-$(eval $(call gb_AutoInstall_add_module,sdk,,SDK_EXECUTABLE))
+$(eval $(call gb_AutoInstall_add_module,reportbuilder,LIBO_LIB_FILE,,LIBO_JAR_FILE,PACKAGE_FILELIST))
+$(eval $(call gb_AutoInstall_add_module,sdk,,SDK_EXECUTABLE,,PACKAGE_FILELIST))
$(eval $(call gb_AutoInstall_add_module,tde,LIBO_LIB_FILE,LIBO_EXECUTABLE))
-$(eval $(call gb_AutoInstall_add_module,ure,URE_PRIVATE_LIB,URE_EXECUTABLE,URE_JAR_FILE))
+$(eval $(call gb_AutoInstall_add_module,ure,URE_PRIVATE_LIB,URE_EXECUTABLE,URE_JAR_FILE,PACKAGE_FILELIST))
$(eval $(call gb_AutoInstall_add_module,winexplorerextbinarytable,LIBO_LIB_FILE_BINARYTABLE))
$(eval $(call gb_AutoInstall_add_module,winexplorerext,SHLXTHDL_LIB_FILE))
$(eval $(call gb_AutoInstall_add_module,winexplorerextnt6,SHLXTHDL_LIB_FILE_COMPONENTCONDITION,,,"VersionNT >= 600"))
@@ -54,7 +54,7 @@ $(eval $(call gb_AutoInstall_add_module,winexplorerextwin64,SHLXTHDL_LIB_FILE_CO
$(eval $(call gb_AutoInstall_add_module,winexplorerextwin64nt6,SHLXTHDL_LIB_FILE_COMPONENTCONDITION,,,"VersionNT64 >= 600"))
endif
$(eval $(call gb_AutoInstall_add_module,writer,LIBO_LIB_FILE))
-$(eval $(call gb_AutoInstall_add_module,writer_brand,,LIBO_EXECUTABLE))
-$(eval $(call gb_AutoInstall_add_module,xsltfilter,))
+$(eval $(call gb_AutoInstall_add_module,writer_brand,,LIBO_EXECUTABLE,,PACKAGE_FILELIST))
+$(eval $(call gb_AutoInstall_add_module,xsltfilter,,,,PACKAGE_FILELIST))
# vim: set noet sw=4 ts=4:
diff --git a/solenv/gbuild/AutoInstall.mk b/solenv/gbuild/AutoInstall.mk
index 5bf4d985b5cd..9799fc6ecc44 100644
--- a/solenv/gbuild/AutoInstall.mk
+++ b/solenv/gbuild/AutoInstall.mk
@@ -36,6 +36,7 @@ $(call gb_AutoInstall_get_target,%) : $(GBUILDDIR)/AutoInstall.mk \
$(GBUILDDIR)/gen-autoinstall.py \
'$*' '$(SCP2COMPONENTCONDITION)' \
'$(SCP2LIBTEMPLATE)' '$(SCP2EXETEMPLATE)' '$(SCP2JARTEMPLATE)' \
+ '$(SCP2PKGTEMPLATE)' \
$${SDKLIBFILE} $${LIBFILE} $${EXEFILE} $${JARFILE} $${PKGFILE} \
> $@ \
&& rm -f $${SDKLIBFILE} $${LIBFILE} $${EXEFILE} $${JARFILE} $${PKGFILE}
@@ -53,7 +54,7 @@ $(call gb_Helper_make_userfriendly_targets,all,AutoInstall)
endef
-# gb_AutoInstall_add_module module lib_template exe_template jar_template componentcondition
+# gb_AutoInstall_add_module module lib_template exe_template jar_template package_template componentcondition
define gb_AutoInstall_add_module
$(call gb_AutoInstall_get_target,all) : $(call gb_AutoInstall_get_target,$(1))
$(call gb_AutoInstall_get_clean_target,all) : $(call gb_AutoInstall_get_clean_target,$(1))
@@ -64,7 +65,8 @@ $(call gb_AutoInstall_get_target,$(1)) :| $(dir $(call gb_AutoInstall_get_target
$(call gb_AutoInstall_get_target,$(1)) : SCP2LIBTEMPLATE := $(2)
$(call gb_AutoInstall_get_target,$(1)) : SCP2EXETEMPLATE := $(3)
$(call gb_AutoInstall_get_target,$(1)) : SCP2JARTEMPLATE := $(4)
-$(call gb_AutoInstall_get_target,$(1)) : SCP2COMPONENTCONDITION := $(5)
+$(call gb_AutoInstall_get_target,$(1)) : SCP2PKGTEMPLATE := $(5)
+$(call gb_AutoInstall_get_target,$(1)) : SCP2COMPONENTCONDITION := $(6)
endef
diff --git a/solenv/gbuild/gen-autoinstall.py b/solenv/gbuild/gen-autoinstall.py
index 53690bf439f5..4ae3e62ca04c 100644
--- a/solenv/gbuild/gen-autoinstall.py
+++ b/solenv/gbuild/gen-autoinstall.py
@@ -18,16 +18,17 @@ scp2componentcondition = sys.argv[2]
scp2libtemplate = sys.argv[3]
scp2exetemplate = sys.argv[4]
scp2jartemplate = sys.argv[5]
+scp2pkgtemplate = sys.argv[6]
# use 'with open(file) as f:' to avoid 'ResourceWarning: unclosed file'
-with open(sys.argv[6]) as f:
- sdklibs = f.readline().split()
with open(sys.argv[7]) as f:
- libs = f.readline().split()
+ sdklibs = f.readline().split()
with open(sys.argv[8]) as f:
- exes = f.readline().split()
+ libs = f.readline().split()
with open(sys.argv[9]) as f:
- jars = f.readline().split()
+ exes = f.readline().split()
with open(sys.argv[10]) as f:
+ jars = f.readline().split()
+with open(sys.argv[11]) as f:
pkgs = f.readline().split()
if len(scp2componentcondition) > 0:
@@ -72,16 +73,28 @@ print(", \\\n".join([" " + gid for gid in allgids]))
for (gid, link, target) in autosdklibs:
print("SDK_LIBRARY_LINK(" + gid + "," + link + "," + target + ")")
+scp2libtemplates = { "URE_PRIVATE_LIB", "LIBO_LIB_FILE", "LIBO_LIB_FILE_BINARYTABLE", "LIBO_LIB_FILE_COMPONENTCONDITION", "SHLXTHDL_LIB_FILE", "SHLXTHDL_LIB_FILE_COMPONENTCONDITION" }
for (gid, libfile) in autolibs:
+ if not(scp2libtemplate in scp2libtemplates):
+ raise Exception("invalid scp2libtemplate \"" + scp2libtemplate + "\"")
print(scp2libtemplate + "(" + gid + "," + libfile + scp2componentcondition + ")")
+scp2exetemplates = { "URE_EXECUTABLE", "LIBO_EXECUTABLE", "LIBO_EXECUTABLE_COMPONENTCONDITION", "SDK_EXECUTABLE" }
for (gid, exefile) in autoexes:
+ if not(scp2exetemplate in scp2exetemplates):
+ raise Exception("invalid scp2exetemplate \"" + scp2exetemplate + "\"")
print(scp2exetemplate + "(" + gid + "," + exefile + scp2componentcondition + ")")
+scp2jartemplates = { "URE_JAR_FILE", "LIBO_JAR_FILE" }
for (gid, jarfile) in autojars:
+ if not(scp2jartemplate in scp2jartemplates):
+ raise Exception("invalid scp2jartemplate \"" + scp2jartemplate + "\"")
print(scp2jartemplate + "(" + gid + "," + jarfile + scp2componentcondition + ")")
+scp2pkgtemplates = { "PACKAGE_FILELIST" }
for (gid, pkgfilelist) in autopkgs:
- print("PACKAGE_FILELIST(" + gid + "," + pkgfilelist + ")")
+ if not(scp2pkgtemplate in scp2pkgtemplates):
+ raise Exception("invalid scp2pkgtemplate \"" + scp2pkgtemplate + "\"")
+ print(scp2pkgtemplate + "(" + gid + "," + pkgfilelist + ")")
# vim:set shiftwidth=4 softtabstop=4 expandtab: