1 /************************************************************** 2 * 3 * Licensed to the Apache Software Foundation (ASF) under one 4 * or more contributor license agreements. See the NOTICE file 5 * distributed with this work for additional information 6 * regarding copyright ownership. The ASF licenses this file 7 * to you under the Apache License, Version 2.0 (the 8 * "License"); you may not use this file except in compliance 9 * with the License. You may obtain a copy of the License at 10 * 11 * http://www.apache.org/licenses/LICENSE-2.0 12 * 13 * Unless required by applicable law or agreed to in writing, 14 * software distributed under the License is distributed on an 15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16 * KIND, either express or implied. See the License for the 17 * specific language governing permissions and limitations 18 * under the License. 19 * 20 *************************************************************/ 21 22 23 24 #ifndef _MHAPPDEF_HXX 25 #define _MHAPPDEF_HXX 26 27 28 #ifdef UNX 29 #define DEFAULT_INI_ROOT "/so/env" 30 #define DEFAULT_BS_ROOT "/so/env/b_server" 31 #define DEFAULT_EIS_ROOT "/so/env/merge" 32 #define PATH_SEPARATOR '/' 33 #define S_PATH_SEPARATOR "/" 34 #else 35 #define DEFAULT_INI_ROOT "r:" 36 #define DEFAULT_BS_ROOT "n:" 37 #define DEFAULT_EIS_ROOT "w:" 38 #define PATH_SEPARATOR '\\' 39 #define S_PATH_SEPARATOR "\\" 40 #endif 41 42 #define _INI_DRV DEFAULT_INI_ROOT 43 #define B_SERVER_ROOT DEFAULT_BS_ROOT 44 #define DEFAULT_INI_FILE B_SERVER_ROOT S_PATH_SEPARATOR "config" S_PATH_SEPARATOR "b_server.ini" 45 #define BINARYROOT B_SERVER_ROOT S_PATH_SEPARATOR "bin" 46 #define _JOB_DIR B_SERVER_ROOT S_PATH_SEPARATOR "server" S_PATH_SEPARATOR "db" 47 #define _INJOB_DIR B_SERVER_ROOT S_PATH_SEPARATOR "server" S_PATH_SEPARATOR "dbin" 48 #define _OUTJOB_DIR B_SERVER_ROOT S_PATH_SEPARATOR "server" S_PATH_SEPARATOR "dbout" 49 #define _ERRJOB_DIR B_SERVER_ROOT S_PATH_SEPARATOR "server" S_PATH_SEPARATOR "dberr" 50 #define _BUILDPATTERN_DIR B_SERVER_ROOT S_PATH_SEPARATOR "pattern" 51 #define _COMMENT_DIR B_SERVER_ROOT S_PATH_SEPARATOR "comment" 52 #define _SOLARLIST B_SERVER_ROOT S_PATH_SEPARATOR "config" S_PATH_SEPARATOR "solar.lst" 53 #define _DEF_STAND_LIST B_SERVER_ROOT S_PATH_SEPARATOR "config" S_PATH_SEPARATOR "stand.lst" 54 #define _DEF_DEFAULT_LIST B_SERVER_ROOT S_PATH_SEPARATOR "config" S_PATH_SEPARATOR "default.lst" 55 #define _DEF_SSOLARINI B_SERVER_ROOT S_PATH_SEPARATOR "config" S_PATH_SEPARATOR "ssolar.ini" 56 #define _DEF_SSCOMMON B_SERVER_ROOT S_PATH_SEPARATOR "config" S_PATH_SEPARATOR "ssolar.cmn" 57 #define _SERVER_IDENT_FLAG B_SERVER_ROOT S_PATH_SEPARATOR "config" S_PATH_SEPARATOR "server.id" 58 #define _CUSTOMJOBINI B_SERVER_ROOT S_PATH_SEPARATOR "config" S_PATH_SEPARATOR "custom.ini" 59 #define _BUILDCOMMANDINI B_SERVER_ROOT S_PATH_SEPARATOR "config" S_PATH_SEPARATOR "bcommand.ini" 60 #define _DATABASEINI B_SERVER_ROOT S_PATH_SEPARATOR "config" S_PATH_SEPARATOR "database.ini" 61 #define _ZNINI B_SERVER_ROOT S_PATH_SEPARATOR "config" S_PATH_SEPARATOR "bszn.ini" 62 #define _ERRORINFOFILE B_SERVER_ROOT S_PATH_SEPARATOR "config" S_PATH_SEPARATOR "errinf.lst" 63 #define _REGEXPINFOFILE B_SERVER_ROOT S_PATH_SEPARATOR "config" S_PATH_SEPARATOR "regexp.lst" 64 #define _POSITIVERRORINFOFILE B_SERVER_ROOT S_PATH_SEPARATOR "config" S_PATH_SEPARATOR "perrinf.lst" 65 #define _POSITIVREGEXPINFOFILE B_SERVER_ROOT S_PATH_SEPARATOR "config" S_PATH_SEPARATOR "pregexp.lst" 66 #define _INIROOT B_SERVER_ROOT S_PATH_SEPARATOR "config" 67 #define _INIROOT_OLD B_SERVER_ROOT S_PATH_SEPARATOR "config" 68 #define _ENV_DIR B_SERVER_ROOT S_PATH_SEPARATOR "config" 69 #define _REDIRECTIONPATH B_SERVER_ROOT S_PATH_SEPARATOR "redir" 70 #define _ZLOGSPATH B_SERVER_ROOT S_PATH_SEPARATOR "zlogs" 71 #define DEFAULT_PROTPATH B_SERVER_ROOT S_PATH_SEPARATOR "filesize" 72 #define _INI_UNC "\\\\jumbo2.germany.sun.com\\R-Laufwerk" 73 #define _INI_UNC_OLD "\\\\jumbo2.germany.sun.com\\R-Laufwerk" 74 #define LOG_DIR B_SERVER_ROOT S_PATH_SEPARATOR "log" 75 76 #define _REDIRECTIONSIZE "10000" 77 #define _EISPATH DEFAULT_EIS_ROOT S_PATH_SEPARATOR "EIS" 78 79 #define _BUILDEVENTPATH _EISPATH S_PATH_SEPARATOR "EventImport" 80 81 #define _WRITE_LOGFILES "1" 82 #define _WRITE_JOBFILES "1" 83 84 #define _VERSION_WINDOW "0" 85 #define _JOB_WINDOW "0" 86 #define _APPWIN_MAXIMIZED "0" 87 #define _CONTEXT_TBOX "0" 88 89 #define _COLOR_DROPED COL_GRAY 90 #define _COLOR_WAIT COL_BLUE 91 #define _COLOR_BUILD COL_GREEN 92 #define _COLOR_ERROR COL_RED 93 #define _COLOR_BUILDERROR COL_MAGENTA 94 #define _COLOR_OK COL_BLACK 95 #define _COLOR_DELIVERED COL_CYAN 96 #define _COLOR_MASTERSTOP COL_LIGHTRED 97 98 #define _ASYNCHRON "1" 99 100 // folowing defines are used to write filesize information for binaries 101 #define OH_GOTT "*" 102 #define UNX_DEFAULT_FILESIZES "bin/" OH_GOTT ".bin;bin/" OH_GOTT ".res;bin/" OH_GOTT ".tlb;lib/" OH_GOTT ".so" 103 #define DOS_DEFAULT_FILESIZES "bin\\*.exe;bin\\*.res;bin\\*.dll;bin\\*.tlb" 104 105 #ifdef UNX 106 #define DEFAULT_FILESIZES UNX_DEFAULT_FILESIZES 107 #else 108 #define DEFAULT_FILESIZES DOS_DEFAULT_FILESIZES 109 #endif 110 111 /** States for BuildServer projects and directories 112 */ 113 #ifndef BuildStatus 114 #define BuildStatus sal_uInt16 115 #endif 116 #define BS_DROPED 0 /// project is waiting for dispatching 117 #define BS_BUILD 1 /// project/directory is building 118 #define BS_WAIT 2 /// project/directory is waiting for building 119 #define BS_OK 3 /// project/directory builded whithout errors 120 #define BS_BUILDANDERROR 4 /// project is in build, any errors accured 121 #define BS_ERROR 5 /// project/directory builded with errors 122 #define BS_NON 6 /// no state is set 123 #define BS_DELIVERED 7 /// project was delivered without errors 124 #define BS_DELIVEREDANDERROR 8 /// project was delivered with errors 125 #define BS_FIXED 9 /// errors are fixed 126 #define BS_NOTDELIVERED 10 /// project is ready to deliver 127 #define BS_BUILD_PRIO 11 /// build projects with prio 128 #define BS_BUILD_ORDER 12 /// build project in correct order 129 #define BS_BUILD_DEPEND 13 /// build projects using dependencies 130 #define BS_BUILD_DELIVER 14 /// build projects using dependencies and deliver builded projects 131 #define BS_BUILD_NORMAL 15 /// build projects without using dependencies 132 #define BS_BUILD_DELIVER_NO_DEPEND 16 /// build projects without using dependencies and deliver builded projects 133 #define BS_BUILD_DOUBLE_LOG 17 /// error with double log names 134 135 #define LF_STARDIV "StarDivision" 136 #define LF_UNIX "UNIX" 137 #define LF_MAC "Macintosh" 138 #define LF_OS2 "OS/2" 139 140 // path conversion 141 const char* GetDefStandList(); 142 const char* GetIniRoot(); 143 const char* GetIniRootOld(); 144 const char* GetSSolarIni(); 145 const char* GetSSCommon(); 146 const char* GetBServerRoot(); 147 148 const char* GetEnv( const char *pVar ); 149 const char* GetEnv( const char *pVar, const char *pDefault ); 150 151 #define CONVERT_R_TO_HOSTFSYS( sPath ) { sPath.ToLowerAscii().SearchAndReplace( "r:", GetEnv("ISERVERBASE", DEFAULT_INI_ROOT ) ); sPath.SearchAndReplaceAll( "\\", S_PATH_SEPARATOR ); } 152 153 // Only for usage inside IServer! 154 #define ISERVER_DEF_STAND_LIST "r:\\b_server\\config\\stand.lst" 155 #define ISERVER_DEF_DEPEND_LIST "r:\\b_server\\config\\depend.lst" 156 157 #endif 158