Next: , Previous: Installation, Up: Top

3 Invoking pyconf

Before invoking the pyconf script, you first must decide whether you would prefer to have your installation logic written in Python or in Make. If you choose the former, the generated Makefile will be a wrapper around the Python installation script (i.e., while if you choose the latter, the Python installation script will be a wrapper around the Makefile.

Next, you must create a PKG-INFO file containing standard metadata about your project (see PKG-INFO metadata). Finally, in the most basic case, you would navigate to your project's directory and simply invoke pyconf on your project's PKG-INFO file:

     $ pyconf PKG-INFO

This will generate a Autoconf file, a configure script generated from that Autoconf file, a installation file (to be configured by the user upon the invocation of configure) and a file which wraps the functionality of If any of these files already exist, pyconf will not overwrite them unless the --overwrite option is passed.

If you wish the files to be copied into a different directory, you may add the --output option (or its short form -o) to specify the directory into which you would prefer the files to be copied.

     $ pyconf -output=$HOME/Projects/pyproject PKG-INFO

If you would prefer to write your installation logic using Make, pass the --prefer-make (-m) option:

     $ pyconf --prefer-make PKG-INFO

Now, the script that is generated will instead be a wrapper around the file. You would then extend the installation process in the latter file.

If you would prefer a pure-Python approach, pyconf may optionally not generate any Makefile by passing the --no-make option. Finally, if you only need pyconfigure's Autoconf macros, you may pass the --macros-only option, which causes pyconf to exit immediately after copying the macros into your package directory.