Changeset 3905

Show
Ignore:
Timestamp:
05/26/05 11:57:51 (4 years ago)
Author:
rgs
svk:copy_cache_prev:
5482
Message:

* Fix linking with embedding perl 5 against shared libperl.so (at least on

Linux) by adding -optl $Config{ccdlflags} to the ghc command-line

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • Makefile.PL

    r3903 r3905  
    123123    my $embed_flags = ""; 
    124124    my $hsc2hs_flags = ""; 
     125    my $ccdlflags = ""; 
    125126 
    126127    if ($ENV{PUGS_EMBED} and $ENV{PUGS_EMBED} =~ /\bperl5\b/i) { 
     
    128129        $ghc_output .= " src/perl5/perl5.o "; 
    129130        $ghc_flags .= " -DPUGS_HAVE_PERL5 "; 
     131        $ccdlflags .= " -optl $Config{ccdlflags} "; 
    130132    } 
    131133    else { 
     
    248250 
    249251profiled :: src/Pugs/Config.hs @srcfiles $version_h @prereqs 
    250         $ghc $threaded -O -auto-all -prof --make $profiled_flags $ghc_output 
     252        $ghc $threaded -O -auto-all -prof --make $profiled_flags $ccdlflags $ghc_output 
    251253 
    252254pugs.prof :: profiled 
     
    256258 
    257259optimized :: src/Pugs/Config.hs @srcfiles $version_h @prereqs 
    258         $ghc $threaded -O --make $ghc_flags $embed_flags $ghc_output 
     260        $ghc $threaded -O --make $ghc_flags $embed_flags $ccdlflags $ghc_output 
    259261 
    260262unoptimised :: unoptimized 
    261263 
    262264unoptimized :: src/Pugs/Config.hs @srcfiles $version_h @prereqs 
    263         $ghc $threaded -O0 --make $ghc_flags $embed_flags $ghc_output 
     265        $ghc $threaded -O0 --make $ghc_flags $embed_flags $ccdlflags $ghc_output 
    264266 
    265267$pugs : src/Pugs/Config.hs @srcfiles $version_h @prereqs 
    266         $ghc $threaded -O --make $ghc_flags $embed_flags $ghc_output 
     268        $ghc $threaded -O --make $ghc_flags $embed_flags $ccdlflags $ghc_output 
    267269 
    268270smoke : $pugs util/run-smoke.pl