From 71485564ccb53196c6b6ea8c0a8ee66fbcd85fdf Mon Sep 17 00:00:00 2001 From: Michael Olbrich Date: Thu, 3 Jun 2010 16:19:47 +0200 Subject: [autotools] cleanup build system Signed-off-by: Michael Olbrich --- web-gui/Makefile.am | 3 ++ web-gui/calculator/Makefile.am | 25 +++++++++++-- web-gui/calculator/config.json.in | 3 +- web-gui/calculator/generate.py | 72 -------------------------------------- web-gui/calculator/generate.py.in | 72 ++++++++++++++++++++++++++++++++++++++ web-gui/calculator/readme.txt | 10 ------ web-gui/hello-world/Makefile.am | 24 +++++++++++-- web-gui/hello-world/config.json.in | 3 +- web-gui/hello-world/generate.py | 72 -------------------------------------- web-gui/hello-world/generate.py.in | 72 ++++++++++++++++++++++++++++++++++++++ web-gui/hello-world/readme.txt | 10 ------ 11 files changed, 194 insertions(+), 172 deletions(-) delete mode 100755 web-gui/calculator/generate.py create mode 100755 web-gui/calculator/generate.py.in delete mode 100644 web-gui/calculator/readme.txt delete mode 100755 web-gui/hello-world/generate.py create mode 100755 web-gui/hello-world/generate.py.in delete mode 100644 web-gui/hello-world/readme.txt (limited to 'web-gui') diff --git a/web-gui/Makefile.am b/web-gui/Makefile.am index 4ca8f21..e0304e9 100644 --- a/web-gui/Makefile.am +++ b/web-gui/Makefile.am @@ -3,6 +3,9 @@ SUBDIRS = \ hello-world \ calculator +clean-local: + rm -rf qooxdoo-cache + MAINTAINERCLEANFILES = \ Makefile.in diff --git a/web-gui/calculator/Makefile.am b/web-gui/calculator/Makefile.am index af29dd7..92e5608 100644 --- a/web-gui/calculator/Makefile.am +++ b/web-gui/calculator/Makefile.am @@ -1,10 +1,29 @@ +QOOXDOO_SOURCE = \ + Manifest.json \ + generate.py \ + source/resource/calculator/back.png \ + source/script/calculator.js \ + source/index.html \ + source/translation/readme.txt \ + source/class/calculator/Application.js \ + source/class/calculator/test/DemoTest.js \ + source/class/calculator/theme/Color.js \ + source/class/calculator/theme/Theme.js \ + source/class/calculator/theme/Decoration.js \ + source/class/calculator/theme/Font.js \ + source/class/calculator/theme/Appearance.js + all: - if [ "@srcdir@" != "@builddir@" ]; then \ - cp -a "@srcdir@/"{source,generate.py,Manifest.json} "@builddir@/"; \ - fi ./generate.py build +clean-local: + rm -rf build + +EXTRA_DIST = \ + config.json.in \ + $(QOOXDOO_SOURCE) + MAINTAINERCLEANFILES = \ Makefile.in diff --git a/web-gui/calculator/config.json.in b/web-gui/calculator/config.json.in index 73bc087..93c33c7 100644 --- a/web-gui/calculator/config.json.in +++ b/web-gui/calculator/config.json.in @@ -36,7 +36,8 @@ "API_EXCLUDE" : ["qx.test.*", "${APPLICATION}.theme.*", "${APPLICATION}.test.*"], "LOCALES" : [ "en" ], "CACHE" : "@abs_builddir@/../qooxdoo-cache", - "ROOT" : "." + "BUILD_PATH" : "@abs_builddir@/build", + "ROOT" : "@abs_srcdir@" } // You only need to edit the remainder of this file, if you want to customize diff --git a/web-gui/calculator/generate.py b/web-gui/calculator/generate.py deleted file mode 100755 index 2d7794d..0000000 --- a/web-gui/calculator/generate.py +++ /dev/null @@ -1,72 +0,0 @@ -#!/usr/bin/env python -################################################################################ -# -# qooxdoo - the new era of web development -# -# http://qooxdoo.org -# -# Copyright: -# 2008 - 2009 1&1 Internet AG, Germany, http://www.1und1.de -# -# License: -# LGPL: http://www.gnu.org/licenses/lgpl.html -# EPL: http://www.eclipse.org/org/documents/epl-v10.php -# See the LICENSE file in the project's top-level directory for details. -# -# Authors: -# * Thomas Herchenroeder (thron7) -# -################################################################################ - -## -# This is a stub proxy for the real generator.py -## - -import sys, os, re, subprocess - -CMD_PYTHON = 'python' -QOOXDOO_PATH = '../../../../src/qooxdoo-1.1-sdk' - -def getQxPath(): - path = QOOXDOO_PATH - # try updating from config file - if os.path.exists('config.json'): - # "using QOOXDOO_PATH from config.json" - qpathr=re.compile(r'"QOOXDOO_PATH"\s*:\s*"([^"]*)"\s*,?') - conffile = open('config.json') - aconffile = conffile.readlines() - for line in aconffile: - mo = qpathr.search(line) - if mo: - path = mo.group(1) - break # assume first occurrence is ok - path = os.path.normpath(os.path.join(os.path.dirname(os.path.abspath(sys.argv[0])), path)) - - return path - -os.chdir(os.path.dirname(os.path.abspath(sys.argv[0]))) # switch to skeleton dir -qxpath = getQxPath() -REAL_GENERATOR = os.path.join(qxpath, 'tool', 'bin', 'generator.py') - -if not os.path.exists(REAL_GENERATOR): - print "Cannot find real generator script under: \"%s\"; aborting" % REAL_GENERATOR - sys.exit(1) - -argList = [] -argList.append(CMD_PYTHON) -argList.append(REAL_GENERATOR) -argList.extend(sys.argv[1:]) -if sys.platform == "win32": - argList1=[] - for arg in argList: - if arg.find(' ')>-1: - argList1.append('"%s"' % arg) - else: - argList1.append(arg) - argList = argList1 -else: - argList = ['"%s"' % x for x in argList] # quote argv elements - -cmd = " ".join(argList) -retval = subprocess.call(cmd, shell=True) -sys.exit(retval) diff --git a/web-gui/calculator/generate.py.in b/web-gui/calculator/generate.py.in new file mode 100755 index 0000000..2e1f102 --- /dev/null +++ b/web-gui/calculator/generate.py.in @@ -0,0 +1,72 @@ +#!/usr/bin/env python +################################################################################ +# +# qooxdoo - the new era of web development +# +# http://qooxdoo.org +# +# Copyright: +# 2008 - 2009 1&1 Internet AG, Germany, http://www.1und1.de +# +# License: +# LGPL: http://www.gnu.org/licenses/lgpl.html +# EPL: http://www.eclipse.org/org/documents/epl-v10.php +# See the LICENSE file in the project's top-level directory for details. +# +# Authors: +# * Thomas Herchenroeder (thron7) +# +################################################################################ + +## +# This is a stub proxy for the real generator.py +## + +import sys, os, re, subprocess + +CMD_PYTHON = 'python' +QOOXDOO_PATH = '@QOOXDOO_SDK@' + +def getQxPath(): + path = QOOXDOO_PATH + # try updating from config file + if os.path.exists('config.json'): + # "using QOOXDOO_PATH from config.json" + qpathr=re.compile(r'"QOOXDOO_PATH"\s*:\s*"([^"]*)"\s*,?') + conffile = open('config.json') + aconffile = conffile.readlines() + for line in aconffile: + mo = qpathr.search(line) + if mo: + path = mo.group(1) + break # assume first occurrence is ok + path = os.path.normpath(os.path.join(os.path.dirname(os.path.abspath(sys.argv[0])), path)) + + return path + +os.chdir(os.path.dirname(os.path.abspath(sys.argv[0]))) # switch to skeleton dir +qxpath = getQxPath() +REAL_GENERATOR = os.path.join(qxpath, 'tool', 'bin', 'generator.py') + +if not os.path.exists(REAL_GENERATOR): + print "Cannot find real generator script under: \"%s\"; aborting" % REAL_GENERATOR + sys.exit(1) + +argList = [] +argList.append(CMD_PYTHON) +argList.append(REAL_GENERATOR) +argList.extend(sys.argv[1:]) +if sys.platform == "win32": + argList1=[] + for arg in argList: + if arg.find(' ')>-1: + argList1.append('"%s"' % arg) + else: + argList1.append(arg) + argList = argList1 +else: + argList = ['"%s"' % x for x in argList] # quote argv elements + +cmd = " ".join(argList) +retval = subprocess.call(cmd, shell=True) +sys.exit(retval) diff --git a/web-gui/calculator/readme.txt b/web-gui/calculator/readme.txt deleted file mode 100644 index a7b3d84..0000000 --- a/web-gui/calculator/readme.txt +++ /dev/null @@ -1,10 +0,0 @@ -GUI Skeleton - A qooxdoo Application Template -============================================= - -This is a qooxdoo application skeleton which is used as a template. The -'create-application.py' script (usually under tool/bin/create-application.py) -will use this and expand it into a self-contained qooxdoo application which -can then be further extended. Please refer to the script and other documentation -for further information. - -short:: is a standard qooxdoo GUI application \ No newline at end of file diff --git a/web-gui/hello-world/Makefile.am b/web-gui/hello-world/Makefile.am index af29dd7..2f3d390 100644 --- a/web-gui/hello-world/Makefile.am +++ b/web-gui/hello-world/Makefile.am @@ -1,10 +1,28 @@ +QOOXDOO_SOURCE = \ + Manifest.json \ + generate.py \ + source/resource/hello_world/back.png \ + source/index.html \ + source/translation/readme.txt \ + source/class/hello_world/Application.js \ + source/class/hello_world/test/DemoTest.js \ + source/class/hello_world/theme/Color.js \ + source/class/hello_world/theme/Theme.js \ + source/class/hello_world/theme/Decoration.js \ + source/class/hello_world/theme/Font.js \ + source/class/hello_world/theme/Appearance.js + all: - if [ "@srcdir@" != "@builddir@" ]; then \ - cp -a "@srcdir@/"{source,generate.py,Manifest.json} "@builddir@/"; \ - fi ./generate.py build +clean-local: + rm -rf build + +EXTRA_DIST = \ + config.json.in \ + $(QOOXDOO_SOURCE) + MAINTAINERCLEANFILES = \ Makefile.in diff --git a/web-gui/hello-world/config.json.in b/web-gui/hello-world/config.json.in index 0952a8f..82e59af 100644 --- a/web-gui/hello-world/config.json.in +++ b/web-gui/hello-world/config.json.in @@ -36,7 +36,8 @@ "API_EXCLUDE" : ["qx.test.*", "${APPLICATION}.theme.*", "${APPLICATION}.test.*"], "LOCALES" : [ "en" ], "CACHE" : "@abs_builddir@/../qooxdoo-cache", - "ROOT" : "." + "BUILD_PATH" : "@abs_builddir@/build", + "ROOT" : "@abs_srcdir@" } // You only need to edit the remainder of this file, if you want to customize diff --git a/web-gui/hello-world/generate.py b/web-gui/hello-world/generate.py deleted file mode 100755 index 2d7794d..0000000 --- a/web-gui/hello-world/generate.py +++ /dev/null @@ -1,72 +0,0 @@ -#!/usr/bin/env python -################################################################################ -# -# qooxdoo - the new era of web development -# -# http://qooxdoo.org -# -# Copyright: -# 2008 - 2009 1&1 Internet AG, Germany, http://www.1und1.de -# -# License: -# LGPL: http://www.gnu.org/licenses/lgpl.html -# EPL: http://www.eclipse.org/org/documents/epl-v10.php -# See the LICENSE file in the project's top-level directory for details. -# -# Authors: -# * Thomas Herchenroeder (thron7) -# -################################################################################ - -## -# This is a stub proxy for the real generator.py -## - -import sys, os, re, subprocess - -CMD_PYTHON = 'python' -QOOXDOO_PATH = '../../../../src/qooxdoo-1.1-sdk' - -def getQxPath(): - path = QOOXDOO_PATH - # try updating from config file - if os.path.exists('config.json'): - # "using QOOXDOO_PATH from config.json" - qpathr=re.compile(r'"QOOXDOO_PATH"\s*:\s*"([^"]*)"\s*,?') - conffile = open('config.json') - aconffile = conffile.readlines() - for line in aconffile: - mo = qpathr.search(line) - if mo: - path = mo.group(1) - break # assume first occurrence is ok - path = os.path.normpath(os.path.join(os.path.dirname(os.path.abspath(sys.argv[0])), path)) - - return path - -os.chdir(os.path.dirname(os.path.abspath(sys.argv[0]))) # switch to skeleton dir -qxpath = getQxPath() -REAL_GENERATOR = os.path.join(qxpath, 'tool', 'bin', 'generator.py') - -if not os.path.exists(REAL_GENERATOR): - print "Cannot find real generator script under: \"%s\"; aborting" % REAL_GENERATOR - sys.exit(1) - -argList = [] -argList.append(CMD_PYTHON) -argList.append(REAL_GENERATOR) -argList.extend(sys.argv[1:]) -if sys.platform == "win32": - argList1=[] - for arg in argList: - if arg.find(' ')>-1: - argList1.append('"%s"' % arg) - else: - argList1.append(arg) - argList = argList1 -else: - argList = ['"%s"' % x for x in argList] # quote argv elements - -cmd = " ".join(argList) -retval = subprocess.call(cmd, shell=True) -sys.exit(retval) diff --git a/web-gui/hello-world/generate.py.in b/web-gui/hello-world/generate.py.in new file mode 100755 index 0000000..2e1f102 --- /dev/null +++ b/web-gui/hello-world/generate.py.in @@ -0,0 +1,72 @@ +#!/usr/bin/env python +################################################################################ +# +# qooxdoo - the new era of web development +# +# http://qooxdoo.org +# +# Copyright: +# 2008 - 2009 1&1 Internet AG, Germany, http://www.1und1.de +# +# License: +# LGPL: http://www.gnu.org/licenses/lgpl.html +# EPL: http://www.eclipse.org/org/documents/epl-v10.php +# See the LICENSE file in the project's top-level directory for details. +# +# Authors: +# * Thomas Herchenroeder (thron7) +# +################################################################################ + +## +# This is a stub proxy for the real generator.py +## + +import sys, os, re, subprocess + +CMD_PYTHON = 'python' +QOOXDOO_PATH = '@QOOXDOO_SDK@' + +def getQxPath(): + path = QOOXDOO_PATH + # try updating from config file + if os.path.exists('config.json'): + # "using QOOXDOO_PATH from config.json" + qpathr=re.compile(r'"QOOXDOO_PATH"\s*:\s*"([^"]*)"\s*,?') + conffile = open('config.json') + aconffile = conffile.readlines() + for line in aconffile: + mo = qpathr.search(line) + if mo: + path = mo.group(1) + break # assume first occurrence is ok + path = os.path.normpath(os.path.join(os.path.dirname(os.path.abspath(sys.argv[0])), path)) + + return path + +os.chdir(os.path.dirname(os.path.abspath(sys.argv[0]))) # switch to skeleton dir +qxpath = getQxPath() +REAL_GENERATOR = os.path.join(qxpath, 'tool', 'bin', 'generator.py') + +if not os.path.exists(REAL_GENERATOR): + print "Cannot find real generator script under: \"%s\"; aborting" % REAL_GENERATOR + sys.exit(1) + +argList = [] +argList.append(CMD_PYTHON) +argList.append(REAL_GENERATOR) +argList.extend(sys.argv[1:]) +if sys.platform == "win32": + argList1=[] + for arg in argList: + if arg.find(' ')>-1: + argList1.append('"%s"' % arg) + else: + argList1.append(arg) + argList = argList1 +else: + argList = ['"%s"' % x for x in argList] # quote argv elements + +cmd = " ".join(argList) +retval = subprocess.call(cmd, shell=True) +sys.exit(retval) diff --git a/web-gui/hello-world/readme.txt b/web-gui/hello-world/readme.txt deleted file mode 100644 index a7b3d84..0000000 --- a/web-gui/hello-world/readme.txt +++ /dev/null @@ -1,10 +0,0 @@ -GUI Skeleton - A qooxdoo Application Template -============================================= - -This is a qooxdoo application skeleton which is used as a template. The -'create-application.py' script (usually under tool/bin/create-application.py) -will use this and expand it into a self-contained qooxdoo application which -can then be further extended. Please refer to the script and other documentation -for further information. - -short:: is a standard qooxdoo GUI application \ No newline at end of file -- cgit v1.2.3