Hello wise monks,
I created some par packed executables with the command line tool "pp" as follows in a MSWin32 environment:
pp -a "additional_stuff" -o hello_world.exe hello_world.pl
Now I noticed that inside the "hello_world.exe" there are a lot of files which I want to get rid of.
That's why I wrote the following script:
#!/usr/bin/perl use strict; use warnings; use Archive::Zip qw( :ERROR_CODES ); my $zip_name = 'hello_world.exe'; my $zip = Archive::Zip->new( $zip_name ); die "ERROR: Could not open \"$zip_name\"!!!" unless defined $zip; my @metadata_file_members = $zip->membersMatching( '\.metadata' ); $zip->removeMember($_) for ( @metadata_file_members ); $zip->overwrite();
The updated "hello_world.exe" now does NOT contain the .metadata files I wanted to get rid of. So this works fine. But now I have the problem that I have a normal zip file and not a self extracting file as before.
I looked into the examples of Archive::Zip and found "selfex.pl". Here I got the idea of how it could be done. But to be honest I have no plan how to create the par packed executable as it was before.
I've seen in the "script/main.pl" file within the par packed executable that this code could be the right place to look. But as said before I don't know how to create exactly such a self extracting executable as it was before.
Main question: How can I remove some files from a par packed executable?
Thank you a lot for you help.
Greetings,
Dirk
In reply to Update par packer executable by Dirk80
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |