tpkg 1.21.0 → 1.21.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/Rakefile +1 -1
- data/bin/cpan2tpkg +19 -13
- data/lib/tpkg.rb +2 -2
- metadata +15 -15
data/Rakefile
CHANGED
@@ -5,7 +5,7 @@ spec = Gem::Specification.new do |s|
|
|
5
5
|
s.add_dependency('facter')
|
6
6
|
s.add_dependency('net-ssh')
|
7
7
|
s.add_dependency('ddao-kwalify')
|
8
|
-
s.version = '1.21.
|
8
|
+
s.version = '1.21.1'
|
9
9
|
s.authors = ['Darren Dao', 'Jason Heiss']
|
10
10
|
s.email = 'tpkg-users@lists.sourceforge.net'
|
11
11
|
s.homepage = 'http://tpkg.sourceforge.net'
|
data/bin/cpan2tpkg
CHANGED
@@ -131,8 +131,13 @@ CPAN::Shell->o('conf', 'makepl_arg', "DESTDIR=$workdir");
|
|
131
131
|
# http://perldoc.perl.org/Module/Build.html#INSTALL-PATHS
|
132
132
|
CPAN::Shell->o('conf', 'mbuildpl_arg', "--destdir=$workdir");
|
133
133
|
|
134
|
-
#
|
135
|
-
|
134
|
+
# Automatically install dependencies so that we can package them too
|
135
|
+
CPAN::Shell->o('conf', 'prerequisites_policy', "follow");
|
136
|
+
|
137
|
+
# In order for cpan2tpkg to be able to install and package dependencies of the
|
138
|
+
# user's module we need perl to be able to find modules installed in our
|
139
|
+
# working directory.
|
140
|
+
$ENV{PERL5LIB} = File::Spec->catdir($workdir, $Config{sitelib});
|
136
141
|
|
137
142
|
# Install the module
|
138
143
|
if ($force)
|
@@ -141,7 +146,7 @@ if ($force)
|
|
141
146
|
}
|
142
147
|
else
|
143
148
|
{
|
144
|
-
|
149
|
+
CPAN::Shell->install($module);
|
145
150
|
}
|
146
151
|
|
147
152
|
# It is not nearly as straightforward as one might wish to get
|
@@ -150,7 +155,7 @@ else
|
|
150
155
|
# system directories from $Config, any directories in the PERL5LIB environment
|
151
156
|
# variable, and any extra directories you pass it. You can work around the
|
152
157
|
# system directories from $Config by passing EU::I your own modified $Config
|
153
|
-
# via the config_override parameter.
|
158
|
+
# via the config_override parameter. We override $ENV{PERL5LIB} above.
|
154
159
|
# And that just leaves it searching the extra directories you pass it via the
|
155
160
|
# extra_libs parameter. To further complicate matters EU::I searches the
|
156
161
|
# directories in @INC when asked for the version of an installed module, but
|
@@ -167,8 +172,6 @@ foreach my $incdir (@INC)
|
|
167
172
|
my %myconfig = %{dclone(\%Config)};
|
168
173
|
$myconfig{archlibexp} = File::Spec->catdir($workdir, $Config{archlibexp});
|
169
174
|
$myconfig{sitearchexp} = File::Spec->catdir($workdir, $Config{sitearchexp});
|
170
|
-
# EU::I searches PERL5LIB as well, so clear that out
|
171
|
-
$ENV{PERL5LIB} = '';
|
172
175
|
my $extinst = ExtUtils::Installed->new(
|
173
176
|
config_override=>\%myconfig,
|
174
177
|
inc_override=>\@incwork,
|
@@ -187,8 +190,8 @@ MODULE: foreach my $name ($extinst->modules)
|
|
187
190
|
# Sometimes calling expand on a result from EU::I->modules doesn't
|
188
191
|
# work. For example, if the user requests Date::Parse that module
|
189
192
|
# is part of the TimeDate distribution. EU::I->modules will return
|
190
|
-
# ['Perl', 'TimeDate'], but calling expand on TimeDate fails.
|
191
|
-
#
|
193
|
+
# ['Perl', 'TimeDate'], but calling expand on TimeDate fails.
|
194
|
+
# FIXME: We should find an alternative to EU::I->modules,
|
192
195
|
# something that returns the distributions installed rather than the
|
193
196
|
# modules.
|
194
197
|
if (!$mod)
|
@@ -258,11 +261,14 @@ MODULE: foreach my $name ($extinst->modules)
|
|
258
261
|
# This is a bit of an indirect way to identify core modules
|
259
262
|
# but the only way I can figure out. Core stuff gets
|
260
263
|
# installed with perl into /home/t/perl-version, CPAN
|
261
|
-
# modules into /home/t/lib/perl5/site_perl.
|
262
|
-
#
|
263
|
-
#
|
264
|
-
#
|
265
|
-
|
264
|
+
# modules into /home/t/lib/perl5/site_perl.
|
265
|
+
#
|
266
|
+
# What seems like it should be the "right" way is that the "D"
|
267
|
+
# (aka "Development Stage") field in dslip_status has "S" (aka
|
268
|
+
# "Standard, supplied with Perl 5") as one of its possible values,
|
269
|
+
# according to the docs (http://perldoc.perl.org/CPAN.html).
|
270
|
+
# However, that doesn't seem to be set reliably.
|
271
|
+
if ($depmod->inst_file && $depmod->inst_file =~ /$Config{prefix}/)
|
266
272
|
{
|
267
273
|
print "Prereq $dep is a core module, skipping\n";
|
268
274
|
next PREREQ;
|
data/lib/tpkg.rb
CHANGED
@@ -56,7 +56,7 @@ require 'kwalify' # for validating yaml
|
|
56
56
|
|
57
57
|
class Tpkg
|
58
58
|
|
59
|
-
VERSION = '1.21.
|
59
|
+
VERSION = '1.21.1'
|
60
60
|
CONFIGDIR = '/etc'
|
61
61
|
|
62
62
|
GENERIC_ERR = 1
|
@@ -3809,7 +3809,7 @@ class Tpkg
|
|
3809
3809
|
# log changes
|
3810
3810
|
currently_installed = metadata_for_installed_packages.collect{|metadata| metadata.to_hash}
|
3811
3811
|
newly_installed = currently_installed - already_installed_pkgs
|
3812
|
-
removed = already_installed_pkgs - currently_installed
|
3812
|
+
removed = already_installed_pkgs - currently_installed
|
3813
3813
|
log_changes({:newly_installed => newly_installed, :removed => removed})
|
3814
3814
|
|
3815
3815
|
# send update back to reporting server
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tpkg
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.21.
|
4
|
+
version: 1.21.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Darren Dao
|
@@ -10,7 +10,7 @@ autorequire:
|
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
12
|
|
13
|
-
date: 2010-03-
|
13
|
+
date: 2010-03-17 00:00:00 -07:00
|
14
14
|
default_executable:
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
@@ -55,24 +55,24 @@ extensions: []
|
|
55
55
|
extra_rdoc_files: []
|
56
56
|
|
57
57
|
files:
|
58
|
+
- bin/cpan2tpkg
|
59
|
+
- bin/tpkg_xml_to_yml
|
60
|
+
- bin/tpkg
|
61
|
+
- bin/gem2tpkg
|
62
|
+
- schema/tpkg.dtd
|
63
|
+
- schema/schema-1.0.yml
|
64
|
+
- schema/tpkg-1.0.0.dtd
|
65
|
+
- schema/tpkg-1.0.4.dtd
|
66
|
+
- schema/tpkg-1.0.3.dtd
|
67
|
+
- schema/schema.yml
|
68
|
+
- schema/tpkg-1.0.5.dtd
|
69
|
+
- schema/tpkg-1.0.2.dtd
|
70
|
+
- schema/tpkg-1.0.1.dtd
|
58
71
|
- lib/tpkg/versiontype.rb
|
59
72
|
- lib/tpkg/deployer.rb
|
60
73
|
- lib/tpkg/thread_pool.rb
|
61
74
|
- lib/tpkg/metadata.rb
|
62
75
|
- lib/tpkg.rb
|
63
|
-
- schema/tpkg-1.0.4.dtd
|
64
|
-
- schema/tpkg-1.0.0.dtd
|
65
|
-
- schema/tpkg-1.0.5.dtd
|
66
|
-
- schema/tpkg.dtd
|
67
|
-
- schema/tpkg-1.0.1.dtd
|
68
|
-
- schema/tpkg-1.0.3.dtd
|
69
|
-
- schema/schema.yml
|
70
|
-
- schema/tpkg-1.0.2.dtd
|
71
|
-
- schema/schema-1.0.yml
|
72
|
-
- bin/tpkg
|
73
|
-
- bin/cpan2tpkg
|
74
|
-
- bin/gem2tpkg
|
75
|
-
- bin/tpkg_xml_to_yml
|
76
76
|
- Rakefile
|
77
77
|
has_rdoc: true
|
78
78
|
homepage: http://tpkg.sourceforge.net
|