Changeset 2834
- Timestamp:
- 2001-11-21T10:46:35+13:00 (22 years ago)
- Location:
- trunk/is_gsdl_cdrom
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/is_gsdl_cdrom/Greenstone Digital Library Software.ipr
r2827 r2834 7 7 [Data] 8 8 CurrentMedia=default 9 set_mifserial= 10 ProductName=Greenstone Digital Library Software 9 11 CurrentComponentDef=Default.cdf 10 ProductName=Greenstone Digital Library Software 11 set_mifserial=12 set_dlldebug=No 13 AppExe= 12 14 DevEnvironment=Microsoft Visual C++ 13 AppExe= 14 set_dlldebug=No 15 set_mif=No 16 set_testmode=No 17 Instructions=Instructions.txt 15 18 EmailAddresss= 16 Instructions=Instructions.txt17 set_testmode=No18 set_mif=No19 19 SummaryText= 20 20 Department= 21 Type=Internet Application 22 Author= 21 23 HomeURL= 22 Author=23 Type=Internet Application24 24 InstallRoot=C:\My Installations\is_gsdl_cdrom 25 set_level=Level 3 26 InstallationGUID=4c986880-d387-11d5-840f-a0c20cc10000 25 27 Version=2.37.000 26 InstallationGUID=4c986880-d387-11d5-840f-a0c20cc10000 27 set_level=Level 3 28 set_miffile=Status.mif 29 set_args= 30 set_maxerr=50 31 Notes=Notes.txt 28 32 CurrentFileGroupDef=Default.fdf 29 Notes=Notes.txt30 set_maxerr=5031 set_args=32 set_miffile=Status.mif33 33 set_dllcmdline= 34 set_warnaserr=No 34 35 Copyright= 35 set_warnaserr=No 36 set_preproc= 37 Category= 36 38 CurrentPlatform= 37 Category= 38 set_preproc= 39 set_compileb4build=No 40 set_crc=Yes 41 set_maxwarn=50 42 Description=Description.txt 43 CompanyName=New Zealand Digital Library Project 39 44 CurrentLanguage=English 40 CompanyName=New Zealand Digital Library Project41 Description=Description.txt42 set_maxwarn=5043 set_crc=Yes44 set_compileb4build=No45 45 46 46 [MediaInfo] -
trunk/is_gsdl_cdrom/Script Files/setup.rul
r2832 r2834 71 71 prototype rs(BYREF STRING); 72 72 prototype InstallCollOrganizer(); 73 prototype SetPermissions(); 73 74 74 75 // ----- global variables ------ … … 86 87 BOOL bCompact; 87 88 STRING svAdminPassword, svLogFile; 89 90 91 // for _LaunchAppEx function 92 #ifndef STILL_ACTIVE 93 #define STILL_ACTIVE 0x00000103 94 #endif 95 #if _ISCRIPT_VER < 0x600 96 #ifndef BYVAL 97 #define BYVAL 98 #endif 99 #endif 100 prototype _LaunchAppEx(STRING, STRING, NUMBER, NUMBER, NUMBER, BYREF NUMBER); 101 prototype BOOL kernel32.CreateProcessA(POINTER, BYVAL STRING, POINTER, 102 POINTER, BOOL, NUMBER, POINTER, POINTER, POINTER, 103 POINTER); 104 prototype BOOL kernel32.GetExitCodeProcess(NUMBER, POINTER); 105 prototype NUMBER kernel32.WaitForSingleObject(NUMBER, NUMBER); 106 prototype BOOL kernel32.CloseHandle(HWND); 107 typedef STARTUPINFO 108 begin 109 NUMBER cb; 110 POINTER lpReserved; 111 POINTER lpDesktop; 112 POINTER lpTitle; 113 NUMBER dwX; 114 NUMBER dwY; 115 NUMBER dwXSize; 116 NUMBER dwYSize; 117 NUMBER dwXCountChars; 118 NUMBER dwYCountChars; 119 NUMBER dwFillAttribute; 120 NUMBER dwFlags; 121 NUMBER wShowWindow; 122 POINTER lpReserved2; 123 HWND hStdInput; 124 HWND hStdOutput; 125 HWND hStdError; 126 end; 127 typedef PROCESS_INFORMATION 128 begin 129 NUMBER hProcess; 130 HWND hThread; 131 NUMBER dwProcessId; 132 NUMBER dwThreadId; 133 end; 134 88 135 89 136 /////////////////////////////////////////////////////////////////////////////// … … 302 349 EditSetupBat(); 303 350 SetAdminPassword(); 351 SetPermissions(); 304 352 305 353 szReferenceFile = svDir ^ @PRODUCT_KEY; … … 958 1006 end; 959 1007 1008 1009 // if running NT/2000 we need to make the collect and tmp 1010 // directories and some contents of the etc directory writable 1011 // by all users (otherwise certain functions will only work 1012 // if Greenstone is run by someone with admin privileges) 1013 function SetPermissions() 1014 STRING szProgram, szCmdLine; 1015 NUMBER nvExitCode; 1016 1017 begin 1018 1019 if (bWinNT) then 1020 1021 szProgram = WINSYSDIR ^ "cmd.exe"; 1022 1023 szCmdLine = "/c cacls \"" + TARGETDIR ^ "tmp\" /T /E /G Everyone:F"; 1024 _LaunchAppEx(szProgram, szCmdLine, WAIT, SW_HIDE, 5000, nvExitCode); 1025 1026 szCmdLine = "/c cacls \"" + TARGETDIR ^ "collect\" /T /E /G Everyone:F"; 1027 _LaunchAppEx(szProgram, szCmdLine, WAIT, SW_HIDE, 5000, nvExitCode); 1028 1029 szCmdLine = "/c cacls \"" + TARGETDIR ^ "etc" ^ "errout.txt\" /T /E /G Everyone:F"; 1030 _LaunchAppEx(szProgram, szCmdLine, WAIT, SW_HIDE, 5000, nvExitCode); 1031 1032 szCmdLine = "/c cacls \"" + TARGETDIR ^ "etc" ^ "initout.txt\" /T /E /G Everyone:F"; 1033 _LaunchAppEx(szProgram, szCmdLine, WAIT, SW_HIDE, 5000, nvExitCode); 1034 1035 szCmdLine = "/c cacls \"" + TARGETDIR ^ "etc" ^ "key.db\" /T /E /G Everyone:F"; 1036 _LaunchAppEx(szProgram, szCmdLine, WAIT, SW_HIDE, 5000, nvExitCode); 1037 1038 szCmdLine = "/c cacls \"" + TARGETDIR ^ "etc" ^ "users.db\" /T /E /G Everyone:F"; 1039 _LaunchAppEx(szProgram, szCmdLine, WAIT, SW_HIDE, 5000, nvExitCode); 1040 1041 szCmdLine = "/c cacls \"" + TARGETDIR ^ "etc" ^ "main.cfg\" /T /E /G Everyone:F"; 1042 _LaunchAppEx(szProgram, szCmdLine, WAIT, SW_HIDE, 5000, nvExitCode); 1043 1044 szCmdLine = "/c cacls \"" + TARGETDIR ^ "etc" ^ "history.db\" /T /E /G Everyone:F"; 1045 _LaunchAppEx(szProgram, szCmdLine, WAIT, SW_HIDE, 5000, nvExitCode); 1046 1047 szCmdLine = "/c cacls \"" + TARGETDIR ^ "etc" ^ "usage.txt\" /T /E /G Everyone:F"; 1048 _LaunchAppEx(szProgram, szCmdLine, WAIT, SW_HIDE, 5000, nvExitCode); 1049 1050 endif; 1051 1052 end; 1053 1054 function _LaunchAppEx(szProgram, szCmdLine, nWait, nShow, nTimeOut, nvExitCode) 1055 STARTUPINFO siData; 1056 PROCESS_INFORMATION piData; 1057 1058 begin 1059 1060 siData.cb = 68; 1061 siData.lpReserved = NULL; 1062 siData.lpDesktop = NULL; 1063 siData.lpTitle = NULL; 1064 siData.dwX = 0; 1065 siData.dwY = 0; 1066 siData.dwXSize = 0; 1067 siData.dwYSize = 0; 1068 siData.dwXCountChars = 0; 1069 siData.dwYCountChars = 0; 1070 siData.dwFillAttribute = 0; 1071 siData.dwFlags = 1; 1072 siData.wShowWindow = nShow; 1073 siData.lpReserved2 = NULL; 1074 siData.hStdInput = NULL; 1075 siData.hStdOutput = NULL; 1076 siData.hStdError = NULL; 1077 1078 if (CreateProcessA(NULL, szProgram + " " + szCmdLine, NULL, NULL, 1079 TRUE, 0, NULL, NULL, &siData, &piData) = 0) then 1080 return (-1); 1081 endif; 1082 1083 if ( nWait != WAIT ) then 1084 nvExitCode = 0; 1085 return 0; 1086 endif; 1087 1088 WaitForSingleObject(piData.hProcess, nTimeOut); 1089 1090 GetExitCodeProcess(piData.hProcess, &nvExitCode); 1091 1092 CloseHandle(piData.hProcess); 1093 CloseHandle(piData.hThread); 1094 1095 return 0; 1096 end; 1097 1098 960 1099 /////////////////////////////////////////////////////////////////////////////// 961 1100 // … … 975 1114 976 1115 1116 1117
Note:
See TracChangeset
for help on using the changeset viewer.