source: gsdl/trunk/setup.bat@ 17948

Last change on this file since 17948 was 17948, checked in by max, 15 years ago

Do not need to be run from the directory in which it resides anymore (necesarry for Vista elevation). Show green logo.

File size: 4.6 KB
RevLine 
[14843]1@echo off
[17948]2pushd "%CD%"
3CD /D "%~dp0"
[7020]4set GSDLLANG=en
[6764]5
[17948]6echo.
7echo.
8echo #### #
9echo ## #
10echo # ### ## ## ### ### ### ## ### ##
11echo # # # #### #### # # ## # # # # # ####
12echo ## # # # # # # # # # # # # #
13echo #### # ### ### # # ### ## ## # # ###
14echo (C) 2008, New Zealand Digital Library Project
15echo.
16echo.
17echo.
18
[3041]19if "%OS%" == "Windows_NT" goto WinNT
20if "%OS%" == "" goto Win95
[7020]21if "%GSDLLANG%" == "en" echo Setup failed - your PATH has not been set
22if "%GSDLLANG%" == "es" echo No se pudo realizar la configuraci¢n - no se ha establecido la RUTA.
23if "%GSDLLANG%" == "fr" echo Ech‚c de l'installation - votre variable PATH n'a pas ‚t‚ ajust‚e
24if "%GSDLLANG%" == "ru" echo “áâ ­®¢ª  ­¥ 〠« áì - “’œ ­¥ ¡ë« ãáâ ­®¢«¥­
[3041]25goto End
26
[17305]27:WinNT
[17948]28set GSDLHOME=%CD%
[3403]29set GSDLOS=windows
[17226]30
31REM Override Imagemagick and Ghostscript paths to the bundled applications shipped with greenstone if they exists otherwise use default environment variables.
32if exist "%GSDLHOME%\bin\windows\ghostscript\bin\gsdll32.dll" set GS_DLL=%GSDLHOME%\bin\windows\ghostscript\bin\gsdll32.dll
33if exist "%GSDLHOME%\bin\windows\ghostscript\lib\*.*" set GS_LIB=%GSDLHOME%\bin\windows\ghostscript\lib
34if exist "%GSDLHOME%\bin\windows\ghostscript\bin\*.*" set PATH=%GSDLHOME%\bin\windows\ghostscript\bin;%PATH%
35if exist "%GSDLHOME%\bin\windows\imagemagick\*.*" set PATH=%GSDLHOME%\bin\windows\imagemagick;%PATH%
36
[17305]37if "%GS_CP_SET%" == "yes" goto Success
[17226]38set PATH=%GSDLHOME%\bin\windows\perl\bin;%GSDLHOME%\bin\windows;%GSDLHOME%\bin\script;%PATH%
[17305]39set GS_CP_SET=yes
[3041]40goto Success
41
42:Win95
[3403]43if "%1" == "SetEnv" goto Win95Env
44REM We'll invoke a second copy of the command processor to make
45REM sure there's enough environment space
[3809]46COMMAND /E:2048 /K %0 SetEnv
[3403]47goto End
48
49:Win95Env
[17948]50set GSDLHOME=%CD%
[3403]51set GSDLOS=windows
[17226]52
53REM Override Imagemagick and Ghostscript paths to the bundled applications shipped with greenstone if they exists otherwise use default environment variables.
54if exist "%GSDLHOME%\bin\windows\ghostscript\bin\gsdll32.dll" set GS_DLL="%GSDLHOME%\bin\windows\ghostscript\bin\gsdll32.dll"
55if exist "%GSDLHOME%\bin\windows\ghostscript\lib\*.*" set GS_LIB="%GSDLHOME%\bin\windows\ghostscript\lib"
56if exist "%GSDLHOME%\bin\windows\ghostscript\bin\*.*" set PATH="%GSDLHOME%\bin\windows\ghostscript\bin";"%PATH%"
57if exist "%GSDLHOME%\bin\windows\imagemagick\*.*" set PATH="%GSDLHOME%\bin\windows\imagemagick";"%PATH%"
[17305]58
59if "%GS_CP_SET%" == "yes" goto Success
[17226]60set PATH="%GSDLHOME%\bin\windows\perl\bin";"%GSDLHOME%\bin\windows";"%GSDLHOME%\bin\script";"%PATH%"
[17305]61set GS_CP_SET=yes
[14843]62goto Success
[3041]63
[14843]64
[3041]65:Success
[17909]66if "%GSDLLANG%" == "en" echo.
[7020]67if "%GSDLLANG%" == "en" echo Your environment has successfully been set up to run Greenstone.
68if "%GSDLLANG%" == "en" echo Note that these settings will only have effect within this MS-DOS
69if "%GSDLLANG%" == "en" echo session. You will therefore need to rerun setup.bat if you want
70if "%GSDLLANG%" == "en" echo to run Greenstone programs from a different MS-DOS session.
[17909]71if "%GSDLLANG%" == "en" echo.
[3041]72
[17909]73if "%GSDLLANG%" == "es" echo.
[7020]74if "%GSDLLANG%" == "es" echo Su ambiente ha sido configurado para correr los programas Greenstone.
75if "%GSDLLANG%" == "es" echo Recuerde que estos ajustes £nicamente tendr n efecto dentro de esta sesi¢n
76if "%GSDLLANG%" == "es" echo MS-DOS. Por lo tanto deber  ejecutar nuevamente setup.bat si desea
77if "%GSDLLANG%" == "es" echo correr los programas de Greenstone desde una sesi¢n MS-DOS diferente.
[17909]78if "%GSDLLANG%" == "es" echo.
[6765]79
[17909]80if "%GSDLLANG%" == "fr" echo.
[7020]81if "%GSDLLANG%" == "fr" echo Votre environnement a ‚t‚ configu‚re avec succŠs pour ex‚cuter Greenstone
82if "%GSDLLANG%" == "fr" echo Notez que ces paramŠtrages n'auront d'effet que dans cette session MS-DOS.
83if "%GSDLLANG%" == "fr" echo Vous devrez par cons‚quent r‚ex‚cuter setup.bat si vous voulez faire
84if "%GSDLLANG%" == "fr" echo lancer des programmes Greenstone dans une autre session MS-DOS.
[17909]85if "%GSDLLANG%" == "fr" echo.
[6764]86
[17909]87if "%GSDLLANG%" == "ru" echo.
[7020]88if "%GSDLLANG%" == "ru" echo ‚ è¥ ®ªà㊥­š¥ ¡ë«® ãᯥ譮 ­ áâ஥­®, ç⮡ë ãáâ ­®¢šâì Greenstone Ž¡à âšâ¥
89if "%GSDLLANG%" == "ru" echo ¢­š¬ ­š¥, çâ® íâš ­ §­ ç¥­šï ¡ã€ãâ ⮫쪮 š¬¥âì íä䥪⠢ ¯à¥€¥« å í⮣® MS DOS
90if "%GSDLLANG%" == "ru" echo á¥áášï. ‚ë ¡ã€¥â¥ ¯®í⮬㠀®«Š­ë ¯®¢â®à­® ã¯à ¢«ïâì setup.bat, ¥á«š ‚ë å®âšâ¥
91if "%GSDLLANG%" == "ru" echo ã¯à ¢«ïâì ¯à®£à ¬¬ ¬š ‡¥«ñ­ëå š§¢¥àŠ¥­­ëå ¯®à®€ ®â à §«šç­®© á¥áášš MS DOS.
[17909]92if "%GSDLLANG%" == "ru" echo.
[6766]93
[3041]94:End
[14843]95
96:: test writability of GSDLHOME
97@call "%GSDLHOME%\bin\script\checkwritability.bat"
[17948]98popd
Note: See TracBrowser for help on using the repository browser.