Skip to content

Commit

Permalink
use env's CFLAGS and LDFLAGS if set, fixes #182
Browse files Browse the repository at this point in the history
  • Loading branch information
FROGGS committed Mar 11, 2015
1 parent b5b5435 commit 0939358
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Configure.pl
Original file line number Diff line number Diff line change
Expand Up @@ -305,6 +305,7 @@
push @cflags, $config{ccdefflags};
push @cflags, $config{ccshared} unless $args{static};
push @cflags, '-fno-omit-frame-pointer -fsanitize=address' if $args{asan};
push @cflags, $ENV{CFLAGS} if $ENV{CFLAGS};
$config{cflags} = join ' ', @cflags;

# generate LDFLAGS
Expand All @@ -314,6 +315,7 @@
push @ldflags, $config{ldinstflags} if $args{instrument};
push @ldflags, $config{ldrpath} unless $args{static};
push @ldflags, $^O eq 'darwin' ? '-faddress-sanitizer' : '-fsanitize=address' if $args{asan};
push @ldflags, $ENV{LDFLAGS} if $ENV{LDFLAGS};
$config{ldflags} = join ' ', @ldflags;

# setup library names
Expand Down

0 comments on commit 0939358

Please sign in to comment.