mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-08-28 20:18:08 -07:00
Closes: https://bugs.gentoo.org/713816 Package-Manager: Portage-2.3.89, Repoman-2.3.20 Signed-off-by: Marek Szuba <marecki@gentoo.org>
23 lines
819 B
Diff
23 lines
819 B
Diff
--- a/Build.PL
|
|
+++ b/Build.PL
|
|
@@ -107,11 +107,17 @@
|
|
my $hts_include = $self->config_data('hts_include');
|
|
my $hts_lib = $self->config_data('hts_lib');
|
|
my $static = $self->args('static');
|
|
+
|
|
+ my @env_linker_flags;
|
|
+ if ( defined $ENV{LDFLAGS} ) {
|
|
+ @env_linker_flags = split qr{\s+}, $ENV{LDFLAGS};
|
|
+ }
|
|
+
|
|
$self->include_dirs([$hts_include]);
|
|
if($static){
|
|
- $self->extra_linker_flags("-L$hts_lib", '-lhts', '-lpthread', '-lz');
|
|
+ $self->extra_linker_flags(@env_linker_flags, "-L$hts_lib", '-lhts', '-lpthread', '-lz');
|
|
}else{
|
|
- $self->extra_linker_flags("-L$hts_lib", "-Wl,-rpath,$hts_lib", '-lhts', '-lpthread', '-lz');
|
|
+ $self->extra_linker_flags(@env_linker_flags, "-L$hts_lib", "-Wl,-rpath,$hts_lib", '-lhts', '-lpthread', '-lz');
|
|
}
|
|
}
|
|
|