Commit ce264469 authored by Jondy Zhao's avatar Jondy Zhao Committed by Cédric de Saint Martin

Fork hexagonit.recipe.cmmi

parent 5312454e
Change History
**************
2.0 (2013-04-07)
================
- Dropped support for Python 2.4/2.5. Use the 1.x versions for those.
Currently supported versions are Python 2.6, 2.7, 3.2 and 3.3. [dokai]
- Python 3.2/3.3 support. [dokai, mmariani]
- Tox support.
https://github.com/hexagonit/hexagonit.recipe.cmmi/pull/7
[msabramo]
- Travis CI integration. https://travis-ci.org/hexagonit/hexagonit.recipe.cmmi
See https://github.com/hexagonit/hexagonit.recipe.cmmi/pull/7
[msabramo]
- Automatically clean up a left-over compile directory from a previously
failed run. See https://github.com/hexagonit/hexagonit.recipe.cmmi/pull/9
[desaintmartin]
1.6 (2012-06-28)
================
- Relicensed under the `3-clause BSD license <http://en.wikipedia.org/wiki/BSD_licenses#3-clause_license_.28.22New_BSD_License.22_or_.22Modified_BSD_License.22.29>`_.
[dokai]
1.5.1 (2012-05-21)
==================
- PEP8 / Pyflakes cleanup.
[dokai]
- Quote ``--prefix`` paths to support whitespace characters in
the path. Closes https://github.com/hexagonit/hexagonit.recipe.cmmi/pull/4
[galpin]
- Fixed importing of the hook scripts on Windows. Closes
https://github.com/hexagonit/hexagonit.recipe.cmmi/pull/6
[grzn]
1.5.0 (2010-12-17)
==================
- Refactored the environment variable handling logic. Python versions prior
to 2.6 have an issue clearing the environment variables using
``os.environ.clear()`` (See http://bugs.python.org/issue3227). [dokai]
Instead of modifying ``os.environ`` directly we use the ``subprocess``
module to run the commands in child processes which are given an explicit
environment which is a copy of the current ``os.environ`` augmented with
the per-part overrides. As a result, ``os.environ`` is no longer modified
by this recipe.
The `Python hook scripts`_ are passed the augmented environment dictionary
as a third parameter.
.. warning:: Existing hook scripts accepting only two parameters
continue to work but they do not have access to the modified
environment variables. To fix this they should be refactored
to accept the third parameter.
See https://github.com/hexagonit/hexagonit.recipe.cmmi/issues/issue/1/#issue/1/comment/605362
for details.
1.4.0 (2010-08-27)
==================
- Added support for passing options to ``make`` with the new
``make-options`` option. See the `Installing a package without an autoconf
like system`_ section below for an example. [dokai]
- The ``--prefix`` parameter will be automatically given to the configure
command if and only if
- the ``configure-command`` is not used to specify a custom configure command and
- ``--prefix`` is not given explicitly in the ``configure-options`` option.
[dokai]
- Removed the ``is_build_dir()`` heuristic.
Previously the recipe inspected the contents of the downloaded package to
determine if it contained the necessary files for building the package (it
checked if files named ``configure`` or ``Makefile.PL`` existed) and gave
an error message if they were missing. However, the recipe is useful for
building many different kinds of software packages and checking for
particular files limited its use severely.
Now the recipe omits any checks for particular files in the downloaded
package. It is recommended that you use the ``md5sum`` option in your part
configuration to assert that you are downloading the package you expect
to. [dokai]
1.3.1 (2010-08-23)
==================
- Refactored the ``is_build_dir()`` helper method to make it easier to test
and override in customized recipes. [dokai]
- Fixed the handling of the working directory so that it is restored to the
state before executing the recipe regardless whether the recipe was
successful or not. Thanks to Jonathan Ballet for the report and preliminary
patch. [dokai]
- Fixed http://github.com/hexagonit/hexagonit.recipe.cmmi/issues#issue/1
Environment variables defined in one part will no longer leak to other
subsequent parts. [dokai]
1.3.0 (2009-09-20)
==================
- Added new options ``environment-section`` and ``environment`` to control
environment variables before executing the recipe.
- Added a new option, ``prefix``, to override the installation prefix.
Defaults to the previously hardcoded value of the part location.
1.2.0
=====
- Added new ``configure-command`` option to control the command used to
generate the ``Makefile``. This makes it possible to build slightly
different packages, e.g. Perl projects where Makefile.PL replaces the
configure script.
1.1.1
=====
- Don't try to execute hooks if the option is an empty string. This
will make it possible to disable hooks when extending existing
parts.
1.1.0
=====
- Added new option ``path`` to allow building and installing local
source trees. The ``path`` option is mutually exclusive with
``url``.
1.0.1
=====
- Fixed a bug with 'keep-compile-dir' option. The location of the
compilation directory was not available through the
``options['compile-directory']`` option as documented.
1.0.0
=====
- Initial public release.
...@@ -6,13 +6,13 @@ Recipe for compiling and installing software ...@@ -6,13 +6,13 @@ Recipe for compiling and installing software
The recipe provides the means to compile and install source distributions The recipe provides the means to compile and install source distributions
using ``configure`` and ``make`` and other similar tools. It is inspired by using ``configure`` and ``make`` and other similar tools. It is inspired by
the zc.recipe.cmmi_ recipe but provides more control over the build process. the hexagonit.recipe.cmmi_ recipe but provides more control over the build process.
Repository: http://github.com/hexagonit/hexagonit.recipe.cmmi Repository: http://git.erp5.org/gitweb/slapos.recipe.cmmi.git
Clone URL: git clone git://github.com/hexagonit/hexagonit.recipe.cmmi.git Clone URL: git clone http://git.erp5.org/repos/slapos.recipe.cmmi.git
Issue tracker: http://github.com/hexagonit/hexagonit.recipe.cmmi/issues Issue tracker: None
Supported Python versions: 2.6, 2.7, 3.2, 3.3 Supported Python versions: 2.6, 2.7, 3.2, 3.3
......
[egg_info]
;tag_build = dev
;tag_svn_revision = true
from setuptools import setup, find_packages from setuptools import setup, find_packages
import os import os
version = '2.0' version = '0.1'
name = 'hexagonit.recipe.cmmi' name = 'slapos.recipe.cmmi'
def read(*rnames): def read(*rnames):
...@@ -16,12 +16,10 @@ setup( ...@@ -16,12 +16,10 @@ setup(
long_description=( long_description=(
read('README.rst') read('README.rst')
+ '\n' + + '\n' +
read('CHANGES.txt')
+ '\n' +
'Detailed Documentation\n' 'Detailed Documentation\n'
'**********************\n' '**********************\n'
+ '\n' + + '\n' +
read('hexagonit', 'recipe', 'cmmi', 'README.txt') read('slapos', 'recipe', 'cmmi', 'README.txt')
+ '\n' + + '\n' +
'Download\n' 'Download\n'
'***********************\n' '***********************\n'
......
...@@ -148,7 +148,7 @@ Supported options ...@@ -148,7 +148,7 @@ Supported options
used, for example, to append to the ``PATH`` variable, e.g.:: used, for example, to append to the ``PATH`` variable, e.g.::
[component] [component]
recipe = hexagonit.recipe.cmmi recipe = slapos.recipe.cmmi
environment-section = environment-section =
environment environment
...@@ -201,7 +201,7 @@ Let's create a buildout to build and install the package. ...@@ -201,7 +201,7 @@ Let's create a buildout to build and install the package.
... parts = package ... parts = package
... ...
... [package] ... [package]
... recipe = hexagonit.recipe.cmmi ... recipe = slapos.recipe.cmmi
... url = file://%s/package-0.0.0.tar.gz ... url = file://%s/package-0.0.0.tar.gz
... """ % src) ... """ % src)
...@@ -237,7 +237,7 @@ a custom location within the buildout:: ...@@ -237,7 +237,7 @@ a custom location within the buildout::
... perl_lib = ${buildout:directory}/perl_lib ... perl_lib = ${buildout:directory}/perl_lib
... ...
... [foobar] ... [foobar]
... recipe = hexagonit.recipe.cmmi ... recipe = slapos.recipe.cmmi
... configure-command = perl -I${buildout:perl_lib}/lib/perl5 Makefile.PL INSTALL_BASE=${buildout:perl_lib} ... configure-command = perl -I${buildout:perl_lib}/lib/perl5 Makefile.PL INSTALL_BASE=${buildout:perl_lib}
... url = file://%s/Foo-Bar-0.0.0.tar.gz ... url = file://%s/Foo-Bar-0.0.0.tar.gz
... """ % src) ... """ % src)
...@@ -272,7 +272,7 @@ Makefile and using explicit ``make`` options to control the build process. ...@@ -272,7 +272,7 @@ Makefile and using explicit ``make`` options to control the build process.
... parts = haproxy ... parts = haproxy
... ...
... [haproxy] ... [haproxy]
... recipe = hexagonit.recipe.cmmi ... recipe = slapos.recipe.cmmi
... configure-command = true ... configure-command = true
... make-options = ... make-options =
... TARGET=linux26 ... TARGET=linux26
...@@ -318,7 +318,7 @@ and building that. ...@@ -318,7 +318,7 @@ and building that.
... parts = package ... parts = package
... ...
... [package] ... [package]
... recipe = hexagonit.recipe.cmmi ... recipe = slapos.recipe.cmmi
... path = %s/package-0.0.0 ... path = %s/package-0.0.0
... """ % checkout_dir) ... """ % checkout_dir)
...@@ -357,7 +357,7 @@ with a new buildout and provide more options. ...@@ -357,7 +357,7 @@ with a new buildout and provide more options.
... LDFLAGS = -I/sw/lib ... LDFLAGS = -I/sw/lib
... ...
... [package] ... [package]
... recipe = hexagonit.recipe.cmmi ... recipe = slapos.recipe.cmmi
... url = file://%(src)s/package-0.0.0.tar.gz ... url = file://%(src)s/package-0.0.0.tar.gz
... md5sum = 6b94295c042a91ea3203857326bc9209 ... md5sum = 6b94295c042a91ea3203857326bc9209
... prefix = /somewhere/else ... prefix = /somewhere/else
...@@ -457,7 +457,7 @@ and a new buildout to try it out ...@@ -457,7 +457,7 @@ and a new buildout to try it out
... parts = package ... parts = package
... ...
... [package] ... [package]
... recipe = hexagonit.recipe.cmmi ... recipe = slapos.recipe.cmmi
... url = file://%(src)s/package-0.0.0.tar.gz ... url = file://%(src)s/package-0.0.0.tar.gz
... pre-configure-hook = %(module)s:preconfigure ... pre-configure-hook = %(module)s:preconfigure
... pre-make-hook = %(module)s:premake ... pre-make-hook = %(module)s:premake
...@@ -479,7 +479,7 @@ and a new buildout to try it out ...@@ -479,7 +479,7 @@ and a new buildout to try it out
hook: This is post-make-hook! hook: This is post-make-hook!
For even more specific needs you can write your own recipe that uses For even more specific needs you can write your own recipe that uses
``hexagonit.recipe.cmmi`` and set the ``keep-compile-dir`` option to ``true``. ``slapos.recipe.cmmi`` and set the ``keep-compile-dir`` option to ``true``.
You can then continue from where this recipe finished by reading the location You can then continue from where this recipe finished by reading the location
of the compile directory from ``options['compile-directory']`` from your own of the compile directory from ``options['compile-directory']`` from your own
recipe. recipe.
......
...@@ -24,8 +24,7 @@ optionflags = (doctest.ELLIPSIS | ...@@ -24,8 +24,7 @@ optionflags = (doctest.ELLIPSIS |
def setUp(test): def setUp(test):
zc.buildout.testing.buildoutSetUp(test) zc.buildout.testing.buildoutSetUp(test)
zc.buildout.testing.install('hexagonit.recipe.download', test) zc.buildout.testing.install('hexagonit.recipe.download', test)
zc.buildout.testing.install_develop('hexagonit.recipe.cmmi', test) zc.buildout.testing.install_develop('slapos.recipe.cmmi', test)
class NonInformativeTests(unittest.TestCase): class NonInformativeTests(unittest.TestCase):
...@@ -46,8 +45,8 @@ class NonInformativeTests(unittest.TestCase): ...@@ -46,8 +45,8 @@ class NonInformativeTests(unittest.TestCase):
os.chmod(path, mode) os.chmod(path, mode)
return path return path
def make_recipe(self, buildout, name, options): def make_recipe(self, buildout, name, options, **buildout_options):
from hexagonit.recipe.cmmi import Recipe from slapos.recipe.cmmi import Recipe
parts_directory_path = os.path.join(self.dir, 'test_parts') parts_directory_path = os.path.join(self.dir, 'test_parts')
try: try:
os.mkdir(parts_directory_path) os.mkdir(parts_directory_path)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment