.\" Man page generated from reStructeredText. . .TH PYBUILD 1 "" "" "" .SH NAME pybuild \- invokes various build systems for requested Python versions in order to build modules and extensions . .nr rst2man-indent-level 0 . .de1 rstReportMargin \\$1 \\n[an-margin] level \\n[rst2man-indent-level] level margin: \\n[rst2man-indent\\n[rst2man-indent-level]] - \\n[rst2man-indent0] \\n[rst2man-indent1] \\n[rst2man-indent2] .. .de1 INDENT .\" .rstReportMargin pre: . RS \\$1 . nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin] . nr rst2man-indent-level +1 .\" .rstReportMargin post: .. .de UNINDENT . RE .\" indent \\n[an-margin] .\" old: \\n[rst2man-indent\\n[rst2man-indent-level]] .nr rst2man-indent-level -1 .\" new: \\n[rst2man-indent\\n[rst2man-indent-level]] .in \\n[rst2man-indent\\n[rst2man-indent-level]]u .. .SH SYNOPSIS .INDENT 0.0 .INDENT 3.5 pybuild [ACTION] [BUILD SYSTEM ARGUMENTS] [DIRECTORIES] [OPTIONS] .UNINDENT .UNINDENT .SH DEBHELPER COMMAND SEQUENCER INTEGRATION .INDENT 0.0 .IP \(bu 2 build depend on \fIdh\-python\fP, .IP \(bu 2 build depend on \fIpython3\-all\fP, \fIpython\-all\-dbg\fP, \fIpypy\fP, etc. (for all supported Python interpreters, pybuild will use it to create a list of interpreters to build for), .IP \(bu 2 add \fI\-\-buildsystem=pybuild\fP to dh\(aqs arguments in debian/rules, .IP \(bu 2 if more than one binary package is build: add debian/python\-foo.install files, or \fIexport PYBUILD_NAME=modulename\fP (modulename will be used to guess binary package prefixes), or \fIexport PYBUILD_DESTDIR\fP env. variables in debian/rules .UNINDENT .sp debian/rules file example: .sp .nf .ft C #! /usr/bin/make \-f export PYBUILD_NAME=foo %: dh $@ \-\-with python2,python3 \-\-buildsystem=pybuild .ft P .fi .sp overriding test command with custom build plugin example: .sp .nf .ft C override_dh_auto_test: PYBUILD_SYSTEM=custom \e PYBUILD_TEST_ARGS="command \-\-with \-\-options {build_dir}/" dh_auto_test .ft P .fi .SH OPTIONS .INDENT 0.0 .INDENT 3.5 Most options can be set (in addition to command line) via environment variables. PyBuild will check: .INDENT 0.0 .IP \(bu 2 PYBUILD_OPTION_VERSIONED_INTERPRETER (f.e. PYBUILD_CLEAN_ARGS_python3.2) .IP \(bu 2 PYBUILD_OPTION_INTERPRETER (f.e. PYBUILD_CONFIGURE_ARGS_python3\-dbg) .IP \(bu 2 PYBUILD_OPTION (f.e. PYBUILD_INSTALL_ARGS) .UNINDENT .UNINDENT .UNINDENT .SS optional arguments .INDENT 0.0 .INDENT 3.5 .INDENT 0.0 .TP .B \-h, \-\-help show this help message and exit .TP .B \-v, \-\-verbose turn verbose mode on .TP .B \-q, \-\-quiet doesn\(aqt show external command\(aqs output .TP .BI \-q\fB q, \ \-\-really\-quiet be quiet .TP .B \-\-version show program\(aqs version number and exit .UNINDENT .UNINDENT .UNINDENT .SS ACTION .INDENT 0.0 .INDENT 3.5 The default is to build, install and test the library using detected build system version by version. Selecting one of following actions, will invoke given action for all versions \- one by one \- which (contrary to the default action) in some build systems can overwrite previous results. .INDENT 0.0 .INDENT 3.5 .INDENT 0.0 .TP .B \-\-detect return the name of detected build system .TP .B \-\-clean clean files using auto\-detected build system specific methods .TP .B \-\-configure invoke configure step for all requested Python versions .TP .B \-\-build invoke build step for all requested Python versions .TP .B \-\-install invoke install step for all requested Python versions .TP .B \-\-test invoke tests for auto\-detected build system .TP .B \-\-list\-systems list available build systems and exit .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .SS TESTS .INDENT 0.0 .INDENT 3.5 unittest\(aqs discover from standard library (available in Python 2.7 and >= 3.2) is used in test step by default. .INDENT 0.0 .TP .B \-\-test\-nose use nose module in test step, remember to add python\-nose and/or python3\-nose to Build\-Depends .TP .B \-\-test\-pytest use pytest module in test step, remember to add python\-pytest and/or python3\-pytest to Build\-Depends .TP .B \-\-test\-tox use tox command in test step, remember to add python\-tox to Build\-Depends. Requires tox.ini file .UNINDENT .UNINDENT .UNINDENT .SS BUILD SYSTEM ARGUMENTS .INDENT 0.0 .INDENT 3.5 Additional arguments passed to the build system. \-\-system=custom requires complete command. .INDENT 0.0 .INDENT 3.5 .INDENT 0.0 .TP .BI \-\-before\-clean \ COMMAND invoked before the clean command .TP .BI \-\-clean\-args \ ARGUMENTS arguments added to clean command generated by build system plugin .TP .BI \-\-after\-clean \ COMMAND invoked after the clean command .TP .BI \-\-before\-configure \ COMMAND invoked before the configure command .TP .BI \-\-configure\-args \ ARGUMENTS arguments added to configure command generated by build system plugin .TP .BI \-\-after\-configure \ COMMAND invoked after the configure command .TP .BI \-\-before\-build \ COMMAND invoked before the build command .TP .BI \-\-build\-args \ ARGUMENTS arguments added to build command generated by build system plugin .TP .BI \-\-after\-build \ COMMAND invoked after the build command .TP .BI \-\-before\-install \ COMMAND invoked before the install command .TP .BI \-\-install\-args \ ARGUMENTS arguments added to install command generated by build system plugin .TP .BI \-\-after\-install \ COMMAND invoked after the install command .TP .BI \-\-before\-test \ COMMAND invoked before the test command .TP .BI \-\-test\-args \ ARGUMENTS arguments added to test command generated by build system plugin .TP .BI \-\-after\-test \ COMMAND invoked after the test command .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .SS variables that can be used in \fIARGUMENTS\fP and \fICOMMAND\fP .INDENT 0.0 .IP \(bu 2 \fI{version}\fP will be replaced with current Python version, you can also use \fI{version.major}\fP, \fI{version.minor}\fP, etc. .IP \(bu 2 \fI{interpreter}\fP will be replaced with current interpreter, you can also use \fI{interpreter.include_dir}\fP .IP \(bu 2 \fI{dir}\fP will be replaced with sources directory, .IP \(bu 2 \fI{destdir}\fP will be replaced with destination directory, .IP \(bu 2 \fI{home_dir}\fP will be replaced with temporary HOME directory, where plugins can keep their data (.pybuild/interpreter_version/ by default), .IP \(bu 2 \fI{build_dir}\fP will be replaced with build directory .IP \(bu 2 \fI{install_dir}\fP will be replaced with install directory. .IP \(bu 2 \fI{package}\fP will be replaced with suggested package name, if \-\-name (or PYBUILD_NAME) is set to \fIfoo\fP, this variable will be replaced to \fIpython\-foo\fP, \fIpython3\-foo\fP or \fIpypy\-foo\fP depending on interpreter which is used in given iteration. .UNINDENT .SS DIRECTORIES .INDENT 0.0 .INDENT 3.5 .INDENT 0.0 .TP .BI \-d \ DIR, \ \-\-dir \ DIR set source files directory \- base for other relative dirs [by default: current working directory] .TP .BI \-\-dest\-dir \ DIR set destination directory [default: debian/tmp] .TP .BI \-\-ext\-dest\-dir \ DIR set destination directory for .so files .TP .BI \-\-ext\-pattern \ PATTERN regular expression for files that should be moved if \-\-ext\-destdir is set [default: \fI.so(.[^/]*)?$\fP] .TP .BI \-\-install\-dir \ DIR set installation directory [default: .../dist\-packages] .TP .BI \-\-name \ NAME use this name to guess destination directories (depending on interpreter, "foo" sets debian/python\-foo, debian/python3\-foo, debian/python3\-foo\-dbg, etc.) .UNINDENT .UNINDENT .UNINDENT .SS variables that can be used in \fIDIR\fP .INDENT 0.0 .IP \(bu 2 \fI{version}\fP will be replaced with current Python version, .IP \(bu 2 \fI{interpreter}\fP will be replaced with selected interpreter. .UNINDENT .SS LIMITATIONS .INDENT 0.0 .INDENT 3.5 .INDENT 0.0 .TP .BI \-s \ SYSTEM, \ \-\-system \ SYSTEM select a build system [default: auto\-detection] .TP .BI \-p \ VERSIONS, \ \-\-pyver \ VERSIONS build for Python VERSIONS. This option can be used multiple times. Versions can be separated by space character. The default is all Python 3.X supported versions. .TP .BI \-i \ INTERPRETER, \ \-\-interpreter \ INTERPRETER change interpreter [default: python{version}] .TP .BI \-\-disable \ ITEMS disable action, interpreter, version or any mix of them. Note that f.e. python3 and python3\-dbg are two different interpreters, \-\-disable python3/test doesn\(aqt disable python3\-dbg\(aqs tests. .UNINDENT .UNINDENT .UNINDENT .SS disable examples .INDENT 0.0 .IP \(bu 2 \fI\-\-disable test/python2.5\-dbg\fP \- disables tests for python2.5\-dbg .IP \(bu 2 \fI\-\-disable \(aq2.4 2.7\(aq\fP \- disables all actions for version 2.4 and 2.7 .IP \(bu 2 \fIPYBUILD_DISABLE_python2=1\fP \- disables all actions for Python 2.X .IP \(bu 2 \fIPYBUILD_DISABLE_python3.3=test\fP \- disables tests for Python 3.3 .IP \(bu 2 \fIPYBUILD_DISABLE=test/python3.3\fP \- same as above .IP \(bu 2 \fIPYBUILD_DISABLE=configure/python3 2.4 pypy\fP \- disables configure action for all python3 interpreters, all actions for version 2.4, and all actions for pypy .UNINDENT .SH SEE ALSO .INDENT 0.0 .IP \(bu 2 dh_python2(1) .IP \(bu 2 dh_python3(1) .IP \(bu 2 \fI\%https://wiki.debian.org/Python/Pybuild\fP .IP \(bu 2 \fI\%http://deb.li/pybuild\fP \- most recent version of this document .UNINDENT .SH AUTHOR Piotr Ożarowski, 2012-2013 .\" Generated by docutils manpage writer. .\" .