diff --git a/bin/hipcc b/bin/hipcc index 62191ffa4e..42fa1e8a20 100755 --- a/bin/hipcc +++ b/bin/hipcc @@ -28,7 +28,9 @@ use File::Basename; use File::Spec::Functions 'catfile'; # TODO: By default select perl script until change incorporated in HIP build script. -my $HIPCC_USE_PERL_SCRIPT = 1; +my $USE_PERL_SCRIPT = $ENV{'HIP_USE_PERL_SCRIPTS'}; +$USE_PERL_SCRIPT //= 1; # use defined-or assignment operator. Use env var, but if not defined default to 1. + my $isWindows = ($^O eq 'MSWin32' or $^O eq 'msys'); # escapes args with quotes SWDEV-341955 foreach $arg (@ARGV) { @@ -38,8 +40,7 @@ foreach $arg (@ARGV) { } my $SCRIPT_DIR=dirname(__FILE__); - -if ($HIPCC_USE_PERL_SCRIPT) { +if ($USE_PERL_SCRIPT) { #Invoke hipcc.pl my $HIPCC_PERL=catfile($SCRIPT_DIR, '/hipcc.pl'); system($^X, $HIPCC_PERL, @ARGV); diff --git a/bin/hipconfig b/bin/hipconfig index 6bb4f892f8..d50b10b94a 100755 --- a/bin/hipconfig +++ b/bin/hipconfig @@ -28,11 +28,11 @@ use File::Basename; use File::Spec::Functions 'catfile'; #TODO: By default select perl script until change incorporated in HIP build script -my $HIPCONFIG_USE_PERL_SCRIPT = 1; +my $USE_PERL_SCRIPT = $ENV{'HIP_USE_PERL_SCRIPTS'}; +$USE_PERL_SCRIPT //= 1; # use defined-or assignment operator. Use env var, but if not defined default to 1. my $isWindows = ($^O eq 'MSWin32' or $^O eq 'msys'); my $SCRIPT_DIR=dirname(__FILE__); - -if ($HIPCONFIG_USE_PERL_SCRIPT) { +if ($USE_PERL_SCRIPT) { #Invoke hipconfig.pl my $HIPCONFIG_PERL=catfile($SCRIPT_DIR, '/hipconfig.pl'); system($^X, $HIPCONFIG_PERL, @ARGV);