Ticket #476: parrot-1.0.0-norpath.diff

File parrot-1.0.0-norpath.diff, 3.7 KB (added by JSchmitt, 6 years ago)

Patch to implement a --disable-rpath option

  • config/gen/makefiles/json.in

    old new  
    99PGE_DIR  := ../../compilers/pge 
    1010TGE_DIR  := ../../compilers/tge 
    1111 
     12export LD_LIBRARY_PATH := ../../blib/lib 
     13 
    1214# the default target 
    1315all: JSON.pbc 
    1416 
  • config/gen/makefiles/nqp.in

    old new  
    99PARROT_LIBRARY := @build_dir@/runtime/parrot/library 
    1010PGE_LIBRARY    := @build_dir@/runtime/parrot/library/PGE 
    1111 
     12export LD_LIBRARY_PATH := ../../blib/lib 
     13 
    1214all: nqp.pbc 
    1315 
    1416SOURCES := \ 
  • config/gen/makefiles/pct.in

    old new  
    1111PGE_DIR  := ../../compilers/pge 
    1212TEST_DIR := ../../t/compilers/pct 
    1313 
     14export LD_LIBRARY_PATH := ../../blib/lib 
     15 
    1416# Where to put things 
    1517PARROT_LIBRARY := ../../runtime/parrot/library 
    1618 
  • config/gen/makefiles/pge.in

    old new  
    99 
    1010TOOL_DIR := ../.. 
    1111 
     12export LD_LIBRARY_PATH := ../../blib/lib 
     13 
    1214# Where to put things 
    1315PARROT_LIBRARY := ../../runtime/parrot/library 
    1416 
  • config/gen/makefiles/root.in

    old new  
    534534.pbc$(O) : # suffix rule (limited support) 
    535535        $(PARROT) -o $@ $< 
    536536 
     537# This sets up proper internal dynamic linking in case we don't set an rpath 
     538export LD_LIBRARY_PATH = $(CUR_DIR)/blib/lib 
    537539 
    538540############################################################################### 
    539541# 
     
    750752 
    751753runtime/parrot/include/config.fpmc : myconfig config_lib.pasm $(MINIPARROT) 
    752754        @echo Invoking Parrot to generate runtime/parrot/include/config.fpmc --cross your fingers 
    753         $(MINIPARROT) config_lib.pasm > $@ 
     755        LD_LIBRARY_PATH=$(CUR_DIR)/blib/lib $(MINIPARROT) config_lib.pasm > $@ 
    754756 
    755757$(PARROT) : $(SRC_DIR)/main$(O) $(GEN_HEADERS) $(LIBPARROT) CFLAGS \ 
    756758    lib/Parrot/OpLib/core.pm $(SRC_DIR)/parrot_config$(O) \ 
  • config/gen/makefiles/tge.in

    old new  
    66RM_F     := @rm_f@ 
    77PARROT   := ../../parrot@exe@ 
    88 
     9export LD_LIBRARY_PATH := ../../blib/lib 
     10 
    911# Where to put things 
    1012PARROT_LIBRARY    := ../../runtime/parrot/library 
    1113PERL6GRAMMAR      := $(PARROT_LIBRARY)/PGE/Perl6Grammar.pbc 
  • config/inter/libparrot.pm

    old new  
    3434sub runstep { 
    3535    my ( $self, $conf ) = @_; 
    3636    my $parrot_is_shared = $conf->options->get('parrot_is_shared'); 
     37    my $site_install = $conf->options->get('disable-rpath'); 
    3738 
    3839    $parrot_is_shared = integrate( 
    3940        $conf->data->get('parrot_is_shared'), 
     
    9899    # Set -rpath (or equivalent) for executables to find the 
    99100    # shared libparrot in the build directory. 
    100101    $conf->data->set( 
    101         rpath_blib => ( $parrot_is_shared && $conf->data->get('rpath') ) 
     102        rpath_blib => ( $parrot_is_shared && $conf->data->get('rpath')  
     103                        && !$site_install ) 
    102104        ? $conf->data->get('rpath') 
    103105            . $conf->data->get('build_dir') 
    104106            . $conf->data->get('slash') 
     
    109111    # Set -rpath (or equivalent) for the installed executables to find the 
    110112    # installed shared libparrot. 
    111113    $conf->data->set( 
    112         rpath_lib => ( $parrot_is_shared && $conf->data->get('rpath') ) 
     114        rpath_lib => ( $parrot_is_shared && $conf->data->get('rpath') 
     115                       && !$site_install ) 
    113116        ? $conf->data->get('rpath') 
    114117            . $conf->data->get('libdir') 
    115118        : '' 
  • lib/Parrot/Configure/Options/Conf/Shared.pm

    old new  
    6262    sbindir 
    6363    sharedstatedir 
    6464    silent 
     65    disable-rpath 
    6566    sysconfdir 
    6667    test 
    6768    verbose