Permalink
Browse files

forked cpanplus-dist-mageia from cpanplus-dist-mdv

this includes changing all mdv / mandriva to mga / mageia
  • Loading branch information...
1 parent 9be46c2 commit f55339c46d84e33b37b014d0c8f82e5f1e123b2b @jquelin committed Jan 10, 2011
Showing with 39 additions and 170 deletions.
  1. +1 −1 .gitignore
  2. +1 −126 Changes
  3. +3 −9 dist.ini
  4. +32 −32 lib/CPANPLUS/Dist/{Mdv.pm → Mageia.pm}
  5. +2 −2 share/template.spec
View
2 .gitignore
@@ -27,5 +27,5 @@ cover_db
*.tmp
# Avoid archives of this distribution
-CPANPLUS-Dist-Mdv-*
+CPANPLUS-Dist-Mageia-*
View
127 Changes
@@ -1,129 +1,4 @@
Revision history for CPANPLUS-Dist-Mdv
{{$NEXT}}
-
-2.100400 2010-02-09 18:00:20 Europe/Paris
- - do not ship makefile.pl anymore, providing build.pl exclusively (for
- cpanplus::dist::mdv only - makefile.pl support for packaged modules
- still remains, of course! :-) )
- - filter out "perl" buildrequires (shlomi fish)
- - package meta.yml (or meta.json) as doc file
- - using file::sharedir for template spec file
- - using %make instead of %{make} for eumm-powered dists
- - doc update
-
-2.093311 2009-11-27 16:53:10 Europe/Paris
- - fix git repo in meta.yml
-
-2.093310 2009-11-27 14:46:53 Europe/Paris
- - moving to 2.yydddn version scheme
- - requiring perl 5.10.x (which is the default in mandriva)
- - fix #52096: improved error messages
-
-**
-
-1.2.1 Mon Jul 6 16:42:57 CEST 2009
- - fixing bug in prereq
-
-1.2.0 Wed Jul 1 17:47:57 2009
- - moving template spec in its own file
- - support for module::build only distributions (shlomi fish)
- - infrastructue: moving to dist::zilla
-
-**
-
-1.1.0 Fri May 22 13:11:58 CEST 2009
- - using %perl_convert_version macro to normalize version numbers
- - using valid license gpl+ or artistic
- - removing duplicates in %doc
- - makefile.pl now autogenerated
- - try to follow http://wiki.mandriva.com/en/Policies/RpmSpecProposal
-
-**
-
-1.0.0 Sun Feb 1 17:56:59 CET 2009
- - install() supported. module is somehow complete
- - select first rpm created (hence, not the -debug one)
-
-**
-
-0.3.9 Mon Nov 10 09:12:23 CET 2008
- - fix LC_ALL usage, failing on some smoker setups
-
-0.3.8 Sun Nov 9 17:58:49 CET 2008
- - fix LC_ALL bug for date (guillomovitch)
- - enforce mandriva summary format policy (guillomovitch)
-
-0.3.7 Sun Aug 10 09:00:43 CEST 2008
- - fix bug 38360: borken changelog generation (shlomi fish)
- - update repository information
-
-0.3.6 Wed Jun 11 12:55:13 CEST 2008
- - don't insert a blank line before description, as per thierry vignaud's request
- - use %buildroot rpm macro instead of env var, as per guillaume's request
- - don't package META.yml file, as per guillaume's request
- - added initial changelog to be imported by mdvsys, as per guillaume's request
-
-0.3.5 Sun Feb 10 18:53:39 CET 2008
- - moving to git
- - using pod::pom::view::text to format description
- . wrapping description to fit in 80 columns
- . removing all pod sequences in it
-
-0.3.4 Fri Dec 21 13:12:52 CET 2007
- - ticket #31693: using rpm command to find rpm topdir
-
-0.3.3 Mon Nov 26 13:57:03 CET 2007
- - fixing typo in default description
- - kwalitee/cpants release
-
-0.3.2 Tue Nov 13 18:09:34 CET 2007
- - checking for Makefile.PL à la Module::Build::Compat
- - fixing build problems
- - enabling tests during rpm creation
-
-0.3.1 Mon Nov 12 18:30:08 CET 2007
- - try to guess build arch
- - module toplevel replaced by a wildcard (for native packages)
-
-0.3.0 Thu Nov 8 19:24:00 CET 2007
- - provide summary in generated specfile + rpm
- - try to provide a description in generated specfile + rpm
-
-**
-
-0.2.2 Wed Nov 7 19:09:50 CET 2007
- - taking guillomovitch's input into account
- - don't provide runtime requirements: rpmbuild will find them
- - restricting file inclusion:
- . prefer specific files instead of system manpage directory
- . including module top level
- - providing full source url for easier updates later on
-
-0.2.1 Mon Nov 5 18:33:13 CET 2007
- - using File::HomeDir instead of computing ourselves $HOME
- - removed YAML usage (was here for debugging purpose)
-
-0.2.0 Sun Nov 4 17:41:46 CET 2007
- - fixing spec-file when missing files detected by rpmbuild
- - rpmbuild now quiet for better output
- - fixing test on windows
- - fixing case where more than one rpm / srpm found
-
-**
-
-0.1.3 Wed Oct 24 18:46:01 CEST 2007
- - reordered calls to makemaker
- - don't rebuild rpm unless needed (or forced)
-
-0.1.2 Sat Oct 20 12:36:16 CEST 2007
- - taking jos boumans' input into account
- - fixing name of spec file (using distname instead of module name)
-
-0.1.1 Fri Oct 19 13:28:02 CEST 2007
- - fixing missing prereqs in build scripts
-
-0.1.0 Thu Oct 18 20:02:52 CEST 2007
- - initial release: format_available, and rough init / prepare / create
- methods
-
+ - forked from cpanplus-dist-mdv
View
12 dist.ini
@@ -1,14 +1,8 @@
-name = CPANPLUS-Dist-Mdv
+name = CPANPLUS-Dist-Mageia
author = Jerome Quelin
license = Perl_5
copyright_holder = Jerome Quelin
-copyright_year = 2007
-
-; -- static meta-information
-[MetaResources]
-homepage = http://search.cpan.org/dist/CPANPLUS-Dist-Mdv/
-repository = http://github.com/jquelin/cpanplus-dist-mdv
-;MailingList =
+copyright_year = 2011
[@JQUELIN]
-major_version = 2
+major_version = 1
View
64 lib/CPANPLUS/Dist/Mdv.pm → lib/CPANPLUS/Dist/Mageia.pm
@@ -2,8 +2,8 @@ use 5.010;
use strict;
use warnings;
-package CPANPLUS::Dist::Mdv;
-# ABSTRACT: a cpanplus backend to build mandriva rpms
+package CPANPLUS::Dist::Mageia;
+# ABSTRACT: a cpanplus backend to build mageia rpms
use base 'CPANPLUS::Dist::Base';
@@ -26,22 +26,22 @@ Readonly my $RPMDIR => do { chomp(my $d=qx[ rpm --eval %_topdir ]); $d; };
# -- class methods
-=method my $bool = CPANPLUS::Dist::Mdv->format_available;
+=method my $bool = CPANPLUS::Dist::Mageia->format_available;
Return a boolean indicating whether or not you can use this package to
create and install modules in your environment.
-It will verify if you are on a mandriva system, and if you have all the
-necessary components avialable to build your own mandriva packages. You
+It will verify if you are on a mageia system, and if you have all the
+necessary components avialable to build your own mageia packages. You
will need at least these dependencies installed: C<rpm>, C<rpmbuild> and
C<gcc>.
=cut
sub format_available {
- # check mandriva release file
- if ( ! -f '/etc/mandriva-release' ) {
- error( 'not on a mandriva system' );
+ # check mageia release file
+ if ( ! -f '/etc/mageia-release' ) {
+ error( 'not on a mageia system' );
return;
}
@@ -58,7 +58,7 @@ sub format_available {
# check prereqs
for my $prog ( qw[ rpm rpmbuild gcc ] ) {
next if can_run($prog);
- error( "'$prog' is a required program to build mandriva packages" );
+ error( "'$prog' is a required program to build mageia packages" );
$flag++;
}
@@ -68,9 +68,9 @@ sub format_available {
# -- public methods
-=method my $bool = $mdv->init;
+=method my $bool = $mga->init;
-Sets up the C<CPANPLUS::Dist::Mdv> object for use. Effectively creates
+Sets up the C<CPANPLUS::Dist::Mageia> object for use. Effectively creates
all the needed status accessors.
Called automatically whenever you create a new C<CPANPLUS::Dist> object.
@@ -84,9 +84,9 @@ sub init {
# distvers: 1.23
# extra_files: qw[ /bin/foo /usr/bin/bar ]
# rpmname: perl-Foo-Bar
- # rpmpath: $RPMDIR/RPMS/noarch/perl-Foo-Bar-1.23-1mdv2008.0.noarch.rpm
+ # rpmpath: $RPMDIR/RPMS/noarch/perl-Foo-Bar-1.23-1mga2008.0.noarch.rpm
# rpmvers: 1
- # srpmpath: $RPMDIR/SRPMS/perl-Foo-Bar-1.23-1mdv2008.0.src.rpm
+ # srpmpath: $RPMDIR/SRPMS/perl-Foo-Bar-1.23-1mga2008.0.src.rpm
# specpath: $RPMDIR/SPECS/perl-Foo-Bar.spec
$status->mk_accessors(qw[ distname distvers extra_files rpmname rpmpath
rpmvers srpmpath specpath ]);
@@ -95,7 +95,7 @@ sub init {
}
-=method my $bool = $mdv->prepare;
+=method my $bool = $mga->prepare;
Prepares a distribution for creation. This means it will create the rpm
spec file needed to build the rpm and source rpm. This will also satisfy
@@ -107,8 +107,8 @@ since it relies on pod parsing to find those information.
Returns true on success and false on failure.
-You may then call C<< $mdv->create >> on the object to create the rpm
-from the spec file, and then C<< $mdv->install >> on the object to
+You may then call C<< $mga->create >> on the object to create the rpm
+from the spec file, and then C<< $mga->install >> on the object to
actually install it.
=cut
@@ -180,7 +180,7 @@ sub prepare {
if ( not $opts{force} ) {
msg( "won't re-spec package since --force isn't in use" );
- # c::d::mdv store
+ # c::d::mga store
$status->rpmpath($pkg); # store the path of rpm
# cpanplus api
$status->prepared(1);
@@ -246,14 +246,14 @@ sub prepare {
}
-=method my $bool = $mdv->create;
+=method my $bool = $mga->create;
Builds the rpm file from the spec file created during the C<create()>
step.
Returns true on success and false on failure.
-You may then call C<< $mdv->install >> on the object to actually install it.
+You may then call C<< $mga->install >> on the object to actually install it.
=cut
@@ -311,7 +311,7 @@ sub create {
my ($srpm) = (sort glob "$RPMDIR/SRPMS/$rpmname-*.src.rpm")[-1];
msg( "rpm created successfully: $rpm" );
msg( "srpm available: $srpm" );
- # c::d::mdv store
+ # c::d::mga store
$status->rpmpath($rpm);
$status->srpmpath($srpm);
# cpanplus api
@@ -322,7 +322,7 @@ sub create {
# unknown error, aborting.
if ( not $buffer =~ /^\s+Installed .but unpackaged. file.s. found:\n(.*)\z/ms ) {
- error( "failed to create mandriva package for '$distname': $buffer" );
+ error( "failed to create mageia package for '$distname': $buffer" );
# cpanplus api
$status->created(0);
return;
@@ -341,7 +341,7 @@ sub create {
}
-=method my $bool = $mdv->install;
+=method my $bool = $mga->install;
Installs the rpm using C<rpm -U>. If run as a non-root user, uses
C<sudo>. This assumes that current user has sudo rights (without
@@ -440,15 +440,15 @@ sub _is_module_build_compat {
# return the absolute path where the template spec will be located.
#
sub _template_spec_file_path {
- my $path = dist_dir('CPANPLUS-Dist-Mdv');
+ my $path = dist_dir('CPANPLUS-Dist-Mageia');
return "$path/template.spec";
}
#
# my $name = _mk_pkg_name($dist);
#
-# given a distribution name, return the name of the mandriva rpm
+# given a distribution name, return the name of the mageia rpm
# package. in most cases, it will be the same, but some pakcage name
# will be too long as a rpm name: we'll have to cut it.
#
@@ -555,13 +555,13 @@ __END__
=head1 SYNOPSYS
- $ cpan2dist --format=CPANPLUS::Dist::Mdv Some::Random::Package
+ $ cpan2dist --format=CPANPLUS::Dist::Mageia Some::Random::Package
=head1 DESCRIPTION
-CPANPLUS::Dist::Mdv is a distribution class to create mandriva packages
+CPANPLUS::Dist::Mageia is a distribution class to create mageia packages
from CPAN modules, and all its dependencies. This allows you to have
the most recent copies of CPAN modules installed, using your package
manager of choice, but without having to wait for central repositories
@@ -571,7 +571,7 @@ You can either install them using the API provided in this package, or
manually via rpm.
Some of the bleading edge CPAN modules have already been turned into
-mandriva packages for you, and you can make use of them by adding the
+mageia packages for you, and you can make use of them by adding the
cooker repositories (main & contrib).
Note that these packages are built automatically from CPAN and are
@@ -611,23 +611,23 @@ You can look for information on this module at:
=item * Search CPAN
-L<http://search.cpan.org/dist/CPANPLUS-Dist-Mdv>
+L<http://search.cpan.org/dist/CPANPLUS-Dist-Mageia>
=item * See open / report bugs
-L<http://rt.cpan.org/NoAuth/Bugs.html?Dist=CPANPLUS-Dist-Mdv>
+L<http://rt.cpan.org/NoAuth/Bugs.html?Dist=CPANPLUS-Dist-Mageia>
=item * Git repository
-L<http://github.com/jquelin/cpanplus-dist-mdv>
+L<http://github.com/jquelin/cpanplus-dist-mageia>
=item * AnnoCPAN: Annotated CPAN documentation
-L<http://annocpan.org/dist/CPANPLUS-Dist-Mdv>
+L<http://annocpan.org/dist/CPANPLUS-Dist-Mageia>
=item * CPAN Ratings
-L<http://cpanratings.perl.org/d/CPANPLUS-Dist-Mdv>
+L<http://cpanratings.perl.org/d/CPANPLUS-Dist-Mageia>
=back
View
4 share/template.spec
@@ -43,5 +43,5 @@ DISTDOC
DISTEXTRA
%changelog
-* DISTDATE cpan2dist DISTVERS-1mdv
-- initial mdv release, generated with cpan2dist
+* DISTDATE cpan2dist DISTVERS-1mga
+- initial mageia release, generated with cpan2dist

0 comments on commit f55339c

Please sign in to comment.