Changeset 32263
- Timestamp:
- 2018-07-11T18:54:06+12:00 (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/trunk/greenstone2/bin/script/gsConvert.pl
r32226 r32263 928 928 sub _get_xpdftools_bindir { 929 929 930 # build up the path to the containing bin dir of the xpdf conversion tool we're going to use 931 my $xpdf_tools_bin = &FileUtils::filenameConcatenate($ENV{'GSDLHOME'}, "bin", $ENV{'GSDLOS'}, "xpdf-tools"); 932 933 if($ENV{'GSDLOS'} =~ m/^windows$/i) { # For Windows, just use the 32 bit xpdf's pdftohtml as it works the same as the 64 bit 934 $xpdf_tools_bin = &FileUtils::filenameConcatenate($xpdf_tools_bin, "bin32"); 935 } else { # unix (linux|darwin), use the bin32/bin64 folder depending on the BITNESS env var 936 937 # Don't use $ENV{'GSDLARCH'}, use the new $ENV{'BITNESS'}, since $ENV{'GSDLARCH'} 938 # isn't always set and has side-effects when it is set: 939 # $ENV{'GSDLARCH'} is only (meant to be) set when many other 32-bit or 64-bit 940 # specific subdirectories exist in a greenstone installation. 941 # None of those locations need exist when xpdf-tools is installed with GS. 942 # So don't depend on GSDLARCH as forcing that to be exported has side-effects 943 if($ENV{'BITNESS'}) { 944 $xpdf_tools_bin = &FileUtils::filenameConcatenate($xpdf_tools_bin, "bin".$ENV{'BITNESS'}); 945 } else { # what if $ENV{'BITNESS'} undefined, fallback on bin32? or 64? 946 $xpdf_tools_bin = &FileUtils::filenameConcatenate($xpdf_tools_bin, "bin32"); 947 } 948 } 949 950 return $xpdf_tools_bin; 930 # build up the path to the containing bin dir of the xpdf conversion tool we're going to use 931 my $xpdf_tools_bin = &FileUtils::filenameConcatenate($ENV{'GSDLHOME'}, "bin", $ENV{'GSDLOS'}, "xpdf-tools", "bin"); 932 return $xpdf_tools_bin; 951 933 } 952 934
Note:
See TracChangeset
for help on using the changeset viewer.