NAME

rt_makedist - create/update source files specified in an RPM spec.

SYNOPSIS

 rt_makedist [OPTIONS]
 rt_makedist [OPTIONS] PROJECT.spec
 rt_makedist [OPTIONS] PROJECT.spec.in
 rt_makedist [OPTIONS] PROJECT.bootstrap

DESCRIPTION

rt_makedist creates or updates sources, patches and icons specified in an RPM spec file. It's intended to be used with projects that maintain their spec files within their source trees; it expects to find the actual source files in the same directory as PROJECT.spec.

For example if your project's spec file contains something like this:

 ...
 Name: foo
 Version: 1.0
 Source: %name-%version.tar.gz
 ...

this script will try to create the file foo-1.0.tar.gz, as described below.

Upon startup, if no filenames are provided rt_makedist searches "." and ".." for the files *.bootstrap, *.spec.in and *.spec in that order and exits with an error message if eiher directory contains more than one file of each kind, or if neither directory contains any matching files.

After that, if the -x option was specified, it calls rt_bootstrap(1) in order to create/update the project's build scripts (the spec file, make files, etc.).

Next, it tries to create/update all source files, patches and icons mentioned in the spec file:

At this point all sources, patches and icons must exist in the project's top-level directory, otherwise rt_makedist exits with an error message.

Finally, it copies all source files, patches and icons from the project's top-level directory to the rpmbuild's source directory (%_sourcedir).

EXAMPLE

The following example shows how rt_makedist parses a simple spec file and creates a .tar.gz archive required to build it.

 % ls -1
 Makefile
 foo.c
 foo.spec

 % egrep 'Name|Version|Source' foo.spec
 Name: foo
 Version: 1.0
 Source: %name-%version.tar.gz

 % rt_makedist
 ...
 rt_makedist: created foo-1.0.tar.gz

OPTIONS

FILES

SEE ALSO

autoconf(8), Module::Build, ExtUtils::MakeMaker, rt_bootstrap(1), rt_archive(1), rt_distfiles(1)

AUTHORS

Davlet Panech - dpanech at users dot sourceforge dot net

COPYRIGHT AND LICENSE

Copyright 2010 Davlet Panech.

Rpmtoolbox is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

Rpmtoolbox is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with rpmtoolbox. If not, see <www.gnu.org>.