From f400489385f86f62047994d4a8c60cc1aa9697c6 Mon Sep 17 00:00:00 2001 From: thomas Date: Thu, 19 Dec 2024 14:32:11 +0100 Subject: [PATCH 1/2] usrlocalpkg/admin/makebin: whitespace fixes --- usrlocalpkg/admin/makebin | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/usrlocalpkg/admin/makebin b/usrlocalpkg/admin/makebin index 9e0ef8d..ad89e49 100755 --- a/usrlocalpkg/admin/makebin +++ b/usrlocalpkg/admin/makebin @@ -10,7 +10,7 @@ my $BINDIR = $ENV{MAKEBIN_BINDIR} || '/usr/local/package/bin'; my $LIBDIR = $ENV{MAKEBIN_LIBDIR} || '/usr/local/package/lib'; # files that belong to the wrapper tools and should stay in the BINDIR -my %SACROSANCT = (ptype => 1, pman => 1, prun => 1); +my %SACROSANCT = (ptype => 1, pman => 1, prun => 1); sub WRAPPER { return<<'_EOF_'; @@ -28,7 +28,7 @@ _EOF_ sub tilde_replace { my ($data,$hash)=@_; - $data =~ s/~([^~]*)~/$hash->{$1}/eg; + $data =~ s/~([^~]*)~/$hash->{$1}/eg; return $data; } @@ -250,8 +250,8 @@ sub to_varstring { } sub createWrapper { - my %firstWrapper; - my %firstWrapperInode; + my %firstWrapper; + my %firstWrapperInode; foreach my $wrapper (sort keys %hasPackage) { my $package = $hasPackage{$wrapper}; if (my $oldfile = $firstWrapper{$package}) { From deb84b66455c92500b6cd74b3003f24fcb018119 Mon Sep 17 00:00:00 2001 From: thomas Date: Thu, 19 Dec 2024 14:38:36 +0100 Subject: [PATCH 2/2] usrlocalpkg/admin/makebin: make /etc/mxpkg a variable '/etc/mxpkg' might get disted over whilst testing things, so provide an option for own experiments. + salute a vi :) --- usrlocalpkg/admin/makebin | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/usrlocalpkg/admin/makebin b/usrlocalpkg/admin/makebin index ad89e49..0d156d4 100755 --- a/usrlocalpkg/admin/makebin +++ b/usrlocalpkg/admin/makebin @@ -4,6 +4,7 @@ use warnings; # see /usr/local/package/admin/config for further descriptions +my $MXPKG = $ENV{MAKEBIN_MXPKG} || '/etc/mxpkg'; my $CFG = $ENV{MAKEBIN_CFG} || '/usr/local/package/admin/config'; my $LIBSRC = $ENV{MAKEBIN_LIBSRC} || '/usr/local/package/admin/lib'; my $BINDIR = $ENV{MAKEBIN_BINDIR} || '/usr/local/package/bin'; @@ -34,7 +35,7 @@ sub tilde_replace { sub read_mxpkg { my @ret; - open my $in,'<',"/etc/mxpkg" or die "/etc/.xmpg: $!\n"; + open my $in,'<',$MXPKG or die "$MXPKG: $!\n"; while(<$in>) { s/#.*//; /\S/ or next;