Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re^3: What is the format of a .packlist file for a PPM repository?

by randyk (Parson)
on Oct 18, 2007 at 16:17 UTC ( #645767=note: print w/ replies, xml ) Need Help??


in reply to Re^2: What is the format of a .packlist file for a PPM repository?
in thread What is the format of a .packlist file for a PPM repository?

The messages from ppm:

Synchronizing Database ... done
Downloading Dubious packlist ... not found
Downloading Dubious packlist ... not found
Downloading Dubious packlist ... done
Synchronizing Database ... done
are perhaps misleading; ppm is looking for either a package.lst or a package.xml file, not a literal "packlist" file. If it doesn't find either of these summary files, it will fetch and parse the ppd files within this directory, if there are any. The summary files are just there to save ppm downloading and parsing individual ppd files.

Try making a local repository and populating it with some ppd files, and the corresponding .tar.gz or .zip archives referenced in the CODEBASE element, and see if that works. You can use the rep_summary script of PPM-Make to generate the summary files, or alternatively, run the following script:

use strict; use warnings; use File::Spec; my $ppm_dir = 'C:\Temp\ppms'; opendir(my $dir, $ppm_dir) or die qq{Cannot opendir $ppm_dir: $!}; my @ppds = grep /\.ppd$/, readdir $dir; closedir $dir; my $pack = File::Spec->catfile($ppm_dir, 'package.lst'); open(my $pack_fh, '>', $pack) or die qq{Cannot open $pack for writing: $!}; print $pack_fh <<"END"; <?xml version="1.0" encoding="UTF-8"?> <REPOSITORYSUMMARY> END for my $ppd (@ppds) { open(my $ppd_fh, File::Spec->catfile($ppm_dir, $ppd)) or die qq{Cannot read $ppd under $ppm_dir: $!}; while (<$ppd_fh>) { next if $_ =~ /\?xml version/; print $pack_fh " $_"; } close $ppd_fh; } print $pack_fh qq{</REPOSITORYSUMMARY>\n}; close $pack_fh;
to generate the package.lst file; the directory of the repository in this script is specified as $ppm_dir.


Comment on Re^3: What is the format of a .packlist file for a PPM repository?
Download Code
Re^4: What is the format of a .packlist file for a PPM repository?
by LittleGreyCat (Scribe) on Oct 21, 2007 at 17:56 UTC
    "The messages from ppm are perhaps misleading; ppm is looking for either a package.lst or a package.xml file, not a literal "packlist" file. If it doesn't find either of these summary files, it will fetch and parse the ppd files within this directory, if there are any. The summary files are just there to save ppm downloading and parsing individual ppd files. Try making a local repository and populating it with some ppd files, and the corresponding .tar.gz or .zip archives referenced in the CODEBASE element, and see if that works."

    This is what is confusing me.
    I have a fully populated local PPM repository which works fine with the command line version of 'ppm' (in my 817 install).
    When I point the 822 GUI at the same repository it does not appear to find anything to add to the list of packages waiting to be installed.

    I may not be driving the GUI correctly but I expected all the packages in the PPM repository to be shown in the list of packages available to be installed.

    Is it perhaps like the command line 'ppm' where you have to search on key words before anything appears?

    Nothing succeeds like a budgie with no teeth.
      Quick follow up:

      I installed 5.8.8 822 on a clean (XP) system connected to the Internet and ran the PPM GUI

      I was presented with a long list of packages available - 6949 - and the names.

      As a test I installed perl-ldap and this seemed to go O.K.

      I then added my local PPM repository (across a LAN) and disabled the default PPM repository.

      Although PPM spent a long time reading the repository across the LAN at the end it did not list any packages available.

      So it seems that I am not mis-understanding the GUI; when connected across the Internet to the default PPM repository I get the expected results. When connected to my local PPM repository there are indications that PPM has searched the repository and is aware of what is in it. It just doesn't seem to list them in the 'All Packages' area nor in the summary line at the bottom.

      Nothing succeeds like a budgie with no teeth.
        Adding a local repository in 822 works OK for me with the GUI. Might there be some firewall, proxy, or permission issues?
Re^4: What is the format of a .packlist file for a PPM repository?
by LittleGreyCat (Scribe) on Oct 24, 2007 at 15:26 UTC
    Just ran the code you supplied and I now have a 'package.lst' file.

    The repository is now working, although I am tracking down a few unusual aspects, such as why none of my statistics add up.

    I have:

    13520 '.ppd' files
    13517 instances of the "<SOFTPKG" string within ".ppd" files
    13402 packages known to PPM (as declared on the bottom line of the GUI)
    6088 filtered packages listed with the "Show All" filter (!)

    I am a lot further along and a lot happier, but there are obviously still a few unaswered questions!

    Nothing succeeds like a budgie with no teeth.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://645767]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (6)
As of 2014-10-26 03:57 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    For retirement, I am banking on:










    Results (151 votes), past polls