gendistrib

Langue: en

Version: 2007-06-15 (mandriva - 22/10/07)

Section: 1 (Commandes utilisateur)

NAME

gendistrib - generates a mirror tree for a distribution

SYNOPSIS

     gendistrib [options] directory
 
 

OPTIONS

--blind
Always rebuild indexes, without checking whether it's needed.
--hdlists file
Path of the hdlists file (defaults to media/media_info/hdlists). This is deprecated; if gendistrib finds a media.cfg file, it will use it and ignore the hdlists file unless this option is given.
--mediacfg file
Use the specified media.cfg file (defaults to media/media_info/media.cfg).
--nobadrpm
Don't abort when encountering bad rpms.
--noemptymedia
Stop and abort if an empty media is found.
--nomd5sum
Don't generate MD5SUM files.
--skipmissingdir
If a media dir is missing, ignore it instead of aborting.
-s
Silent mode.

DESCRIPTION

gendistrib is a tool that helps to generate the structure of a Mandriva RPM repository, compatible with Mandriva tools (urpmi, rpmdrake, etc.)

General Structure of a Repository

A typical repository, under a root directory /ROOT/, has the following structure:

     ROOT/ - media/
             |- contrib/
             |   `- media_info/
             |- main/
             |   `- media_info/
             `- media_info/
 
 

In this example, we have two media, called main and contrib. The RPMs packages are placed in the main and contrib subdirectories. Repository metadata is contained in the top-level media_info directory. Per-media metadata are contained in the main/media_info and contrib/media_info subdirectories.

Configuration of the distribution tree

Before using gendistrib, you must create a file media_info/media.cfg to describe your repository. (An empty file will work, but this isn't recommended.) The syntax of this file is reminiscent of .ini files.

A first section "[media_info]" contains global information about the repository:

     [media_info]
     version=2006.0
     branch=Cooker
     arch=i586
 
 

Then, supply one section per media.

     [main]
     hdlist=hdlist_main.cz
     name=Main
 
 

Here, the "hdlist" parameter specifies what will be the name of the hdlist file in the top-level media_info directory. "name" is a human readable label for the media.

Operation

gendistrib should be passed the ROOT directory as parameter. It will then generate the hdlist and synthesis files and all other files needed for proper repository operation.

SEE ALSO

genhdlist2(1), and MDV::Distribconf(3) for description of the format of the media.cfg file. Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005 MandrakeSoft SA

Copyright (C) 2005, 2006 Mandriva SA

This program 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 2, or (at your option) any later version.

This program 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 this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.