summaryrefslogtreecommitdiff
path: root/solenv/inc/verinfo.hrc
blob: fc7a7cafd03ffa914305d33136c6e4b396276c71 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
/*************************************************************************
 *
 *  $RCSfile: verinfo.hrc,v $
 *
 *  $Revision: 1.2 $
 *
 *  last change: $Author: hjs $ $Date: 2000-10-30 16:15:04 $
 *
 *  The Contents of this file are made available subject to the terms of
 *  either of the following licenses
 *
 *         - GNU Lesser General Public License Version 2.1
 *         - Sun Industry Standards Source License Version 1.1
 *
 *  Sun Microsystems Inc., October, 2000
 *
 *  GNU Lesser General Public License Version 2.1
 *  =============================================
 *  Copyright 2000 by Sun Microsystems, Inc.
 *  901 San Antonio Road, Palo Alto, CA 94303, USA
 *
 *  This library is free software; you can redistribute it and/or
 *  modify it under the terms of the GNU Lesser General Public
 *  License version 2.1, as published by the Free Software Foundation.
 *
 *  This library is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 *  Lesser General Public License for more details.
 *
 *  You should have received a copy of the GNU Lesser General Public
 *  License along with this library; if not, write to the Free Software
 *  Foundation, Inc., 59 Temple Place, Suite 330, Boston,
 *  MA  02111-1307  USA
 *
 *
 *  Sun Industry Standards Source License Version 1.1
 *  =================================================
 *  The contents of this file are subject to the Sun Industry Standards
 *  Source License Version 1.1 (the "License"); You may not use this file
 *  except in compliance with the License. You may obtain a copy of the
 *  License at http://www.openoffice.org/license.html.
 *
 *  Software provided under this License is provided on an "AS IS" basis,
 *  WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
 *  WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
 *  MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
 *  See the License for the specific provisions governing your rights and
 *  obligations concerning the Software.
 *
 *  The Initial Developer of the Original Code is: Sun Microsystems, Inc.
 *
 *  Copyright: 2000 by Sun Microsystems, Inc.
 *
 *  All Rights Reserved.
 *
 *  Contributor(s): _______________________________________
 *
 *
 ************************************************************************/

#ifndef _VERINFO_HRC
#define _VERINFO_HRC

// include ---------------------------------------------------------------

#ifndef WIN32
#include <ver.h>
#else
#include <winver.h>
#endif

// general preprocessor string management --------------------------------

#ifndef PPSX
#define PPSX(s) #s
#endif
#ifndef PPS
#define PPS(s) PPSX(s)
#endif

#ifndef PPCX
#define PPCX(s1, s2) s1##s2
#endif
#ifndef PPCAT
#define PPCAT(s1, s2) PPCX(s1, s2)
#endif

// define order of date parts --------------------------------------------

#if defined(LG_D)
  #define VER_DMY
#else
  #define VER_YMD
#endif

// set VERVARIANT to 0 if not defined ------------------------------------

#if !defined(VERVARIANT)
  #define VERVARIANT 0
#endif

// define pre release state ----------------------------------------------

#ifdef VER_CONCEPT
  #define VER_PREL 1
  #define VER_COUNT (0+VER_CONCEPT)
  #define VER1 Concept (Level VER_CONCEPT)
#endif

#ifdef VER_ALPHA
  #define VER_PREL 1
  #define VER_COUNT (100+VER_ALPHA)
  #define VER1 Alpha (Level VER_ALPHA)
#endif

#ifdef VER_BETA
  #define VER_PREL 1
  #define VER_COUNT (200+VER_BETA)
  #define VER1 Beta (Level VER_BETA)
#endif

#ifdef VER_GAMMA
  #define VER_PREL 1
  #define VER_COUNT (300+VER_GAMMA)
  #define VER1 Gamma (Level VER_GAMMA)
#endif

#ifdef VER_FINAL
  #define VER_COUNT (500+VER_FINAL)
  #if VER_FINAL==0
    #undef VER1
  #elif VER_FINAL==1
    #define VER1 1
  #elif VER_FINAL==2
    #define VER1 2
  #elif VER_FINAL==3
    #define VER1 3
  #elif VER_FINAL==4
    #define VER1 4
  #elif VER_FINAL==5
    #define VER1 5
  #elif VER_FINAL==6
    #define VER1 6
  #elif VER_FINAL==7
    #define VER1 7
  #elif VER_FINAL==8
    #define VER1 8
  #elif VER_FINAL==9
    #define VER1 9
  #elif VER_FINAL==10
    #define VER1 a
  #elif VER_FINAL==11
    #define VER1 b
  #elif VER_FINAL==12
    #define VER1 c
  #endif
#endif

#if SUBVERSION < 10
  #define VER4 PPCAT(0, SUBVERSION)
#else
  #define VER4 SUBVERSION
#endif

#ifndef VER1
#if VERVARIANT > 0
  #define VER_LEVEL VERSION.VER4.VERVARIANT
#else
  #define VER_LEVEL VERSION.VER4
#endif
#else
  #define VERC1(a, b, c) a.b##c
  #define VERC2(a, b, c) VERC1(a, b, c)
  #define VER_LEVEL VERC2(VERSION, VER4, VER1)
#endif

#if !defined(VER_DMY) && VER_DAY < 10
  #define VER5 PPCAT(0, VER_DAY)
#else
  #define VER5 VER_DAY
#endif

// define month strings --------------------------------------------------

#if VER_MONTH==1
  #define VER2 Jan
#elif VER_MONTH==2
  #define VER2 Feb
#elif VER_MONTH==3
  #ifdef LG_D
    #define VER2 M\344r
  #else
    #define VER2 Mar
  #endif
#elif VER_MONTH==4
  #define VER2 Apr
#elif VER_MONTH==5
  #ifdef LG_D
    #define VER2 Mai
  #else
    #define VER2 May
  #endif
#elif VER_MONTH==6
  #define VER2 Jun
#elif VER_MONTH==7
  #define VER2 Jul
#elif VER_MONTH==8
  #define VER2 Aug
#elif VER_MONTH==9
  #define VER2 Sep
#elif VER_MONTH==10
  #ifdef LG_D
    #define VER2 Okt
  #else
    #define VER2 Oct
  #endif
#elif VER_MONTH==11
  #define VER2 Nov
#elif VER_MONTH==12
  #ifdef LG_D
    #define VER2 Dez
  #else
    #define VER2 Dec
  #endif
#endif

#ifdef LG_D
  #define VERC3(a, b, c) a.b.c
#else
  #define VERC3(a, b, c) c-b-a
#endif
#define VERC4(a, b, c) VERC3(a, b, c)
#define VER_DATE VERC4(VER5, VER2, VER_YEAR)

#if VER_FIRSTYEAR==VER_YEAR
  #define VER_YEARRANGE VER_FIRSTYEAR
#else
  #define VER_YEARRANGE VER_FIRSTYEAR-VER_YEAR
#endif

#if VER_FIRSTYEAR > 100
#define VERC5(a) Copyright \251 a by
#define VERC6(a) VERC5(a)
#else
#define VERC5(a) Copyright \251 19##a by
#define VERC6(a) VERC5(a)
#endif

#define S_CRIGHT PPS(VERC6(VER_YEARRANGE))

#ifdef LG_D
#define S_VERSION PPS(Version VER_LEVEL vom VER_DATE)
#else
#define S_VERSION PPS(Version VER_LEVEL of VER_DATE)
#endif

#endif  // _VERINFO_HRC

/*************************************************************************

      Source Code Control System - Update

      $Log: not supported by cvs2svn $
      Revision 1.1.1.1  2000/09/20 14:43:18  hr
      initial import

      Revision 1.3  2000/06/29 17:24:48  hjs
      year 2000 bug

      Revision 1.2  2000/06/29 16:02:40  hjs
      use VERVARIANT

      Revision 1.1  2000/02/10 12:22:20  hjs
      versioninfo resources


      Rev 1.4   21 Dec 1995 14:32:38   HJS
   umstellung von ver_final; 1=1,  10=a etc.

      Rev 1.3   25 Sep 1995 14:50:58   ER
   moved to t:/solar/inc (s:\solenv\inc)

      Rev 1.2   16 Mar 1995 16:10:20   ER
   kurz vor der dritten Auslieferung befinden wir uns
   nicht mehr in der Test/UI Phase..

      Rev 1.1   11 Oct 1993 18:14:00   ER
   VerInfo auch unter WNT

      Rev 1.0   07 Sep 1993 17:26:52   ER
   Initial revision.

*************************************************************************/