author | Stefan Vogel <sv@exept.de> |
Thu, 23 Feb 2012 12:50:27 +0100 | |
changeset 14021 | 11d015697e44 |
parent 13968 | 03b79717bd2b |
child 14042 | 05b7b61d7e59 |
permissions | -rw-r--r-- |
9553 | 1 |
" |
2 |
COPYRIGHT (c) 2006 by eXept Software AG |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3 |
All Rights Reserved |
9553 | 4 |
|
5 |
This software is furnished under a license and may be used |
|
6 |
only in accordance with the terms of that license and with the |
|
7 |
inclusion of the above copyright notice. This software may not |
|
8 |
be provided or otherwise made available to, or used by, any |
|
9 |
other person. No title to or ownership of the software is |
|
10 |
hereby transferred. |
|
11 |
" |
|
9671 | 12 |
"{ Package: 'stx:libbasic' }" |
9536 | 13 |
|
9569 | 14 |
Object subclass:#ProjectDefinition |
13820
f46f7306eea2
changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents:
13809
diff
changeset
|
15 |
instanceVariableNames:'' |
f46f7306eea2
changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents:
13809
diff
changeset
|
16 |
classVariableNames:'LibraryType GUIApplicationType NonGUIApplicationType |
f46f7306eea2
changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents:
13809
diff
changeset
|
17 |
PackagesBeingLoaded Verbose AbbrevDictionary AccessLock' |
f46f7306eea2
changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents:
13809
diff
changeset
|
18 |
poolDictionaries:'' |
f46f7306eea2
changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents:
13809
diff
changeset
|
19 |
category:'System-Support-Projects' |
9536 | 20 |
! |
21 |
||
13419 | 22 |
ProjectDefinition class instanceVariableNames:'safeForOverwrittenMethods extensionOverwriteInfo projectIsLoaded' |
9607 | 23 |
|
24 |
" |
|
25 |
No other class instance variables are inherited by this class. |
|
26 |
" |
|
27 |
! |
|
28 |
||
13592 | 29 |
Object subclass:#AbbrevEntry |
13820
f46f7306eea2
changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents:
13809
diff
changeset
|
30 |
instanceVariableNames:'className fileName category numClassInstVars' |
f46f7306eea2
changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents:
13809
diff
changeset
|
31 |
classVariableNames:'' |
f46f7306eea2
changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents:
13809
diff
changeset
|
32 |
poolDictionaries:'' |
f46f7306eea2
changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents:
13809
diff
changeset
|
33 |
privateIn:ProjectDefinition |
13592 | 34 |
! |
35 |
||
9569 | 36 |
!ProjectDefinition class methodsFor:'documentation'! |
9553 | 37 |
|
12210 | 38 |
buildingMakefiles |
39 |
" |
|
40 |
You can define additional rules and flag settings for use in the makeFile generation: |
|
41 |
||
42 |
redefinable build-file attributes: |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
43 |
stcOptimizationOptions -> STCLOCALOPT |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
44 |
stcWarningOptions -> STCLOCALOPT |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
45 |
localIncludes_unix -> LOCALINCLUDES (Make.proto) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
46 |
localIncludes_win32 -> LOCALINCLUDES (bc.mak) |
13419 | 47 |
|
48 |
for applications: |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
49 |
startupClassName |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
50 |
startupSelector |
13419 | 51 |
|
52 |
for libraries: |
|
12210 | 53 |
|
54 |
" |
|
55 |
! |
|
56 |
||
9553 | 57 |
copyright |
58 |
" |
|
59 |
COPYRIGHT (c) 2006 by eXept Software AG |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
60 |
All Rights Reserved |
9553 | 61 |
|
62 |
This software is furnished under a license and may be used |
|
63 |
only in accordance with the terms of that license and with the |
|
64 |
inclusion of the above copyright notice. This software may not |
|
65 |
be provided or otherwise made available to, or used by, any |
|
66 |
other person. No title to or ownership of the software is |
|
67 |
hereby transferred. |
|
68 |
" |
|
9714 | 69 |
! |
70 |
||
71 |
documentation |
|
72 |
" |
|
12210 | 73 |
As ST/X is (still) very tightly bound with stc, we keep the package and project information |
74 |
in a class-object (instead of some Project-object). This has the advantage, that it can be |
|
75 |
compiled and included in a compiled class library just like any other class. |
|
76 |
Every package includes an subclass of me (an instance of my meta), which provides useful |
|
77 |
information about the versioning and packaging. Me myself, I know how to generate dependency |
|
78 |
information and can generate makefiles and other build-support files for compilation. |
|
79 |
||
80 |
Some special notes about extension methods: |
|
81 |
if a package is loaded (Smalltalk loadPackage:'foo:bar/baz'), any already loaded package of which |
|
82 |
methods are overwritten by an extension of this package, the other package is asked to safe those |
|
83 |
methods in its safe(ForOverwrittenMethods). Thus, if the other package or any of its classes is asked |
|
84 |
to file itself out, it can do so using the safe (otherwise, you'D not be able to checkin a class while |
|
85 |
it has an overriding extension loaded). |
|
86 |
Also, the information about which other package was in charge when a method is overwritten is recorded in |
|
87 |
extensionOverwriteInfo. This is used to correctly reinstall an overwritten method, whenever a package is |
|
88 |
unloaded. |
|
9714 | 89 |
|
90 |
" |
|
9553 | 91 |
! ! |
9536 | 92 |
|
9569 | 93 |
!ProjectDefinition class methodsFor:'instance creation'! |
9559 | 94 |
|
12371 | 95 |
definitionClassForMonticelloPackage:aMonicelloPackagename |
96 |
^ self definitionClassForMonticelloPackage:aMonicelloPackagename createIfAbsent:false |
|
97 |
||
98 |
" |
|
99 |
self definitionClassForMonticelloPackage:'foobar' |
|
100 |
" |
|
101 |
! |
|
102 |
||
103 |
definitionClassForMonticelloPackage:aMonicelloPackagename createIfAbsent:createIfAbsent |
|
13419 | 104 |
^ self allSubclasses |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
105 |
detect:[:eachProjectDefinition | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
106 |
eachProjectDefinition monticelloPackageName = aMonicelloPackagename ] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
107 |
ifNone:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
108 |
|dfn squeakPackageInfo| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
109 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
110 |
createIfAbsent ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
111 |
dfn := ApplicationDefinition |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
112 |
definitionClassForPackage:'mc:',aMonicelloPackagename createIfAbsent:true projectType:GUIApplicationType. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
113 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
114 |
"/ if the squeak-stuff is loaded, use it. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
115 |
PackageInfo notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
116 |
squeakPackageInfo := PackageInfo allSubclasses |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
117 |
detect:[:pi | pi new packageName = aMonicelloPackagename] ifNone:nil. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
118 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
119 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
120 |
squeakPackageInfo notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
121 |
dfn classNames:(squeakPackageInfo new classes collect:[:each | each name]). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
122 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
123 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
124 |
nil |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
125 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
126 |
] |
12371 | 127 |
|
128 |
" |
|
129 |
self definitionClassForMonticelloPackage:'foobar' |
|
130 |
self definitionClassForMonticelloPackage:'foobar' createIfAbsent:true |
|
131 |
" |
|
13118
06c6d0c09bb2
changed: #definitionClassForMonticelloPackage:createIfAbsent:
Claus Gittinger <cg@exept.de>
parents:
13090
diff
changeset
|
132 |
|
06c6d0c09bb2
changed: #definitionClassForMonticelloPackage:createIfAbsent:
Claus Gittinger <cg@exept.de>
parents:
13090
diff
changeset
|
133 |
"Modified: / 30-10-2010 / 00:26:07 / cg" |
12371 | 134 |
! |
135 |
||
136 |
definitionClassForPackage:aPackageID |
|
137 |
^ self definitionClassForPackage:aPackageID createIfAbsent:false |
|
138 |
||
139 |
"Modified: / 17-08-2006 / 14:33:35 / cg" |
|
140 |
! |
|
141 |
||
142 |
definitionClassForPackage:aPackageID createIfAbsent:doCreateIfAbsent |
|
143 |
^ self definitionClassForPackage:aPackageID createIfAbsent:doCreateIfAbsent projectType:nil |
|
144 |
||
145 |
"Modified: / 23-08-2006 / 14:29:15 / cg" |
|
146 |
! |
|
147 |
||
148 |
definitionClassForPackage: aPackageID createIfAbsent: doCreateIfAbsent projectType:typeOrNil |
|
149 |
|packageDefinitionClassName class| |
|
150 |
||
151 |
packageDefinitionClassName := ProjectDefinition initialClassNameForDefinitionOf:aPackageID. |
|
152 |
class := Smalltalk classNamed:packageDefinitionClassName. |
|
153 |
class isNil ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
154 |
doCreateIfAbsent ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
155 |
class := self newForPackage:aPackageID. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
156 |
"setup before prerequisites are defined" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
157 |
class setupForType:typeOrNil. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
158 |
"/ look what is there and include it; is this ok ? |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
159 |
class compileDescriptionMethods |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
160 |
]. |
12371 | 161 |
] ifFalse:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
162 |
typeOrNil notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
163 |
class projectType == typeOrNil ifFalse: [ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
164 |
class setupForType:typeOrNil. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
165 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
166 |
]. |
12371 | 167 |
]. |
168 |
^ class |
|
169 |
||
170 |
"Created: / 23-08-2006 / 14:29:21 / cg" |
|
171 |
"Modified: / 23-08-2006 / 15:35:26 / cg" |
|
172 |
! |
|
173 |
||
174 |
definitionClassForPackage:newProjectID projectType:typeOrNil createIfAbsent:createIfAbsent |
|
175 |
^ (self definitionClassForType:typeOrNil) |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
176 |
definitionClassForPackage:newProjectID |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
177 |
createIfAbsent:createIfAbsent |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
178 |
projectType:typeOrNil |
12371 | 179 |
|
180 |
"Created: / 23-08-2006 / 14:28:53 / cg" |
|
181 |
! |
|
182 |
||
183 |
definitionClassForType: type |
|
184 |
"answer the class that describes a give project type" |
|
185 |
||
186 |
(type = LibraryType) ifTrue:[ ^ LibraryDefinition ]. |
|
187 |
(type = GUIApplicationType) ifTrue:[ ^ ApplicationDefinition ]. |
|
188 |
(type = NonGUIApplicationType) ifTrue:[ ^ ApplicationDefinition ]. |
|
189 |
(type = 'Application') ifTrue:[ ^ ApplicationDefinition ]. "/ temporary - for backward compat. |
|
190 |
self error:'unknown project type'. |
|
191 |
||
192 |
"Created: / 17-08-2006 / 14:46:28 / cg" |
|
193 |
"Modified: / 23-08-2006 / 13:49:27 / cg" |
|
194 |
! |
|
195 |
||
9559 | 196 |
newForPackage:packageID |
13419 | 197 |
^ self |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
198 |
newNamed:(self initialClassNameForDefinitionOf:packageID) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
199 |
package:packageID. |
9559 | 200 |
|
201 |
"Created: / 11-08-2006 / 14:27:19 / cg" |
|
202 |
! |
|
203 |
||
204 |
newNamed:newName package:packageID |
|
205 |
|newClass| |
|
206 |
||
207 |
"/ for now, we are strict. |
|
208 |
self assert:(self initialClassNameForDefinitionOf:packageID) = newName. |
|
9569 | 209 |
self assert:(self ~~ ProjectDefinition). "ProjectDefinition is abstract" |
9559 | 210 |
|
211 |
newClass := self |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
212 |
subclass:(newName asSymbol) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
213 |
instanceVariableNames:'' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
214 |
classVariableNames:'' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
215 |
poolDictionaries:'' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
216 |
category:(self defaultCategory). |
9559 | 217 |
|
218 |
newClass package:packageID asSymbol. |
|
219 |
^ newClass |
|
220 |
||
221 |
"Created: / 09-08-2006 / 17:57:37 / fm" |
|
222 |
"Modified: / 09-08-2006 / 19:27:53 / fm" |
|
9569 | 223 |
"Modified: / 17-08-2006 / 17:24:23 / cg" |
9559 | 224 |
! ! |
225 |
||
9569 | 226 |
!ProjectDefinition class methodsFor:'accessing'! |
9536 | 227 |
|
10716 | 228 |
allPreRequisites |
13635
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
229 |
"answer all (recursive) prerequisite project ids of myself - in random order." |
11386
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
230 |
|
13336 | 231 |
^ self allPreRequisitesWithParentDo:[:parent :prereq | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
232 |
prereq = self package ifTrue:[ Transcript showCR:('oops: %1 depends on itself' bindWith:prereq) ]. |
13336 | 233 |
] |
234 |
||
235 |
" |
|
236 |
stx_libbasic allPreRequisites |
|
237 |
stx_libbasic2 allPreRequisites |
|
238 |
stx_libview2 allPreRequisites |
|
13419 | 239 |
ubs_application allPreRequisites |
240 |
ubs_application allPreRequisitesSorted |
|
241 |
exept_expecco_application allPreRequisites |
|
242 |
exept_expeccoNET_application allPreRequisites |
|
13336 | 243 |
alspa_batch_application allPreRequisites |
244 |
" |
|
245 |
||
246 |
"Modified: / 13-04-2011 / 15:30:45 / sr" |
|
13635
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
247 |
"Modified (comment): / 06-09-2011 / 08:26:06 / cg" |
13336 | 248 |
! |
249 |
||
250 |
allPreRequisitesSorted |
|
251 |
"answer all the prerequisites of this projects sorted in |
|
252 |
the order they are needed. |
|
253 |
Use this to e.g. compile packages in the dependency order" |
|
13419 | 254 |
|
13336 | 255 |
|allPreRequisites orderedTuples effective allPreRequisitesWithExtensions sortedPackages| |
256 |
||
257 |
orderedTuples := OrderedCollection new. |
|
258 |
||
259 |
allPreRequisites := self allPreRequisites. |
|
260 |
allPreRequisitesWithExtensions := allPreRequisites union:self extensionPackages. |
|
261 |
||
262 |
allPreRequisites do:[:eachPackageID | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
263 |
|def| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
264 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
265 |
self assert:(eachPackageID ~= self package). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
266 |
orderedTuples add:(Array with:eachPackageID with:self package). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
267 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
268 |
def := self definitionClassForPackage:eachPackageID. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
269 |
def isNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
270 |
Transcript showCR:'Warning: no definition class for package: ', eachPackageID. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
271 |
effective := (self searchForPreRequisites: eachPackageID) keys. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
272 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
273 |
effective := def effectivePreRequisites union:def extensionPackages. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
274 |
effective notEmptyOrNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
275 |
effective do:[:eachPrerequisitePackageID| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
276 |
self assert:(eachPrerequisitePackageID ~= eachPackageID). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
277 |
orderedTuples add:(Array with:eachPrerequisitePackageID with:eachPackageID). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
278 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
279 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
280 |
]. |
13336 | 281 |
]. |
282 |
||
283 |
(orderedTuples detect:[:el | el first = el second] ifNone:nil) notNil ifTrue:[self halt]. |
|
284 |
sortedPackages := orderedTuples topologicalSort. |
|
285 |
||
286 |
"packages which only result from extension methods are used for computing the sort order, |
|
287 |
but they are not added, if not present in the first place" |
|
288 |
^ sortedPackages select:[:eachProject| allPreRequisites includes:eachProject] |
|
289 |
||
290 |
" |
|
291 |
stx_libbasic allPreRequisitesSorted |
|
292 |
stx_libbasic2 allPreRequisitesSorted |
|
293 |
stx_libwidg2 allPreRequisitesSorted |
|
294 |
exept_expecco_application allPreRequisitesSorted |
|
295 |
alspa_batch_application allPreRequisitesSorted |
|
296 |
ubs_application allPreRequisitesSorted |
|
297 |
" |
|
298 |
||
299 |
"Modified: / 13-04-2011 / 15:19:13 / sr" |
|
13411 | 300 |
"Modified: / 28-06-2011 / 14:04:30 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
13336 | 301 |
! |
302 |
||
303 |
allPreRequisitesWithParentDo:aBlock |
|
304 |
"answer all (recursive) prerequisite project ids of myself - in random order. |
|
13695 | 305 |
If we exclude a project, but one of our prerequisite projects depends on it, |
13635
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
306 |
then what ????" |
13336 | 307 |
|
11386
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
308 |
|setOfAllPreRequisites toAdd| |
10716 | 309 |
|
310 |
setOfAllPreRequisites := Set new. |
|
11386
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
311 |
toAdd := Set new. |
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
312 |
toAdd addAll:self effectivePreRequisites. |
10810 | 313 |
|
11752
484d542ad43f
subProjects are no prerequisites
Stefan Vogel <sv@exept.de>
parents:
11713
diff
changeset
|
314 |
"is a subproject really a prerequisite?? |
484d542ad43f
subProjects are no prerequisites
Stefan Vogel <sv@exept.de>
parents:
11713
diff
changeset
|
315 |
No, it works the other way: parent projects are prerequisites of sub projects, |
484d542ad43f
subProjects are no prerequisites
Stefan Vogel <sv@exept.de>
parents:
11713
diff
changeset
|
316 |
so the following line has been deleted. |
484d542ad43f
subProjects are no prerequisites
Stefan Vogel <sv@exept.de>
parents:
11713
diff
changeset
|
317 |
Unfortunately the meaning of 'subproject' has never been well defined. SV." |
484d542ad43f
subProjects are no prerequisites
Stefan Vogel <sv@exept.de>
parents:
11713
diff
changeset
|
318 |
"/ toAdd addAll:self effectiveSubProjects. |
10716 | 319 |
|
320 |
[toAdd notEmpty] whileTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
321 |
|aPreRequisiteProjectID def| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
322 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
323 |
aPreRequisiteProjectID := toAdd removeFirst. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
324 |
(setOfAllPreRequisites includes:aPreRequisiteProjectID) ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
325 |
setOfAllPreRequisites add:aPreRequisiteProjectID. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
326 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
327 |
def := self definitionClassForPackage:aPreRequisiteProjectID. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
328 |
def isNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
329 |
Transcript showCR:'ProjectDefinition ', aPreRequisiteProjectID, ' is missing - cannot find its preRequisites.'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
330 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
331 |
def effectivePreRequisites |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
332 |
select:[:eachSubPreRequisite | (setOfAllPreRequisites includes:eachSubPreRequisite) not] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
333 |
thenDo:[:eachSubPreRequisite | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
334 |
Transcript show:'ProjectDefinition preRequisites: '; showCR:(aPreRequisiteProjectID, ' requires ', eachSubPreRequisite). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
335 |
aBlock value:def value:eachSubPreRequisite. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
336 |
toAdd add:eachSubPreRequisite |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
337 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
338 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
339 |
"but subprojects of our prerequisites are also prerequisites" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
340 |
def effectiveSubProjects |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
341 |
select:[:eachSubSubRequisite | eachSubSubRequisite ~= self package and:[ (setOfAllPreRequisites includes:eachSubSubRequisite) not ]] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
342 |
thenDo:[:eachSubSubRequisite | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
343 |
Transcript show:'ProjectDefinition preRequisites: '; showCR:(aPreRequisiteProjectID, ' hasSub ', eachSubSubRequisite). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
344 |
aBlock value:def value:eachSubSubRequisite. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
345 |
toAdd add:eachSubSubRequisite |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
346 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
347 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
348 |
] |
10716 | 349 |
]. |
11386
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
350 |
^ setOfAllPreRequisites. |
10716 | 351 |
|
352 |
" |
|
11386
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
353 |
stx_libbasic allPreRequisites |
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
354 |
stx_libbasic2 allPreRequisites |
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
355 |
stx_libview2 allPreRequisites |
13419 | 356 |
ubs_application allPreRequisites |
357 |
ubs_application allPreRequisitesSorted |
|
358 |
exept_expecco_application allPreRequisites |
|
359 |
exept_expeccoNET_application allPreRequisites |
|
10716 | 360 |
alspa_batch_application allPreRequisites |
361 |
" |
|
13336 | 362 |
|
363 |
"Created: / 13-04-2011 / 15:23:21 / sr" |
|
13635
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
364 |
"Modified (comment): / 06-09-2011 / 08:25:53 / cg" |
10810 | 365 |
! |
366 |
||
12575 | 367 |
directory |
368 |
"for packageId compatibility" |
|
369 |
||
370 |
^ self moduleDirectory |
|
371 |
||
372 |
" |
|
373 |
bosch_dapasx_datenbasis_Definition moduleDirectory |
|
374 |
bosch_dapasx_parameter_system_Definition moduleDirectory |
|
13419 | 375 |
stx_libbasic3 moduleDirectory |
376 |
cg_croquet moduleDirectory |
|
377 |
cg_croquet package asPackageId module |
|
378 |
cg_croquet moduleDirectory |
|
379 |
stx_goodies_xml_vw moduleDirectory |
|
12575 | 380 |
" |
381 |
||
382 |
"Created: / 08-08-2006 / 20:25:39 / fm" |
|
383 |
"Modified: / 18-08-2006 / 12:18:33 / cg" |
|
384 |
! |
|
385 |
||
13823 | 386 |
extensionsRevisionInfoForManager:managerOrNil |
387 |
"return the revisionInfo object for my extensions for a particular source code manager. |
|
388 |
Return nil, if there is either no manager, or I have no extensions" |
|
389 |
||
390 |
|mgr versionMethod revString| |
|
391 |
||
392 |
(mgr := managerOrNil) isNil ifTrue:[ |
|
393 |
mgr := SourceCodeManagerUtilities default sourceCodeManagerFor:self. |
|
394 |
mgr isNil ifTrue:[ |
|
395 |
^ nil |
|
396 |
]. |
|
397 |
]. |
|
398 |
||
399 |
versionMethod := mgr nameOfVersionMethodForExtensions. |
|
400 |
(self class implements:versionMethod) ifFalse:[^ nil]. |
|
401 |
||
402 |
revString := self perform:(mgr nameOfVersionMethodForExtensions) ifNotUnderstood:nil. |
|
403 |
revString isNil ifTrue:[ |
|
404 |
^ nil. |
|
405 |
]. |
|
406 |
^ mgr revisionInfoFromString:revString. |
|
407 |
||
408 |
" |
|
409 |
(stx_libcomp extensionsRevisionInfoForManager:nil) revision |
|
410 |
(stx_libbasic extensionsRevisionInfoForManager:nil) |
|
411 |
" |
|
412 |
||
413 |
"Created: / 25-11-2011 / 14:34:01 / cg" |
|
414 |
! |
|
415 |
||
9536 | 416 |
initialClassNameForDefinitionOf:aPackageId |
12360
18b9a4b30466
preps to allow for monticello packages to be loaded
Claus Gittinger <cg@exept.de>
parents:
12357
diff
changeset
|
417 |
"given a package-ID, return an appropriate class name for this package" |
18b9a4b30466
preps to allow for monticello packages to be loaded
Claus Gittinger <cg@exept.de>
parents:
12357
diff
changeset
|
418 |
|
9536 | 419 |
|s| |
420 |
||
421 |
s := aPackageId asString copy replaceAny:':/' with:$_. |
|
422 |
(s endsWith:$_) ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
423 |
s := s copyWithoutLast:1 |
9536 | 424 |
]. |
425 |
^ s |
|
426 |
||
12186 | 427 |
" |
13419 | 428 |
DapasXProject initialClassNameForDefinitionOf:'bosch:dapasx/interactiver_editor' |
429 |
DapasXProject initialClassNameForDefinitionOf:'stx:libbasic' |
|
430 |
DapasXProject initialClassNameForDefinitionOf:'stx:goodies/xml' |
|
12186 | 431 |
" |
9536 | 432 |
|
433 |
"Created: / 09-08-2006 / 17:44:47 / fm" |
|
434 |
"Modified: / 11-08-2006 / 14:00:05 / cg" |
|
435 |
! |
|
436 |
||
437 |
libraryName |
|
9575 | 438 |
^ self package asPackageId libraryName |
9536 | 439 |
|
9559 | 440 |
" |
9688 | 441 |
bosch_dapasx_datenbasis libraryName |
9575 | 442 |
stx_libbasic3 libraryName |
9559 | 443 |
" |
9536 | 444 |
|
445 |
"Modified: / 09-08-2006 / 18:20:29 / fm" |
|
9575 | 446 |
"Modified: / 18-08-2006 / 12:36:45 / cg" |
9536 | 447 |
! |
448 |
||
13419 | 449 |
libraryNameFor:aProjectID |
9575 | 450 |
^ aProjectID asPackageId libraryName |
9536 | 451 |
|
9559 | 452 |
" |
9575 | 453 |
bosch_dapasx_datenbasis libraryName |
454 |
stx_libbasic3 libraryNameFor:'stx:libbasic' |
|
13419 | 455 |
stx_libbasic3 libraryNameFor:'bosch:dapasx/datenbasis' |
9559 | 456 |
" |
9536 | 457 |
|
458 |
"Modified: / 09-08-2006 / 18:20:29 / fm" |
|
9575 | 459 |
"Modified: / 18-08-2006 / 12:37:02 / cg" |
9536 | 460 |
! |
461 |
||
462 |
module |
|
9559 | 463 |
^ self moduleOfClass:self |
9536 | 464 |
|
9559 | 465 |
" |
466 |
bosch_dapasx_datenbasis_Definition module |
|
467 |
DapasX_Datenbasis module |
|
13419 | 468 |
stx_libbasic3 module |
469 |
stx_libbasic3 directory |
|
9559 | 470 |
" |
9536 | 471 |
|
472 |
"Created: / 08-08-2006 / 20:24:53 / fm" |
|
473 |
"Modified: / 09-08-2006 / 16:16:37 / fm" |
|
9575 | 474 |
"Modified: / 17-08-2006 / 20:50:46 / cg" |
9536 | 475 |
! |
476 |
||
477 |
moduleDirectory |
|
9575 | 478 |
^ (PackageId from:self package) directory |
9536 | 479 |
|
9559 | 480 |
" |
9575 | 481 |
bosch_dapasx_datenbasis_Definition moduleDirectory |
482 |
bosch_dapasx_parameter_system_Definition moduleDirectory |
|
13419 | 483 |
stx_libbasic3 moduleDirectory |
484 |
cg_croquet moduleDirectory |
|
485 |
cg_croquet package asPackageId module |
|
486 |
cg_croquet moduleDirectory |
|
487 |
stx_goodies_xml_vw moduleDirectory |
|
9559 | 488 |
" |
9536 | 489 |
|
490 |
"Created: / 08-08-2006 / 20:25:39 / fm" |
|
9575 | 491 |
"Modified: / 18-08-2006 / 12:18:33 / cg" |
9536 | 492 |
! |
493 |
||
13419 | 494 |
moduleDirectoryFor:aProjectID |
9559 | 495 |
^ (aProjectID subStrings:$:) last |
9536 | 496 |
|
9559 | 497 |
" |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
498 |
bosch_dapasx_datenbasis_Definition moduleDirectory |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
499 |
bosch_dapasx_parameter_system_Definition moduleDirectory |
9559 | 500 |
" |
9536 | 501 |
|
502 |
"Created: / 08-08-2006 / 20:25:39 / fm" |
|
9559 | 503 |
"Modified: / 17-08-2006 / 14:13:41 / cg" |
9536 | 504 |
! |
505 |
||
9891 | 506 |
moduleDirectory_win32 |
507 |
^ (PackageId from:self package) directory copy replaceAll:$/ with:$\ |
|
508 |
||
509 |
" |
|
510 |
bosch_dapasx_datenbasis moduleDirectory_win32 |
|
511 |
bosch_dapasx_parameter_system moduleDirectory_win32 |
|
13419 | 512 |
stx_libbasic3 moduleDirectory_win32 |
9891 | 513 |
" |
514 |
||
515 |
"Created: / 14-09-2006 / 20:19:17 / cg" |
|
516 |
! |
|
517 |
||
10562 | 518 |
moduleDirectory_win32For: projectID |
519 |
||
520 |
^(self moduleDirectoryFor:projectID) copy replaceAll:$/ with:$\ |
|
521 |
||
522 |
" |
|
523 |
self moduleDirectory_win32For: #'bosch:dapasx/pav_vergleich' |
|
524 |
self moduleDirectory_win32For: #'stx:goodies/xml/stx' |
|
525 |
self moduleDirectory_win32For: #'stx:libbasic2' |
|
526 |
" |
|
527 |
! |
|
528 |
||
13419 | 529 |
moduleFor:aProjectID |
9559 | 530 |
^ (aProjectID subStrings:$:) first |
9536 | 531 |
|
9559 | 532 |
" |
533 |
DapasXProject module |
|
534 |
DapasX_Datenbasis module |
|
535 |
" |
|
9536 | 536 |
|
537 |
"Created: / 09-08-2006 / 16:16:16 / fm" |
|
9559 | 538 |
"Modified: / 17-08-2006 / 14:13:46 / cg" |
9536 | 539 |
! |
540 |
||
13419 | 541 |
moduleOfClass:aClass |
9559 | 542 |
^ self moduleFor:aClass package |
9536 | 543 |
|
9559 | 544 |
" |
545 |
DapasXProject module |
|
546 |
DapasX_Datenbasis module |
|
547 |
" |
|
9536 | 548 |
|
549 |
"Created: / 09-08-2006 / 16:16:16 / fm" |
|
9559 | 550 |
"Modified: / 17-08-2006 / 14:13:51 / cg" |
9536 | 551 |
! |
552 |
||
12360
18b9a4b30466
preps to allow for monticello packages to be loaded
Claus Gittinger <cg@exept.de>
parents:
12357
diff
changeset
|
553 |
monticelloPackageName |
18b9a4b30466
preps to allow for monticello packages to be loaded
Claus Gittinger <cg@exept.de>
parents:
12357
diff
changeset
|
554 |
"hook for packages which have been loaded from monticello" |
18b9a4b30466
preps to allow for monticello packages to be loaded
Claus Gittinger <cg@exept.de>
parents:
12357
diff
changeset
|
555 |
|
18b9a4b30466
preps to allow for monticello packages to be loaded
Claus Gittinger <cg@exept.de>
parents:
12357
diff
changeset
|
556 |
^ nil |
18b9a4b30466
preps to allow for monticello packages to be loaded
Claus Gittinger <cg@exept.de>
parents:
12357
diff
changeset
|
557 |
! |
18b9a4b30466
preps to allow for monticello packages to be loaded
Claus Gittinger <cg@exept.de>
parents:
12357
diff
changeset
|
558 |
|
9559 | 559 |
msdosPathToPackage:toPackageID from:fromPackageID |
560 |
"Returns the path to the package defined by aPackageID relative to my path" |
|
13419 | 561 |
|
10976
5696faf1af02
fix #msdosPathToPackage:from: (do not use , since it is relative to the current directory)
Stefan Vogel <sv@exept.de>
parents:
10974
diff
changeset
|
562 |
|parts1 parts2 common up down| |
9852 | 563 |
|
564 |
parts1 := fromPackageID asCollectionOfSubstringsSeparatedByAny:':/'. |
|
565 |
parts2 := toPackageID asCollectionOfSubstringsSeparatedByAny:':/'. |
|
566 |
common := parts1 commonPrefixWith:parts2. |
|
10976
5696faf1af02
fix #msdosPathToPackage:from: (do not use , since it is relative to the current directory)
Stefan Vogel <sv@exept.de>
parents:
10974
diff
changeset
|
567 |
up := ((1 to:parts1 size - common size) collect:[:p | '..']) asStringWith:'\'. |
5696faf1af02
fix #msdosPathToPackage:from: (do not use , since it is relative to the current directory)
Stefan Vogel <sv@exept.de>
parents:
10974
diff
changeset
|
568 |
down := (parts2 copyFrom:common size+1) asStringWith:'\'. |
5696faf1af02
fix #msdosPathToPackage:from: (do not use , since it is relative to the current directory)
Stefan Vogel <sv@exept.de>
parents:
10974
diff
changeset
|
569 |
up isEmpty ifTrue:[ |
5696faf1af02
fix #msdosPathToPackage:from: (do not use , since it is relative to the current directory)
Stefan Vogel <sv@exept.de>
parents:
10974
diff
changeset
|
570 |
down isEmpty ifTrue:[^ '.']. |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
571 |
^ down. |
9852 | 572 |
]. |
10976
5696faf1af02
fix #msdosPathToPackage:from: (do not use , since it is relative to the current directory)
Stefan Vogel <sv@exept.de>
parents:
10974
diff
changeset
|
573 |
down isEmpty ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
574 |
^ up. |
9714 | 575 |
]. |
13419 | 576 |
^ up, '\', down |
9901 | 577 |
|
9559 | 578 |
" |
579 |
self msdosPathToPackage:'bosch:dapasx/kernel' from:'bosch:dapasx/application' |
|
13419 | 580 |
self msdosPathToPackage:'stx:libbasic' from:'bosch:dapasx/application' |
581 |
self msdosPathToPackage:'bosch:dapasx/application' from:'stx:libbasic' |
|
582 |
self msdosPathToPackage:'exept:expecco' from:'exept:expecco/application' |
|
583 |
self msdosPathToPackage:'exept:expecco/application' from:'exept:expecco' |
|
9559 | 584 |
" |
9536 | 585 |
|
9559 | 586 |
"Created: / 17-08-2006 / 14:26:39 / cg" |
9901 | 587 |
"Modified: / 14-09-2006 / 22:04:56 / cg" |
9536 | 588 |
! |
589 |
||
9714 | 590 |
msdosPathToTopFor:aProjectID |
9559 | 591 |
"Returns the path to stx counting the number of $/ and $: in the package name and adding for each one '../' to get the ST/X top directory" |
9536 | 592 |
|
9852 | 593 |
|parts| |
594 |
||
595 |
parts := aProjectID asCollectionOfSubstringsSeparatedByAny:':/'. |
|
596 |
||
597 |
aProjectID asPackageId module = 'stx' ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
598 |
parts size == 1 ifTrue:[^ '.']. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
599 |
^ (((2 to:parts size-1) collect:[:p | '..\']) asStringWith:'') , '..' |
9852 | 600 |
]. |
601 |
||
13419 | 602 |
^ ((parts collect:[:p | '..\']) asStringWith:'') , 'stx' |
603 |
||
604 |
" |
|
605 |
self msdosPathToTopFor: #'bosch' |
|
606 |
self msdosPathToTopFor: #'bosch:dapasx' |
|
607 |
self msdosPathToTopFor: #'bosch:dapasx/datenbasis' |
|
608 |
self msdosPathToTopFor: #'stx' |
|
609 |
self msdosPathToTopFor: #'stx:libview' |
|
610 |
self msdosPathToTopFor: #'stx:goodies/foo' |
|
9559 | 611 |
" |
9536 | 612 |
|
613 |
"Created: / 09-08-2006 / 15:45:54 / fm" |
|
9852 | 614 |
"Modified: / 14-09-2006 / 14:49:17 / cg" |
9559 | 615 |
! |
616 |
||
12028 | 617 |
packageDirectory |
618 |
||
12315
71599fb91dcf
comment/format in: #packageDirectory
Claus Gittinger <cg@exept.de>
parents:
12314
diff
changeset
|
619 |
^ Smalltalk packageDirectoryForPackageId: self package |
12028 | 620 |
|
621 |
"Created: / 15-06-2009 / 12:01:18 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
622 |
! |
|
623 |
||
9536 | 624 |
packageName |
9688 | 625 |
"the last component" |
9536 | 626 |
|
9688 | 627 |
^ self packageNameFor: self package |
9536 | 628 |
|
9688 | 629 |
" |
10810 | 630 |
stx_libwidg2 packageName |
9688 | 631 |
bosch_dapasx_hw_schnittstellen packageName |
632 |
bosch_dapasx_datenbasis packageName |
|
13419 | 633 |
bosch_dapasx_parameter_system packageName |
9688 | 634 |
" |
9536 | 635 |
|
636 |
"Created: / 08-08-2006 / 20:24:53 / fm" |
|
637 |
"Modified: / 09-08-2006 / 16:16:37 / fm" |
|
638 |
! |
|
639 |
||
640 |
packageNameFor: aProjectID |
|
9688 | 641 |
^ (aProjectID asCollectionOfSubstringsSeparatedByAny:':/') last. |
9536 | 642 |
|
9688 | 643 |
" |
644 |
bosch_dapasx_hw_schnittstellen packageName |
|
645 |
bosch_dapasx_datenbasis packageName |
|
13419 | 646 |
bosch_dapasx_parameter_system packageName |
647 |
cg_croquet packageName |
|
648 |
stx_goodies_xml_vw packageName |
|
649 |
stx_goodies_xml_vw packageDirectory |
|
9688 | 650 |
" |
9536 | 651 |
|
652 |
"Created: / 08-08-2006 / 20:24:53 / fm" |
|
653 |
"Modified: / 09-08-2006 / 16:16:37 / fm" |
|
654 |
"Modified: / 11-08-2006 / 14:02:32 / cg" |
|
655 |
! |
|
656 |
||
657 |
parentProject |
|
10306 | 658 |
^ (self parentProjectFor: self package) |
9536 | 659 |
|
660 |
" |
|
661 |
bosch_dapasx_hw_schnittstellen_Definition parentProject |
|
662 |
DapasX_Datenbasis parentProject |
|
663 |
" |
|
664 |
||
665 |
"Created: / 07-08-2006 / 20:18:27 / fm" |
|
666 |
"Modified: / 08-08-2006 / 10:47:37 / fm" |
|
667 |
! |
|
668 |
||
669 |
parentProjectFor: aProjectID |
|
10306 | 670 |
^ (aProjectID subStrings: $/) first |
9536 | 671 |
|
672 |
" |
|
9664 | 673 |
bosch_dapasx_hw_schnittstellen parentProject |
9536 | 674 |
" |
675 |
||
676 |
"Created: / 07-08-2006 / 20:18:27 / fm" |
|
677 |
"Modified: / 08-08-2006 / 10:47:37 / fm" |
|
9664 | 678 |
"Modified: / 23-08-2006 / 15:07:36 / cg" |
9536 | 679 |
! |
680 |
||
10366
8990764f8911
#compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents:
10350
diff
changeset
|
681 |
pathSeparator:platformName |
8990764f8911
#compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents:
10350
diff
changeset
|
682 |
platformName == #unix ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
683 |
^ self pathSeparator_unix |
9850 | 684 |
]. |
10366
8990764f8911
#compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents:
10350
diff
changeset
|
685 |
platformName == #win32 ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
686 |
^ self pathSeparator_win32 |
9850 | 687 |
]. |
10366
8990764f8911
#compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents:
10350
diff
changeset
|
688 |
self error:'unknown operating system platform'. |
9850 | 689 |
|
690 |
"Created: / 14-09-2006 / 13:38:00 / cg" |
|
691 |
! |
|
692 |
||
693 |
pathSeparator_unix |
|
694 |
^ $/ |
|
695 |
||
696 |
"Created: / 14-09-2006 / 13:37:18 / cg" |
|
697 |
! |
|
698 |
||
699 |
pathSeparator_win32 |
|
700 |
^ $\ |
|
701 |
||
702 |
"Created: / 14-09-2006 / 13:37:23 / cg" |
|
703 |
! |
|
704 |
||
705 |
pathTo:aBaseFilename inPackage:aPackageID architecture:arch |
|
706 |
"Returns the path to stx counting the number of $/ and $: in the package name and adding for each one '../' to get the ST/X top directory" |
|
707 |
||
708 |
|p| |
|
709 |
||
710 |
arch == #unix ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
711 |
p := (self pathToPackage_unix:aPackageID). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
712 |
aBaseFilename isNil ifTrue:[^ p]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
713 |
^ p , '/' , aBaseFilename |
9850 | 714 |
]. |
715 |
arch == #win32 ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
716 |
p := self pathToPackage_win32:aPackageID. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
717 |
aBaseFilename isNil ifTrue:[^ p]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
718 |
^ p , '\' , aBaseFilename |
9850 | 719 |
]. |
10366
8990764f8911
#compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents:
10350
diff
changeset
|
720 |
self error:'unknown operating system platform'. |
9850 | 721 |
|
722 |
"Created: / 14-09-2006 / 13:29:20 / cg" |
|
723 |
! |
|
724 |
||
725 |
pathToPackage_unix:aPackageID |
|
726 |
"Returns the path to stx counting the number of $/ and $: in the package name and adding for each one '../' to get the ST/X top directory" |
|
727 |
||
10875
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
728 |
|rel| |
9850 | 729 |
|
9880 | 730 |
aPackageID asPackageId module = self package asPackageId module ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
731 |
^ self unixPathToPackage:aPackageID from:self package |
9880 | 732 |
]. |
10875
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
733 |
rel := self topRelativePathToPackage_unix:aPackageID. |
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
734 |
(rel startsWith:'stx/') ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
735 |
^ '$(TOP)/', (rel copyFrom:'stx/' size + 1). |
9850 | 736 |
] ifFalse:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
737 |
^ '$(TOP)/../', rel |
9850 | 738 |
] |
739 |
||
740 |
" |
|
13419 | 741 |
bosch_dapasx_kernel pathToPackage_unix:'bosch:dapasx/kernel' |
742 |
bosch_dapasx_kernel pathToPackage_unix:'bosch:dapasx/support' |
|
743 |
stx_libbasic pathToPackage_unix:'bosch:dapasx/kernel' |
|
9850 | 744 |
" |
745 |
||
746 |
"Modified: / 16-08-2006 / 18:55:41 / User" |
|
747 |
"Created: / 14-09-2006 / 13:21:23 / cg" |
|
9880 | 748 |
"Modified: / 14-09-2006 / 15:23:59 / cg" |
9850 | 749 |
! |
750 |
||
13419 | 751 |
pathToPackage_win32:aPackageID |
9850 | 752 |
"Returns the path to the package defined by aPackageID relative to my path" |
13419 | 753 |
|
10875
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
754 |
|rel| |
9850 | 755 |
|
9880 | 756 |
aPackageID asPackageId module = self package asPackageId module ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
757 |
^ self msdosPathToPackage:aPackageID from:self package |
9880 | 758 |
]. |
759 |
||
10875
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
760 |
rel := self topRelativePathToPackage_win32:aPackageID. |
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
761 |
(rel startsWith:'stx\') ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
762 |
^ '$(TOP)\', (rel copyFrom:'stx\' size + 1). |
9850 | 763 |
] ifFalse:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
764 |
^ '$(TOP)\..\', rel |
10875
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
765 |
] |
9850 | 766 |
|
767 |
" |
|
13419 | 768 |
self pathToPackage_win32:'bosch:dapasx/kernel' |
769 |
bosch_dapasx_kernel pathToPackage_win32:'bosch:dapasx/kernel' |
|
770 |
bosch_dapasx_kernel pathToPackage_win32:'bosch:dapasx/support' |
|
771 |
stx_libbasic pathToPackage_win32:'bosch:dapasx/kernel' |
|
9850 | 772 |
" |
773 |
||
774 |
"Created: / 14-09-2006 / 13:22:52 / cg" |
|
9880 | 775 |
"Modified: / 14-09-2006 / 15:28:45 / cg" |
9850 | 776 |
! |
777 |
||
9714 | 778 |
pathToTop_unix |
779 |
"Returns the path to stx counting the number of $/ and $: in the package name and adding for each one '../' to get the ST/X top directory" |
|
780 |
||
9852 | 781 |
^ self unixPathToTopFor:self package. |
9714 | 782 |
|
783 |
" |
|
13419 | 784 |
bosch_dapasx_kernel pathToTop_unix |
785 |
stx_goodies_xml pathToTop_unix |
|
786 |
stx_libhtml pathToTop_unix |
|
787 |
stx_goodies_refactoryBrowser_changes pathToTop_unix |
|
9714 | 788 |
" |
789 |
||
790 |
"Created: / 09-08-2006 / 15:45:54 / fm" |
|
9852 | 791 |
"Modified: / 14-09-2006 / 15:01:47 / cg" |
9714 | 792 |
! |
793 |
||
794 |
pathToTop_win32 |
|
795 |
"Returns the path to stx counting the number of $/ and $: in the package name and adding for each one '../' to get the ST/X top directory" |
|
796 |
||
13419 | 797 |
^self msdosPathToTopFor: self package |
798 |
||
799 |
" |
|
800 |
bosch_dapasx_datenbasis pathToTop_win32 |
|
801 |
stx_libbasic pathToTop_win32 |
|
9714 | 802 |
" |
803 |
||
804 |
"Created: / 09-08-2006 / 15:45:54 / fm" |
|
9831 | 805 |
"Modified: / 07-09-2006 / 15:51:00 / cg" |
9714 | 806 |
! |
807 |
||
10433
4768502f5cbf
Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents:
10430
diff
changeset
|
808 |
projectIsLoaded |
4768502f5cbf
Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents:
10430
diff
changeset
|
809 |
"answer true, if this project is completely loaded into the image" |
4768502f5cbf
Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents:
10430
diff
changeset
|
810 |
|
10434
25f76184bf81
project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents:
10433
diff
changeset
|
811 |
projectIsLoaded isNil ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
812 |
projectIsLoaded := false. |
10433
4768502f5cbf
Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents:
10430
diff
changeset
|
813 |
]. |
10434
25f76184bf81
project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents:
10433
diff
changeset
|
814 |
^ projectIsLoaded |
10433
4768502f5cbf
Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents:
10430
diff
changeset
|
815 |
|
4768502f5cbf
Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents:
10430
diff
changeset
|
816 |
" |
4768502f5cbf
Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents:
10430
diff
changeset
|
817 |
stx_libbasic projectIsLoaded |
13251 | 818 |
(ProjectDefinition definitionClassForPackage:#'stx:libbasic') projectIsLoaded |
10433
4768502f5cbf
Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents:
10430
diff
changeset
|
819 |
" |
4768502f5cbf
Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents:
10430
diff
changeset
|
820 |
! |
4768502f5cbf
Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents:
10430
diff
changeset
|
821 |
|
4768502f5cbf
Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents:
10430
diff
changeset
|
822 |
projectIsLoaded:something |
10434
25f76184bf81
project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents:
10433
diff
changeset
|
823 |
projectIsLoaded := something. |
13251 | 824 |
something ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
825 |
"register myself as dependent - I want to get notified on method changes" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
826 |
self class addDependent:self. |
10434
25f76184bf81
project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents:
10433
diff
changeset
|
827 |
]. |
10433
4768502f5cbf
Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents:
10430
diff
changeset
|
828 |
! |
4768502f5cbf
Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents:
10430
diff
changeset
|
829 |
|
9536 | 830 |
requiredProjects |
11479 | 831 |
^ self effectivePreRequisites , self subProjects |
9536 | 832 |
! |
833 |
||
9850 | 834 |
topRelativePathTo:aBaseFilename inPackage:aPackageID architecture:arch |
13419 | 835 |
"Returns the path to stx counting the number of $/ and $: in the package name |
10366
8990764f8911
#compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents:
10350
diff
changeset
|
836 |
and adding for each one '../' to get the ST/X top directory" |
9850 | 837 |
|
838 |
|p| |
|
839 |
||
840 |
arch == #unix ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
841 |
p := (self topRelativePathToPackage_unix:aPackageID). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
842 |
aBaseFilename isNil ifTrue:[^ p]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
843 |
^ p , '/' , aBaseFilename |
9850 | 844 |
]. |
845 |
arch == #win32 ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
846 |
p := self topRelativePathToPackage_win32:aPackageID. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
847 |
aBaseFilename isNil ifTrue:[^ p]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
848 |
^ p , '\' , aBaseFilename |
9850 | 849 |
]. |
10366
8990764f8911
#compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents:
10350
diff
changeset
|
850 |
self error:'unknown operating system platform'. |
9850 | 851 |
|
852 |
"Created: / 14-09-2006 / 13:34:05 / cg" |
|
853 |
! |
|
854 |
||
13419 | 855 |
topRelativePathToPackage_unix:aPackageID |
9850 | 856 |
"Returns the path to the package as specified by aPackageID relative to the top directory" |
13419 | 857 |
|
9850 | 858 |
^ aPackageID asString copy replaceAny:':/' with:$/ |
859 |
||
860 |
" |
|
861 |
self topRelativePathToPackage_unix:'stx:goodies/xml' |
|
862 |
self topRelativePathToPackage_unix:'bosch:dapasx/kernel' |
|
863 |
" |
|
864 |
||
865 |
"Created: / 14-09-2006 / 13:20:40 / cg" |
|
866 |
! |
|
867 |
||
13419 | 868 |
topRelativePathToPackage_win32:aPackageID |
9559 | 869 |
"Returns the path to the package as specified by aPackageID relative to the top directory" |
13419 | 870 |
|
9559 | 871 |
^ aPackageID asString copy replaceAny:':/' with:$\ |
872 |
||
873 |
" |
|
9850 | 874 |
self topRelativePathToPackage_win32:'stx:goodies/xml' |
875 |
self topRelativePathToPackage_win32:'bosch:dapasx/kernel' |
|
9559 | 876 |
" |
9536 | 877 |
|
9850 | 878 |
"Created: / 14-09-2006 / 13:20:12 / cg" |
9852 | 879 |
! |
880 |
||
9880 | 881 |
unixPathToPackage:toPackageID from:fromPackageID |
882 |
"Returns the path to the package defined by aPackageID relative to my path" |
|
13419 | 883 |
|
10875
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
884 |
|parts1 parts2 common up down rel| |
9880 | 885 |
|
886 |
parts1 := fromPackageID asCollectionOfSubstringsSeparatedByAny:':/'. |
|
887 |
parts2 := toPackageID asCollectionOfSubstringsSeparatedByAny:':/'. |
|
888 |
common := parts1 commonPrefixWith:parts2. |
|
889 |
common notEmpty ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
890 |
up := ((1 to:parts1 size - common size) collect:[:p | '../']) asStringWith:''. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
891 |
down := (parts2 copyFrom:common size+1) asStringWith:'/'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
892 |
(up isEmpty and:[down isEmpty]) ifTrue:[^ '.']. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
893 |
^ up , down |
9880 | 894 |
]. |
895 |
||
10875
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
896 |
rel := (self topRelativePathToPackage_unix:toPackageID). |
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
897 |
(rel startsWith:'stx/') ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
898 |
^ '$(TOP)', (rel copyFrom:'stx/' size) |
9880 | 899 |
]. |
10875
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
900 |
|
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
901 |
^ '$(TOP)/../', rel. |
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
902 |
|
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
903 |
"/ pTop := self unixPathToTopFor:fromPackageID. |
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
904 |
"/ (pTop endsWith:'/stx') ifTrue:[ |
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
905 |
"/ pTop := pTop copyButLast:'stx' size. |
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
906 |
"/ ] ifFalse:[ |
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
907 |
"/ pTop isEmpty ifTrue:[ |
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
908 |
"/ pTop := '../'. |
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
909 |
"/ ] ifFalse:[ |
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
910 |
"/ pTop := pTop, '/../'. |
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
911 |
"/ ]. |
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
912 |
"/ ]. |
ed4bd37a995e
Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents:
10872
diff
changeset
|
913 |
"/ ^ pTop, (self topRelativePathToPackage_unix:toPackageID) |
9880 | 914 |
|
915 |
" |
|
10713 | 916 |
self unixPathToPackage:'bosch:dapasx/kernel' from:'bosch:dapasx/application' |
13419 | 917 |
self unixPathToPackage:'stx:libbasic' from:'bosch:dapasx/application' |
918 |
self unixPathToPackage:'bosch:dapasx/application' from:'stx:libbasic' |
|
9880 | 919 |
" |
920 |
||
921 |
"Created: / 14-09-2006 / 15:21:10 / cg" |
|
922 |
! |
|
923 |
||
9852 | 924 |
unixPathToTopFor:aProjectID |
925 |
"Returns the path to stx counting the number of $/ and $: in the package name and adding for each one '../' to get the ST/X top directory" |
|
926 |
||
927 |
|parts| |
|
928 |
||
929 |
parts := aProjectID asCollectionOfSubstringsSeparatedByAny:':/'. |
|
930 |
||
931 |
aProjectID asPackageId module = 'stx' ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
932 |
parts size == 1 ifTrue:[^ '']. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
933 |
^ (((2 to:parts size-1) collect:[:p | '../']) asStringWith:'') , '..' |
9852 | 934 |
]. |
935 |
||
13419 | 936 |
^ ((parts collect:[:p | '../']) asStringWith:'') , 'stx' |
937 |
||
938 |
" |
|
939 |
self unixPathToTopFor: #'bosch' |
|
940 |
self unixPathToTopFor: #'bosch:dapasx' |
|
941 |
self unixPathToTopFor: #'bosch:dapasx/datenbasis' |
|
942 |
self unixPathToTopFor: #'stx' |
|
943 |
self unixPathToTopFor: #'stx:libview' |
|
944 |
self unixPathToTopFor: #'stx:goodies/foo' |
|
9852 | 945 |
" |
946 |
||
947 |
"Created: / 14-09-2006 / 14:59:53 / cg" |
|
9536 | 948 |
! ! |
949 |
||
12339
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
950 |
!ProjectDefinition class methodsFor:'accessing - packaging'! |
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
951 |
|
12371 | 952 |
classNames:aCollectionOfClassNames |
953 |
"set the set of classes" |
|
954 |
||
955 |
self classNamesAndAttributes:aCollectionOfClassNames usingCompiler:nil |
|
956 |
! |
|
957 |
||
958 |
classNamesAndAttributes:newSpec usingCompiler:compilerOrNil |
|
13419 | 959 |
"set the set of classes. and attributes |
960 |
Because this requires compilation of my classList-method, a compiler can be passed in, |
|
12371 | 961 |
which has to do the job. |
962 |
(this is used by the systembrowser to pass in a CodeGeneratorTool with undo support)" |
|
963 |
||
964 |
|oldSpec newCode| |
|
965 |
||
966 |
oldSpec := self classNamesAndAttributes. |
|
967 |
newSpec = oldSpec ifTrue: [^ self]. |
|
968 |
||
969 |
newCode := self classNamesAndAttributes_codeFor:newSpec. |
|
970 |
||
971 |
(compilerOrNil ? self compilerClass) |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
972 |
compile:newCode |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
973 |
forClass:self theMetaclass |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
974 |
inCategory:'description - contents'. |
12371 | 975 |
! |
976 |
||
12339
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
977 |
excludeClasses:toExclude usingCompiler:compilerOrNil |
13419 | 978 |
"exclude (remove from classList) a number of classes. |
979 |
Because this requires compilation of my classList-method, a compiler can be passed in, |
|
12339
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
980 |
which has to do the job. |
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
981 |
(this is used by the systembrowser to pass in a CodeGeneratorTool with undo support)" |
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
982 |
|
12371 | 983 |
|newSpec| |
984 |
||
985 |
newSpec := self classNamesAndAttributes copy. |
|
12339
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
986 |
|
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
987 |
toExclude do:[:eachClassToExclude | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
988 |
|className| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
989 |
className := eachClassToExclude theNonMetaclass name. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
990 |
(self allClassNames includes:className) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
991 |
|idx| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
992 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
993 |
idx := newSpec findFirst:[:entry | entry = className or:[entry first = className]]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
994 |
idx ~~ 0 ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
995 |
newSpec := newSpec copyWithoutIndex:idx. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
996 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
997 |
]. |
12339
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
998 |
]. |
12371 | 999 |
self classNamesAndAttributes:newSpec usingCompiler:compilerOrNil |
12339
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1000 |
|
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1001 |
"Created: / 30-08-2007 / 18:28:28 / cg" |
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1002 |
! |
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1003 |
|
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1004 |
includeClasses:toInclude usingCompiler:compilerOrNil |
13419 | 1005 |
"include (add to classList) a number of classes. |
1006 |
Because this requires compilation of my classList-method, a compiler can be passed in, |
|
12339
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1007 |
which has to do the job. |
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1008 |
(this is used by the systembrowser to pass in a CodeGeneratorTool with undo support)" |
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1009 |
|
12371 | 1010 |
|oldSpec newSpec| |
12339
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1011 |
|
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1012 |
oldSpec := self classNamesAndAttributes. |
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1013 |
newSpec := oldSpec copy. |
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1014 |
|
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1015 |
toInclude do:[:eachClassToInclude | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1016 |
|className| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1017 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1018 |
className := eachClassToInclude theNonMetaclass name. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1019 |
(self compiled_classNames includes:className) ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1020 |
| idx entry| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1021 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1022 |
idx := oldSpec findFirst:[:entry | entry = className or:[entry first = className]]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1023 |
idx == 0 ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1024 |
newSpec := newSpec copyWith:(Array with:className) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1025 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1026 |
entry := newSpec at:idx. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1027 |
entry isArray ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1028 |
entry := entry copyWithout:#autoload |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1029 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1030 |
newSpec at:idx put:entry |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1031 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1032 |
]. |
12339
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1033 |
]. |
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1034 |
|
12371 | 1035 |
self classNamesAndAttributes:newSpec usingCompiler:compilerOrNil |
12339
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1036 |
! |
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1037 |
|
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1038 |
makeClassesAutoloaded:toMakeAutoloaded usingCompiler:compilerOrNil |
13419 | 1039 |
"include as autoloaded (add to classList) a number of classes. |
1040 |
Because this requires compilation of my classList-method, a compiler can be passed in, |
|
12339
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1041 |
which has to do the job. |
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1042 |
(this is used by the systembrowser to pass in a CodeGeneratorTool with undo support)" |
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1043 |
|
12371 | 1044 |
|newSpec| |
1045 |
||
1046 |
newSpec := self classNamesAndAttributes copy. |
|
12339
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1047 |
|
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1048 |
toMakeAutoloaded do:[:eachClassToMakeAutoloaded | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1049 |
|className| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1050 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1051 |
className := eachClassToMakeAutoloaded theNonMetaclass name. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1052 |
(self autoloaded_classNames includes:className) ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1053 |
|idx entry| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1054 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1055 |
idx := newSpec findFirst:[:entry | entry = className or:[entry first = className]]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1056 |
idx == 0 ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1057 |
newSpec := newSpec copyWith:(Array with:className with:#autoload) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1058 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1059 |
entry := newSpec at:idx. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1060 |
entry isArray ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1061 |
entry := (entry copyWithout:#autoload) copyWith:#autoload. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1062 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1063 |
entry := Array with:entry with:#autoload |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1064 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1065 |
newSpec at:idx put:entry. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1066 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1067 |
]. |
12339
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1068 |
]. |
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1069 |
|
12371 | 1070 |
self classNamesAndAttributes:newSpec usingCompiler:compilerOrNil |
12339
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1071 |
! ! |
918b3eddd723
#excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents:
12338
diff
changeset
|
1072 |
|
12028 | 1073 |
!ProjectDefinition class methodsFor:'accessing - svn'! |
1074 |
||
1075 |
svnRevision |
|
1076 |
||
1077 |
" |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1078 |
Answers SVN revision of given package. The revision is computed |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1079 |
as follows: |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1080 |
1) Look at package directory if there is .svn administration |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1081 |
directory. If so, uses SVN to obtain SVN revision & return |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1082 |
2) If svnRevisionNr return non-nil, use that as SVN revision & return |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1083 |
3) If everything fails, compute maximum from all revision of all |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1084 |
classes & extensions |
12028 | 1085 |
" |
1086 |
| pkgDir revNr | |
|
1087 |
||
1088 |
"1)" |
|
1089 |
pkgDir := self packageDirectory. |
|
1090 |
(pkgDir notNil and: [pkgDir exists and: [(pkgDir / '.svn') exists]]) ifTrue: |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1091 |
[[revNr := (SVN::InfoCommand new |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1092 |
workingCopy: (SVN::WorkingCopy branch: (SVN::Branch new) path: pkgDir); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1093 |
execute) anyOne revision] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1094 |
value |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1095 |
"/on: Error do: [revNr := nil] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1096 |
]. |
12028 | 1097 |
revNr ifNotNil:[^SVN::Revision number:revNr]. |
1098 |
"2)" |
|
1099 |
"We have to explicitly check for existence of svnRevisionNr, |
|
1100 |
because we don't want to invoke inherited method" |
|
1101 |
(self class methodDictionary includesKey: #svnRevisionNr) |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1102 |
ifTrue:[revNr := self perform:#svnRevisionNr]. |
12028 | 1103 |
revNr ifNotNil:[^SVN::Revision number:(revNr asString select:[:e|e isDigit])]. |
1104 |
||
1105 |
"3)" |
|
1106 |
revNr := (self searchForClassesWithProject: self package) |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1107 |
inject: 0 |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1108 |
into: |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1109 |
[:rev :cls| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1110 |
((cls revision ? '.') includes: $.)"/ CVS revision number? |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1111 |
ifTrue:[rev] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1112 |
ifFalse:[rev max: (cls revision ? '0') asNumber]]. |
12028 | 1113 |
^revNr ~= 0 |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1114 |
ifTrue: [SVN::Revision number:revNr] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1115 |
ifFalse:[SVN::Revision head] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1116 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1117 |
" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1118 |
stx_libbasic svnRevision |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1119 |
stx_goodies_libsvn svnRevision |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1120 |
stx_goodies_libsvn revision |
12028 | 1121 |
|
1122 |
" |
|
1123 |
||
1124 |
"Created: / 15-06-2009 / 11:54:33 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
1125 |
"Modified: / 22-08-2009 / 09:06:29 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
13411 | 1126 |
"Modified: / 13-02-2010 / 19:27:13 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
1127 |
! ! |
|
1128 |
||
1129 |
!ProjectDefinition class methodsFor:'accessing - tests'! |
|
1130 |
||
13419 | 1131 |
excludedFromTestSuite |
13411 | 1132 |
"List of testcases and/or tests excluded from testsuite. |
1133 |
Entries maybe ClassName or #(ClassName testName) |
|
1134 |
" |
|
1135 |
^ #() |
|
1136 |
||
1137 |
"Created: / 03-06-2011 / 16:56:48 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
1138 |
! |
|
1139 |
||
1140 |
testSuite |
|
13544 | 1141 |
"generate and return a testSuite containing all of my test-classes" |
13411 | 1142 |
|
1143 |
|suite classes| |
|
1144 |
||
1145 |
suite := TestSuite named:self package. |
|
13695 | 1146 |
classes := self classes |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1147 |
select:[:each | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1148 |
each isLoaded ifFalse:[each autoload]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1149 |
(each isTestCaseLike) and:[ each isAbstract not ] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1150 |
]. |
13544 | 1151 |
|
13411 | 1152 |
classes := classes asSortedCollection:[:a :b | a name <= b name ]. |
13695 | 1153 |
classes do: [:eachClass | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1154 |
| tests | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1155 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1156 |
tests := eachClass suite tests. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1157 |
tests := tests reject:[:test|self shouldExcludeTest: test]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1158 |
suite addTests: tests |
13544 | 1159 |
]. |
1160 |
^ suite |
|
13411 | 1161 |
|
1162 |
"Created: / 01-04-2011 / 15:20:02 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
1163 |
"Modified: / 03-06-2011 / 17:07:04 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
13568 | 1164 |
"Modified: / 08-08-2011 / 14:59:45 / cg" |
12028 | 1165 |
! ! |
1166 |
||
9714 | 1167 |
!ProjectDefinition class methodsFor:'class initialization'! |
1168 |
||
1169 |
initialize |
|
1170 |
LibraryType := #'Library'. |
|
1171 |
GUIApplicationType := #'GUI-Application'. |
|
1172 |
NonGUIApplicationType := #'NonGUI-Application'. |
|
13592 | 1173 |
AccessLock := Semaphore forMutualExclusion. |
14021 | 1174 |
Verbose := false. |
9714 | 1175 |
|
10121 | 1176 |
" |
1177 |
self initialize |
|
1178 |
" |
|
1179 |
||
13592 | 1180 |
"Modified: / 18-08-2011 / 13:48:31 / cg" |
10121 | 1181 |
! |
1182 |
||
1183 |
initializeAllProjectDefinitions |
|
1184 |
"needs everything else (especially the compiler etc.) to be initialized. |
|
1185 |
Therefore, its not invoked by #initialize, but instead explicitely, |
|
1186 |
by Smalltalk" |
|
13695 | 1187 |
|
13609 | 1188 |
|isStandAloneApp| |
1189 |
||
1190 |
isStandAloneApp := Smalltalk isStandAloneApp. |
|
1191 |
||
1192 |
self allSubclassesDo:[:eachProjectDefinitionClass | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1193 |
eachProjectDefinitionClass isAbstract ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1194 |
isStandAloneApp ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1195 |
eachProjectDefinitionClass installAutoloadedClasses. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1196 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1197 |
eachProjectDefinitionClass projectIsLoaded:true. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1198 |
] |
13609 | 1199 |
]. |
10115 | 1200 |
|
9714 | 1201 |
" |
1202 |
self initialize |
|
1203 |
" |
|
10113
78086bf25905
install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents:
10106
diff
changeset
|
1204 |
|
10121 | 1205 |
"Created: / 23-10-2006 / 16:40:53 / cg" |
10113
78086bf25905
install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents:
10106
diff
changeset
|
1206 |
! |
78086bf25905
install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents:
10106
diff
changeset
|
1207 |
|
78086bf25905
install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents:
10106
diff
changeset
|
1208 |
installAutoloadedClasses |
12372 | 1209 |
"install all of my autoloaded classes (if any)" |
1210 |
||
13610
ec7ea708ebd2
changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13609
diff
changeset
|
1211 |
|classesToFixClassFileName| |
ec7ea708ebd2
changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13609
diff
changeset
|
1212 |
|
ec7ea708ebd2
changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13609
diff
changeset
|
1213 |
classesToFixClassFileName := OrderedCollection new. |
ec7ea708ebd2
changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13609
diff
changeset
|
1214 |
|
13592 | 1215 |
self autoloaded_classNames do:[:className | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1216 |
|cls| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1217 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1218 |
"/ 'install as autoloaded: ' errorPrint. className errorPrintCR. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1219 |
(cls := Smalltalk classNamed:className) isNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1220 |
Error handle:[:ex | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1221 |
(self name,' [warning]: failed to install autoloaded: ',className) errorPrintCR. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1222 |
(self name,' [info]: reason: ',ex description) errorPrintCR. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1223 |
"/ thisContext fullPrintAll. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1224 |
] do:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1225 |
cls := Smalltalk |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1226 |
installAutoloadedClassNamed:className |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1227 |
category:'* as yet unknown category *' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1228 |
package:self package |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1229 |
revision:nil |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1230 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1231 |
cls notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1232 |
classesToFixClassFileName add:cls. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1233 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1234 |
]. |
13592 | 1235 |
]. |
10113
78086bf25905
install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents:
10106
diff
changeset
|
1236 |
|
13610
ec7ea708ebd2
changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13609
diff
changeset
|
1237 |
Smalltalk addStartBlock:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1238 |
|abbrevs| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1239 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1240 |
abbrevs := self abbrevs. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1241 |
"/ patch the classFileNames |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1242 |
classesToFixClassFileName do:[:cls | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1243 |
|entry classFilenameFromAbbreviations| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1244 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1245 |
entry := abbrevs at:cls name ifAbsent:nil. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1246 |
entry notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1247 |
classFilenameFromAbbreviations := entry fileName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1248 |
classFilenameFromAbbreviations notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1249 |
classFilenameFromAbbreviations := classFilenameFromAbbreviations,'.st'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1250 |
(classFilenameFromAbbreviations ~= cls getClassFilename) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1251 |
cls setClassFilename:classFilenameFromAbbreviations |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1252 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1253 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1254 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1255 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1256 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1257 |
"/ patch the categories |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1258 |
Class withoutUpdatingChangesDo:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1259 |
|entry| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1260 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1261 |
self classNames do:[:nm | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1262 |
|cls| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1263 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1264 |
((cls := Smalltalk at: nm) notNil |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1265 |
and:[ cls isLoaded not |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1266 |
and:[ (entry := abbrevs at:cls name ifAbsent:[nil]) notNil |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1267 |
]]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1268 |
cls category: (entry category) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1269 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1270 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1271 |
] |
13610
ec7ea708ebd2
changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13609
diff
changeset
|
1272 |
]. |
ec7ea708ebd2
changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13609
diff
changeset
|
1273 |
|
13411 | 1274 |
|
10113
78086bf25905
install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents:
10106
diff
changeset
|
1275 |
" |
78086bf25905
install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents:
10106
diff
changeset
|
1276 |
stx_libbasic installAutoloadedClasses |
12268
b3cd2af642f2
changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
12264
diff
changeset
|
1277 |
stx_libhtml installAutoloadedClasses |
13592 | 1278 |
stx_libtool2 installAutoloadedClasses |
10113
78086bf25905
install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents:
10106
diff
changeset
|
1279 |
" |
78086bf25905
install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents:
10106
diff
changeset
|
1280 |
|
78086bf25905
install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents:
10106
diff
changeset
|
1281 |
"Created: / 23-10-2006 / 16:02:12 / cg" |
13411 | 1282 |
"Modified: / 06-03-2011 / 18:26:58 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
13610
ec7ea708ebd2
changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13609
diff
changeset
|
1283 |
"Modified: / 20-08-2011 / 23:32:32 / cg" |
9714 | 1284 |
! ! |
1285 |
||
9998 | 1286 |
!ProjectDefinition class methodsFor:'code generation'! |
1287 |
||
11072 | 1288 |
applicationIconFileName_code |
1289 |
^ String streamContents:[:s | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1290 |
s nextPutLine:'applicationIconFileName'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1291 |
s nextPutLine:' "Return the name (without suffix) of an icon-file (the app''s icon); will be included in the rc-resource file"'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1292 |
s cr; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1293 |
nextPutLine:' ^ nil'; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1294 |
nextPutLine:' "/ ^ self applicationName'. |
11072 | 1295 |
]. |
1296 |
||
1297 |
" |
|
13873 | 1298 |
self applicationIconFileName_code |
1299 |
stx_libbasic3 applicationIconFileName_code |
|
11072 | 1300 |
" |
1301 |
||
1302 |
"Created: / 18-08-2006 / 16:21:01 / cg" |
|
1303 |
! |
|
1304 |
||
10393 | 1305 |
classNamesAndAttributes_codeFor:aSpecArray |
1306 |
"generate method code returning all classes of the project from the given spec." |
|
1307 |
||
1308 |
^ String streamContents:[:s | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1309 |
s nextPutLine:'classNamesAndAttributes'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1310 |
s nextPutLine:' "lists the classes which are to be included in the project.'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1311 |
s nextPutLine:' Each entry in the list may be: a single class-name (symbol),'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1312 |
s nextPutLine:' or an array-literal consisting of class name and attributes.'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1313 |
s nextPutLine:' Attributes are: #autoload or #<os> where os is one of win32, unix,..."'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1314 |
s nextPutLine:''. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1315 |
s nextPutLine:' ^ #('. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1316 |
s nextPutLine:' "<className> or (<className> attributes...) in load order"'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1317 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1318 |
(self classNamesAndAttributesFromSpecArray:aSpecArray) do:[:entry | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1319 |
s spaces:8. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1320 |
entry storeArrayElementOn:s. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1321 |
s cr. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1322 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1323 |
s nextPutLine:' )' |
10393 | 1324 |
]. |
1325 |
||
1326 |
" |
|
1327 |
stx_libbasic3 classNamesAndAttributes_codeFor:(stx_libbasic3 classNamesAndAttributes) |
|
1328 |
exept_expecco classNamesAndAttributes_codeFor:(exept_expecco classNamesAndAttributes) |
|
1329 |
" |
|
1330 |
||
1331 |
"Modified: / 08-08-2006 / 19:24:34 / fm" |
|
1332 |
"Created: / 19-02-2007 / 15:43:27 / cg" |
|
1333 |
! |
|
1334 |
||
10064
fb1ad676019d
update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents:
10063
diff
changeset
|
1335 |
classNamesAndAttributes_code_ignoreOldEntries:ignoreOldEntries ignoreOldDefinition:ignoreOldDefinition |
10010 | 1336 |
"generate method code returning all classes of the project. |
1337 |
Platform attributes are kept from the old definition. |
|
10064
fb1ad676019d
update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents:
10063
diff
changeset
|
1338 |
If ignoreOldEntries is true, the list is completely recreated; |
fb1ad676019d
update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents:
10063
diff
changeset
|
1339 |
if false, existing entries are preserved. |
10010 | 1340 |
If ignoreOldDefinition is true, the autoload attribute is set/reset if |
13419 | 1341 |
the class is installed as autoloaded in the image (i.e. the state in the image is taken). |
10064
fb1ad676019d
update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents:
10063
diff
changeset
|
1342 |
If false, it is taken from an existing definition in #classNamesAndAttributes" |
10010 | 1343 |
|
10393 | 1344 |
|newSpec oldSpec ignored| |
1345 |
||
1346 |
oldSpec := self classNamesAndAttributesAsSpecArray. |
|
1347 |
ignored := self ignoredClassNames asSet. |
|
1348 |
newSpec := OrderedCollection new. |
|
1349 |
||
1350 |
ignoreOldEntries ifFalse:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1351 |
oldSpec do:[:oldEntry | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1352 |
|newEntry className cls | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1353 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1354 |
newEntry := oldEntry copy. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1355 |
className := newEntry first. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1356 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1357 |
(ignored includes:className) ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1358 |
cls := Smalltalk classNamed:className. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1359 |
ignoreOldDefinition ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1360 |
(cls notNil and:[cls isLoaded not]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1361 |
(newEntry includes:#autoload) ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1362 |
newEntry := newEntry copyWith:#autoload. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1363 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1364 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1365 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1366 |
cls notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1367 |
"JV @ 2010-06-19 |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1368 |
Force merge default class attributes with existing ones" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1369 |
newEntry := self mergeDefaultClassAttributesFor: cls with: newEntry. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1370 |
newSpec add:newEntry. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1371 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1372 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1373 |
]. |
10393 | 1374 |
]. |
1375 |
||
1376 |
self searchForClasses do:[:eachClass | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1377 |
|className attributes oldSpecEntry oldAttributes newEntry| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1378 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1379 |
className := eachClass name. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1380 |
(ignored includes:className) ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1381 |
oldSpecEntry := oldSpec detect:[:entry | entry first = className] ifNone:nil. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1382 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1383 |
(ignoreOldEntries or:[ oldSpecEntry isNil]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1384 |
(eachClass isLoaded not or:[eachClass isPrivate not]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1385 |
(self additionalClassNamesAndAttributes includes:className) ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1386 |
(oldSpecEntry size > 1) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1387 |
oldAttributes := oldSpecEntry copyFrom:2. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1388 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1389 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1390 |
ignoreOldDefinition ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1391 |
"take autoload attribute from classes state in the image" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1392 |
oldAttributes notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1393 |
attributes := oldAttributes copyWithout:#autoload. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1394 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1395 |
attributes := #() |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1396 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1397 |
eachClass isLoaded ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1398 |
attributes := attributes copyWith:#autoload. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1399 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1400 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1401 |
"keep any existing attribute" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1402 |
oldAttributes notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1403 |
attributes := oldAttributes. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1404 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1405 |
attributes := eachClass isLoaded ifTrue:[ #() ] ifFalse:[ #(autoload) ]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1406 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1407 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1408 |
"JV @ 2010-06-19 |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1409 |
Support fo additional class attributes and programming language attribute" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1410 |
attributes := self mergeDefaultClassAttributesFor: eachClass with: attributes. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1411 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1412 |
newEntry := Array with:className. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1413 |
attributes notEmptyOrNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1414 |
newEntry := newEntry , attributes. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1415 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1416 |
newSpec add:newEntry |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1417 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1418 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1419 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1420 |
] |
9998 | 1421 |
]. |
10393 | 1422 |
^ self classNamesAndAttributes_codeFor:newSpec |
1423 |
||
13419 | 1424 |
" |
10393 | 1425 |
stx_libbasic3 classNamesAndAttributes_code_ignoreOldEntries:false ignoreOldDefinition:true |
1426 |
exept_expecco classNamesAndAttributes_code_ignoreOldEntries:false ignoreOldDefinition:true |
|
1427 |
" |
|
9998 | 1428 |
|
1429 |
"Modified: / 08-08-2006 / 19:24:34 / fm" |
|
10064
fb1ad676019d
update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents:
10063
diff
changeset
|
1430 |
"Created: / 10-10-2006 / 22:00:50 / cg" |
13411 | 1431 |
"Modified: / 19-06-2010 / 10:56:46 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
13635
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
1432 |
"Modified: / 06-09-2011 / 07:48:52 / cg" |
9998 | 1433 |
! |
1434 |
||
1435 |
companyName_code |
|
12541 | 1436 |
^ self companyName_codeFor:self companyName |
1437 |
||
1438 |
" |
|
1439 |
self companyName_code |
|
1440 |
stx_libbasic3 companyName_code |
|
1441 |
" |
|
1442 |
||
1443 |
"Created: / 18-08-2006 / 16:20:42 / cg" |
|
1444 |
! |
|
1445 |
||
1446 |
companyName_codeFor:aString |
|
9998 | 1447 |
^ String streamContents:[:s | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1448 |
s nextPutLine:'companyName'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1449 |
s nextPutLine:' "Return a companyname which will appear in <lib>.rc"'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1450 |
s cr; nextPutLine:' ^ ',aString storeString. |
9998 | 1451 |
]. |
1452 |
||
1453 |
" |
|
1454 |
self companyName_code |
|
1455 |
stx_libbasic3 companyName_code |
|
1456 |
" |
|
1457 |
||
1458 |
"Created: / 18-08-2006 / 16:20:42 / cg" |
|
1459 |
! |
|
1460 |
||
1461 |
compileDescriptionMethods |
|
1462 |
(self isLibraryDefinition |
|
1463 |
or:[ self isApplicationDefinition ] ) ifFalse:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1464 |
self error:'I am abstract - must be a subclass of Libray- or ApplicationDefinition.' |
9998 | 1465 |
]. |
1466 |
||
13419 | 1467 |
self |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1468 |
forEachMethodsCodeToCompileDo:[:code :category | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1469 |
self compile:code categorized:category |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1470 |
]. |
9998 | 1471 |
|
1472 |
"/ self instAndClassMethodsDo:[:m | m package:self package]. |
|
1473 |
||
1474 |
" |
|
1475 |
DapasXProject compileDescriptionMethods |
|
1476 |
DapasX_Datenbasis compileDescriptionMethods |
|
1477 |
bosch_dapasx_interactiver_editor compileDescriptionMethods |
|
1478 |
stx_libbasic compileDescriptionMethods |
|
1479 |
" |
|
1480 |
||
1481 |
"Created: / 09-08-2006 / 18:00:31 / fm" |
|
1482 |
"Modified: / 05-09-2006 / 13:46:29 / cg" |
|
1483 |
! |
|
1484 |
||
1485 |
description_code |
|
1486 |
^ String streamContents:[:s | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1487 |
s nextPutLine:'description'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1488 |
s nextPutLine:' "Return a description string which will appear in vc.def / bc.def"'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1489 |
s cr; nextPutLine:' ^ ',self description asString storeString. |
9998 | 1490 |
]. |
1491 |
||
1492 |
" |
|
13419 | 1493 |
self description_code |
1494 |
stx_libbasic3 description_code |
|
9998 | 1495 |
" |
1496 |
||
1497 |
"Created: / 17-08-2006 / 21:24:01 / cg" |
|
1498 |
"Modified: / 18-08-2006 / 16:16:24 / cg" |
|
1499 |
! |
|
1500 |
||
10923 | 1501 |
effectivePreRequisites |
1502 |
"get the preRequisites, that are not excluded" |
|
1503 |
||
1504 |
|preRequisites| |
|
1505 |
||
1506 |
preRequisites := self preRequisites asSet. |
|
1507 |
preRequisites removeAllFoundIn:self excludedFromPreRequisites. |
|
1508 |
preRequisites remove:self package ifAbsent:[]. |
|
1509 |
||
1510 |
^ preRequisites |
|
1511 |
! |
|
1512 |
||
11386
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
1513 |
effectiveSubProjects |
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
1514 |
"get the subProjects, that are not excluded" |
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
1515 |
|
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
1516 |
|subProjects| |
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
1517 |
|
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
1518 |
subProjects := self subProjects asSet. |
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
1519 |
subProjects removeAllFoundIn:self excludedFromSubProjects. |
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
1520 |
subProjects remove:self package ifAbsent:[]. |
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
1521 |
|
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
1522 |
^ subProjects |
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
1523 |
! |
5e4e1acf7242
Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents:
11383
diff
changeset
|
1524 |
|
12425 | 1525 |
excludedFromPreRequisites_code |
1526 |
"generate the code of the #excludedFromPreRequisites method" |
|
1527 |
||
1528 |
^ String streamContents:[:s | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1529 |
s nextPutLine:'excludedFromPreRequisites'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1530 |
s nextPutLine:' "list all packages which should be ignored in the automatic'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1531 |
s nextPutLine:' preRequisites scan. See #preRequisites for more."'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1532 |
s nextPutLine:''. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1533 |
s nextPutLine:' ^ #('. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1534 |
s nextPutLine:' )' |
12425 | 1535 |
]. |
1536 |
! |
|
1537 |
||
9998 | 1538 |
extensionMethodNames_code |
10064
fb1ad676019d
update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents:
10063
diff
changeset
|
1539 |
^ self extensionMethodNames_code_ignoreOldEntries:true |
fb1ad676019d
update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents:
10063
diff
changeset
|
1540 |
|
fb1ad676019d
update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents:
10063
diff
changeset
|
1541 |
" |
fb1ad676019d
update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents:
10063
diff
changeset
|
1542 |
self extensionMethodNames_code |
fb1ad676019d
update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents:
10063
diff
changeset
|
1543 |
" |
fb1ad676019d
update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents:
10063
diff
changeset
|
1544 |
|
fb1ad676019d
update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents:
10063
diff
changeset
|
1545 |
"Created: / 17-08-2006 / 21:21:48 / cg" |
fb1ad676019d
update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents:
10063
diff
changeset
|
1546 |
"Modified: / 10-10-2006 / 22:02:42 / cg" |
fb1ad676019d
update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents:
10063
diff
changeset
|
1547 |
! |
fb1ad676019d
update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents:
10063
diff
changeset
|
1548 |
|
fb1ad676019d
update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents:
10063
diff
changeset
|
1549 |
extensionMethodNames_code_ignoreOldEntries:ignoreOldEntries |
9998 | 1550 |
^ String streamContents:[:s | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1551 |
|oldSpec| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1552 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1553 |
s nextPutLine:'extensionMethodNames'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1554 |
s nextPutLine:' "lists the extension methods which are to be included in the project.'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1555 |
s nextPutLine:' Entries are 2-element array literals, consisting of class-name and selector."'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1556 |
s nextPutLine:''. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1557 |
s nextPutLine:' ^ #('. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1558 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1559 |
oldSpec := self extensionMethodNames pairWiseCollect:[:className :selector | className -> selector ]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1560 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1561 |
ignoreOldEntries ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1562 |
oldSpec do:[:entry | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1563 |
|mclassName mselector| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1564 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1565 |
mclassName := entry key asSymbol. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1566 |
(mclassName endsWith:' class') ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1567 |
mclassName := mclassName asString. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1568 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1569 |
mselector := entry value asSymbol. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1570 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1571 |
s spaces:8. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1572 |
mclassName storeArrayElementOn:s. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1573 |
s space. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1574 |
mselector storeArrayElementOn:s. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1575 |
s cr. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1576 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1577 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1578 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1579 |
self searchForExtensions do:[:eachMethod | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1580 |
|attributes oldSpecEntry mclassName mselector| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1581 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1582 |
mclassName := eachMethod mclass name. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1583 |
mselector := eachMethod selector. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1584 |
oldSpecEntry := oldSpec detect:[:entry | entry key = mclassName and:[ entry value = mselector]] ifNone:nil. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1585 |
(ignoreOldEntries or:[ oldSpecEntry isNil]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1586 |
s spaces:8. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1587 |
mclassName storeArrayElementOn:s. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1588 |
s space. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1589 |
mselector storeArrayElementOn:s. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1590 |
s cr. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1591 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1592 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1593 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1594 |
s nextPutLine:' )' |
9998 | 1595 |
]. |
1596 |
||
10106
c26879b72dfe
extensionlist generator was buggy
Claus Gittinger <cg@exept.de>
parents:
10104
diff
changeset
|
1597 |
" |
c26879b72dfe
extensionlist generator was buggy
Claus Gittinger <cg@exept.de>
parents:
10104
diff
changeset
|
1598 |
self extensionMethodNames_code_ignoreOldEntries:false |
c26879b72dfe
extensionlist generator was buggy
Claus Gittinger <cg@exept.de>
parents:
10104
diff
changeset
|
1599 |
stx_libtool extensionMethodNames_code_ignoreOldEntries:false |
c26879b72dfe
extensionlist generator was buggy
Claus Gittinger <cg@exept.de>
parents:
10104
diff
changeset
|
1600 |
stx_libtool extensionMethodNames_code_ignoreOldEntries:true |
c26879b72dfe
extensionlist generator was buggy
Claus Gittinger <cg@exept.de>
parents:
10104
diff
changeset
|
1601 |
" |
9998 | 1602 |
|
10064
fb1ad676019d
update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents:
10063
diff
changeset
|
1603 |
"Created: / 10-10-2006 / 22:02:36 / cg" |
10106
c26879b72dfe
extensionlist generator was buggy
Claus Gittinger <cg@exept.de>
parents:
10104
diff
changeset
|
1604 |
"Modified: / 23-10-2006 / 11:07:29 / cg" |
9998 | 1605 |
! |
1606 |
||
1607 |
forEachContentsMethodsCodeToCompileDo:aTwoArgBlock ignoreOldDefinition:ignoreOldDefinition |
|
13419 | 1608 |
aTwoArgBlock |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1609 |
value:(self classNamesAndAttributes_code_ignoreOldEntries:ignoreOldDefinition ignoreOldDefinition:ignoreOldDefinition) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1610 |
value:'description - contents'. |
13419 | 1611 |
|
1612 |
aTwoArgBlock |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1613 |
value: (self extensionMethodNames_code_ignoreOldEntries:ignoreOldDefinition) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1614 |
value: 'description - contents'. |
13419 | 1615 |
|
1616 |
aTwoArgBlock |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1617 |
value: self preRequisites_code |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1618 |
value: 'description'. |
13419 | 1619 |
|
1620 |
aTwoArgBlock |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1621 |
value: self excludedFromPreRequisites_code |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1622 |
value: 'description'. |
13411 | 1623 |
|
1624 |
(self monticelloPackageName notNil and:[self respondsTo:#monticelloTimestamps_code]) ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1625 |
aTwoArgBlock |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1626 |
value: self monticelloTimestamps_code |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1627 |
value: 'description - monticello'. |
13411 | 1628 |
]. |
1629 |
||
1630 |
"Modified: / 09-11-2010 / 18:41:07 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
1631 |
! |
|
1632 |
||
9998 | 1633 |
forEachMethodsCodeToCompileDo:aTwoArgBlock |
1634 |
self forEachMethodsCodeToCompileDo:aTwoArgBlock ignoreOldDefinition:false |
|
1635 |
! |
|
1636 |
||
1637 |
forEachMethodsCodeToCompileDo:aTwoArgBlock ignoreOldDefinition:ignoreOldDefinition |
|
13419 | 1638 |
self |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1639 |
forEachContentsMethodsCodeToCompileDo:aTwoArgBlock |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1640 |
ignoreOldDefinition:ignoreOldDefinition. |
10013
c6cd8f035693
pretty format of generated methods
Stefan Vogel <sv@exept.de>
parents:
10011
diff
changeset
|
1641 |
|
13873 | 1642 |
"/ code like: |
1643 |
"/ |
|
1644 |
"/ (self class includesSelector:#productName) ifFalse:[ |
|
1645 |
"/ aTwoArgBlock |
|
1646 |
"/ value: self productName_code |
|
1647 |
"/ value: 'description - project information'. |
|
1648 |
"/ ]. |
|
1649 |
||
1650 |
#( |
|
1651 |
(productName productName_code) |
|
1652 |
(description description_code) |
|
1653 |
(companyName companyName_code) |
|
1654 |
(legalCopyright legalCopyright_code) |
|
1655 |
(applicationIconFileName applicationIconFileName_code) |
|
1656 |
(productInstallDirBaseName productInstallDirBaseName_code) |
|
1657 |
) pairsDo:[:selector :codeMethodSelector | |
|
1658 |
(self class includesSelector:selector) ifFalse:[ |
|
1659 |
aTwoArgBlock |
|
1660 |
value: (self perform:codeMethodSelector) |
|
1661 |
value: 'description - project information'. |
|
1662 |
]. |
|
11072 | 1663 |
]. |
9998 | 1664 |
|
13411 | 1665 |
(self monticelloPackageName notNil and:[self respondsTo:#monticelloTimestamps_code]) ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1666 |
aTwoArgBlock |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1667 |
value: self monticelloTimestamps_code |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1668 |
value: 'description - monticello'. |
13411 | 1669 |
]. |
1670 |
||
9998 | 1671 |
"Created: / 18-08-2006 / 16:22:37 / cg" |
13411 | 1672 |
"Modified: / 09-11-2010 / 18:41:15 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
13873 | 1673 |
"Modified: / 21-12-2011 / 16:42:41 / cg" |
9998 | 1674 |
! |
1675 |
||
1676 |
legalCopyright_code |
|
1677 |
^ String streamContents:[:s | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1678 |
s nextPutLine:'legalCopyright'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1679 |
s nextPutLine:' "Return a copyright string which will appear in <lib>.rc"'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1680 |
s cr; nextPutLine:' ^ ', self legalCopyright storeString. |
9998 | 1681 |
]. |
1682 |
||
1683 |
" |
|
13419 | 1684 |
self legalCopyright_code |
1685 |
stx_libbasic3 legalCopyright_code |
|
9998 | 1686 |
" |
1687 |
||
1688 |
"Created: / 18-08-2006 / 16:21:01 / cg" |
|
1689 |
! |
|
1690 |
||
1691 |
preRequisites_code |
|
10574
b77b673bc36c
Better reason comments in #preRequisites packages
Stefan Vogel <sv@exept.de>
parents:
10570
diff
changeset
|
1692 |
"generate the code of the #preRequisites method" |
b77b673bc36c
Better reason comments in #preRequisites packages
Stefan Vogel <sv@exept.de>
parents:
10570
diff
changeset
|
1693 |
|
b77b673bc36c
Better reason comments in #preRequisites packages
Stefan Vogel <sv@exept.de>
parents:
10570
diff
changeset
|
1694 |
|preRequisites searchedPreRequisites importantReason| |
b77b673bc36c
Better reason comments in #preRequisites packages
Stefan Vogel <sv@exept.de>
parents:
10570
diff
changeset
|
1695 |
|
b77b673bc36c
Better reason comments in #preRequisites packages
Stefan Vogel <sv@exept.de>
parents:
10570
diff
changeset
|
1696 |
"maybe, some prerequisites have been added manually - keep them |
b77b673bc36c
Better reason comments in #preRequisites packages
Stefan Vogel <sv@exept.de>
parents:
10570
diff
changeset
|
1697 |
The drawback of this - a preRequisite will never go away, even if it is no longer used" |
9998 | 1698 |
|
1699 |
preRequisites := self preRequisites asSet. |
|
10574
b77b673bc36c
Better reason comments in #preRequisites packages
Stefan Vogel <sv@exept.de>
parents:
10570
diff
changeset
|
1700 |
|
10179 | 1701 |
searchedPreRequisites := self searchForPreRequisites. |
1702 |
preRequisites addAll: (searchedPreRequisites keys). |
|
9998 | 1703 |
|
1704 |
self isApplicationDefinition ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1705 |
preRequisites add:#'stx:libcomp'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1706 |
self isGUIApplication ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1707 |
preRequisites add:#'stx:libbasic2'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1708 |
preRequisites add:#'stx:libview'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1709 |
preRequisites add:#'stx:libview2'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1710 |
preRequisites add:#'stx:libwidg'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1711 |
preRequisites add:#'stx:libwidg2'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1712 |
preRequisites add:#'stx:libui'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1713 |
]. |
9998 | 1714 |
]. |
1715 |
||
10897
6a20c3e54653
#removeAllFoundIn: excludedFromPrerequisites
Stefan Vogel <sv@exept.de>
parents:
10875
diff
changeset
|
1716 |
preRequisites removeAllFoundIn:self excludedFromPreRequisites. |
10034 | 1717 |
preRequisites remove:self package ifAbsent:[]. |
9998 | 1718 |
|
1719 |
^ String streamContents:[:s | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1720 |
s nextPutLine:'preRequisites'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1721 |
s nextPutLine:' "list all required packages.'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1722 |
s nextPutLine:' This list can be maintained manually or (better) generated and'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1723 |
s nextPutLine:' updated by scanning the superclass hierarchies and looking for'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1724 |
s nextPutLine:' global variable accesses. (the browser has a menu function for that)'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1725 |
s nextPutLine:' Howevery, often too much is found, and you may want to explicitely'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1726 |
s nextPutLine:' exclude individual packages in the #excludedFromPrerequisites method."'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1727 |
s nextPutLine:''. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1728 |
s nextPutLine:' ^ #('. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1729 |
preRequisites asSortedCollection do:[:eachPackageID | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1730 |
|reason| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1731 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1732 |
s spaces:8. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1733 |
eachPackageID asSymbol storeOn:s. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1734 |
reason := searchedPreRequisites at:eachPackageID ifAbsent:nil. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1735 |
reason notEmptyOrNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1736 |
"superclasses are really important" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1737 |
importantReason := reason detect:[:eachReasonString| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1738 |
eachReasonString includesString:' superclass ' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1739 |
] ifNone:[reason anElement]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1740 |
s nextPutAll:' "'; nextPutAll:importantReason; nextPutAll:' "'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1741 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1742 |
s cr. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1743 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1744 |
s nextPutLine:' )' |
9998 | 1745 |
]. |
1746 |
||
1747 |
" |
|
1748 |
bosch_dapasx_application preRequisites_code |
|
1749 |
demo_demoApp1 preRequisites_code |
|
10574
b77b673bc36c
Better reason comments in #preRequisites packages
Stefan Vogel <sv@exept.de>
parents:
10570
diff
changeset
|
1750 |
stx_libbasic3 preRequisites_code |
10013
c6cd8f035693
pretty format of generated methods
Stefan Vogel <sv@exept.de>
parents:
10011
diff
changeset
|
1751 |
stx_libtool2 preRequisites_code |
9998 | 1752 |
" |
1753 |
||
1754 |
"Modified: / 08-08-2006 / 19:24:34 / fm" |
|
1755 |
"Created: / 17-08-2006 / 21:28:09 / cg" |
|
10063 | 1756 |
"Modified: / 09-10-2006 / 14:27:20 / cg" |
9998 | 1757 |
! |
1758 |
||
13873 | 1759 |
productInstallDirBaseName_code |
1760 |
^ String streamContents:[:s | |
|
1761 |
s nextPutLine:'productInstallDirBaseName'. |
|
1762 |
s nextPutLine:' "Returns a default installDir which will appear in <app>.nsi.'. |
|
1763 |
s nextPutLine:' This is usually not the one you want to keep"'. |
|
1764 |
s cr; |
|
1765 |
nextPutLine:' ^ (self package asCollectionOfSubstringsSeparatedByAny:'':/'') last'. |
|
1766 |
]. |
|
1767 |
||
1768 |
" |
|
1769 |
self productInstallDirBaseName_code |
|
1770 |
stx_libbasic3 productInstallDirBaseName_code |
|
1771 |
stx_clients_Clock_QlockTwoWatchApplication productInstallDirBaseName_code |
|
1772 |
" |
|
1773 |
||
1774 |
"Created: / 21-12-2011 / 16:38:11 / cg" |
|
1775 |
! |
|
1776 |
||
9998 | 1777 |
productName_code |
12541 | 1778 |
^ self productName_codeFor:(self productName) |
1779 |
||
1780 |
" |
|
1781 |
self productName_code |
|
1782 |
stx_libbasic3 productName_code |
|
1783 |
" |
|
1784 |
||
1785 |
"Created: / 18-08-2006 / 16:14:19 / cg" |
|
1786 |
! |
|
1787 |
||
1788 |
productName_codeFor:aString |
|
9998 | 1789 |
^ String streamContents:[:s | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1790 |
s nextPutLine:'productName'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1791 |
s nextPutLine:' "Return a product name which will appear in <lib>.rc"'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1792 |
s cr; nextPutLine:' ^ ',aString storeString. |
9998 | 1793 |
]. |
1794 |
||
1795 |
" |
|
1796 |
self productName_code |
|
1797 |
stx_libbasic3 productName_code |
|
1798 |
" |
|
1799 |
||
1800 |
"Created: / 18-08-2006 / 16:14:19 / cg" |
|
12028 | 1801 |
! |
1802 |
||
1803 |
svnRevisionNr_code: revisionNrOrNil |
|
1804 |
^ String streamContents:[:s | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1805 |
s nextPutLine:'svnRevisionNr'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1806 |
s nextPutLine:' "Return a SVN revision number of myself.'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1807 |
s nextPutLine:' This number is updated after a commit"'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1808 |
s cr; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1809 |
nextPutLine:' ^ "$SVN-Revision:"''', revisionNrOrNil printString , '''"$"'. |
12028 | 1810 |
]. |
1811 |
||
1812 |
" |
|
1813 |
self svnRevisionNr_code |
|
1814 |
stx_libbasic3 svnRevisionNr_code |
|
1815 |
" |
|
1816 |
||
1817 |
"Created: / 16-06-2009 / 12:12:37 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
1818 |
"Modified: / 22-08-2009 / 09:05:05 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
9998 | 1819 |
! ! |
1820 |
||
9569 | 1821 |
!ProjectDefinition class methodsFor:'defaults'! |
9536 | 1822 |
|
9664 | 1823 |
applicationTypes |
9714 | 1824 |
GUIApplicationType isNil ifTrue:[self initialize]. |
1825 |
^ Array with:GUIApplicationType with:NonGUIApplicationType |
|
9664 | 1826 |
|
9714 | 1827 |
" |
13419 | 1828 |
self applicationTypes |
9714 | 1829 |
" |
9664 | 1830 |
! |
1831 |
||
10434
25f76184bf81
project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents:
10433
diff
changeset
|
1832 |
defaultCategory |
10466 | 1833 |
^'* Projects & Packages *' |
10434
25f76184bf81
project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents:
10433
diff
changeset
|
1834 |
|
25f76184bf81
project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents:
10433
diff
changeset
|
1835 |
"Created: / 11-08-2006 / 14:16:49 / cg" |
25f76184bf81
project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents:
10433
diff
changeset
|
1836 |
! |
25f76184bf81
project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents:
10433
diff
changeset
|
1837 |
|
9714 | 1838 |
defaultProjectType |
9745 | 1839 |
^ self libraryTypes first |
1840 |
"/ ^ self applicationTypes first |
|
9714 | 1841 |
|
1842 |
"Created: / 23-08-2006 / 14:27:32 / cg" |
|
1843 |
! |
|
1844 |
||
1845 |
defaultProjectTypeForGUIApplication |
|
1846 |
^ GUIApplicationType |
|
1847 |
! |
|
1848 |
||
1849 |
defaultProjectTypeForNonGUIApplication |
|
1850 |
^ NonGUIApplicationType |
|
1851 |
! |
|
9664 | 1852 |
|
9714 | 1853 |
guiApplicationType |
1854 |
^ GUIApplicationType |
|
1855 |
! |
|
1856 |
||
1857 |
libraryType |
|
1858 |
^ LibraryType |
|
1859 |
! |
|
1860 |
||
13419 | 1861 |
libraryTypes |
9714 | 1862 |
LibraryType isNil ifTrue:[self initialize]. |
1863 |
^ Array with:LibraryType |
|
1864 |
||
1865 |
" |
|
13419 | 1866 |
self libraryTypes |
9714 | 1867 |
" |
1868 |
! |
|
1869 |
||
1870 |
nonGuiApplicationType |
|
1871 |
^ NonGUIApplicationType |
|
9664 | 1872 |
! |
1873 |
||
12331 | 1874 |
projectTypeSelectors |
1875 |
"a list of possible project type selectors" |
|
1876 |
||
1877 |
^ #( libraryType guiApplicationType nonGuiApplicationType ) |
|
1878 |
||
1879 |
" |
|
1880 |
self libraryType |
|
1881 |
self guiApplicationType |
|
1882 |
self nonGuiApplicationType |
|
1883 |
" |
|
1884 |
||
1885 |
"Created: / 23-08-2006 / 14:27:32 / cg" |
|
1886 |
! |
|
1887 |
||
9664 | 1888 |
projectTypes |
12331 | 1889 |
"a list of possible project types" |
1890 |
||
9664 | 1891 |
^ self libraryTypes , self applicationTypes |
1892 |
||
12331 | 1893 |
" |
1894 |
self projectTypes |
|
1895 |
" |
|
1896 |
||
9664 | 1897 |
"Created: / 23-08-2006 / 14:27:32 / cg" |
9536 | 1898 |
! ! |
1899 |
||
9569 | 1900 |
!ProjectDefinition class methodsFor:'description'! |
9536 | 1901 |
|
13419 | 1902 |
excludedFromPreRequisites |
9983 | 1903 |
"list packages which are to be explicitely excluded from the automatic constructed |
1904 |
prerequisites list. If empty, everything that is found along the inheritance of any of |
|
1905 |
my classes is considered to be a prerequisite package." |
|
1906 |
||
1907 |
^ #() |
|
1908 |
||
1909 |
"Modified: / 17-08-2006 / 19:48:59 / cg" |
|
1910 |
! |
|
1911 |
||
10380
ff1cfee6130b
Fix subproject incluseion in Make.proto
Stefan Vogel <sv@exept.de>
parents:
10369
diff
changeset
|
1912 |
excludedFromSubProjects |
ff1cfee6130b
Fix subproject incluseion in Make.proto
Stefan Vogel <sv@exept.de>
parents:
10369
diff
changeset
|
1913 |
"list packages which are to be explicitely excluded from the automatic constructed |
ff1cfee6130b
Fix subproject incluseion in Make.proto
Stefan Vogel <sv@exept.de>
parents:
10369
diff
changeset
|
1914 |
subProjects list. If empty, every sub-package is included as a prerequisite." |
ff1cfee6130b
Fix subproject incluseion in Make.proto
Stefan Vogel <sv@exept.de>
parents:
10369
diff
changeset
|
1915 |
|
ff1cfee6130b
Fix subproject incluseion in Make.proto
Stefan Vogel <sv@exept.de>
parents:
10369
diff
changeset
|
1916 |
^ #() |
ff1cfee6130b
Fix subproject incluseion in Make.proto
Stefan Vogel <sv@exept.de>
parents:
10369
diff
changeset
|
1917 |
|
ff1cfee6130b
Fix subproject incluseion in Make.proto
Stefan Vogel <sv@exept.de>
parents:
10369
diff
changeset
|
1918 |
"Modified: / 17-08-2006 / 19:49:40 / cg" |
10039 | 1919 |
! |
1920 |
||
9575 | 1921 |
preRequisites |
1922 |
"list packages which are required as a prerequisite. This method is generated automatically, |
|
1923 |
by searching along the inheritance chain of all of my classes. |
|
1924 |
However, when generating automatically, packages are only added - never removed, unless listed |
|
1925 |
in excludedFromPreRequisites." |
|
1926 |
||
1927 |
^ #() |
|
1928 |
||
1929 |
"Modified: / 17-08-2006 / 19:54:21 / cg" |
|
1930 |
! |
|
1931 |
||
13411 | 1932 |
preRequisitesFor: packageId |
1933 |
| def | |
|
1934 |
||
1935 |
def := self definitionClassForPackage:packageId. |
|
13820
f46f7306eea2
changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents:
13809
diff
changeset
|
1936 |
def isNil ifTrue:[ |
f46f7306eea2
changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents:
13809
diff
changeset
|
1937 |
"Maybe the package is not loaded? Try to load it..." |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1938 |
(Smalltalk loadPackage: packageId) ifTrue: |
13820
f46f7306eea2
changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents:
13809
diff
changeset
|
1939 |
[def := self definitionClassForPackage:packageId] |
f46f7306eea2
changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents:
13809
diff
changeset
|
1940 |
]. |
f46f7306eea2
changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents:
13809
diff
changeset
|
1941 |
^ def isNil |
f46f7306eea2
changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents:
13809
diff
changeset
|
1942 |
ifTrue: |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1943 |
["Still no project definition - maybe does not exists?" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1944 |
(ProjectDefinition searchForPreRequisites: packageId) keys] |
13820
f46f7306eea2
changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents:
13809
diff
changeset
|
1945 |
ifFalse: |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
1946 |
[def effectivePreRequisites] |
13411 | 1947 |
|
1948 |
"Created: / 24-02-2011 / 22:47:41 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
13820
f46f7306eea2
changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents:
13809
diff
changeset
|
1949 |
"Modified: / 18-11-2011 / 14:52:43 / cg" |
f46f7306eea2
changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents:
13809
diff
changeset
|
1950 |
"Modified (format): / 19-11-2011 / 11:25:36 / cg" |
13411 | 1951 |
! |
1952 |
||
12186 | 1953 |
preRequisitesForBuilding |
1954 |
"for now, there is only one list of prerequisites present; |
|
1955 |
will be changed in the (near?) future" |
|
1956 |
||
1957 |
^ self preRequisites |
|
1958 |
! |
|
1959 |
||
1960 |
preRequisitesForLoading |
|
1961 |
"for now, there is only one list of prerequisites present; |
|
1962 |
will be changed in the (near?) future" |
|
1963 |
||
1964 |
^ self preRequisites |
|
1965 |
! |
|
1966 |
||
9685 | 1967 |
siblingsAreSubProjects |
1968 |
^ false |
|
1969 |
! |
|
1970 |
||
11377 | 1971 |
splashFileName |
1972 |
"answer the base-name of the splash bitmap. |
|
1973 |
||
1974 |
Default is nil, for no splash. If non-nil, it must be a bmp file's name" |
|
1975 |
||
1976 |
^ nil. |
|
1977 |
! |
|
1978 |
||
9575 | 1979 |
subProjects |
12748 | 1980 |
<resource: #obsolete> |
1981 |
||
1982 |
"OBSOLETE. |
|
1983 |
list packages which are known as subprojects. This method is generated automatically. |
|
9575 | 1984 |
However, when generating automatically, packages are only added - never removed, unless listed |
1985 |
in excludedFromSubProjects." |
|
1986 |
||
1987 |
^ #() |
|
1988 |
||
1989 |
"Modified: / 17-08-2006 / 19:57:46 / cg" |
|
1990 |
! ! |
|
1991 |
||
12372 | 1992 |
!ProjectDefinition class methodsFor:'description - actions'! |
1993 |
||
1994 |
postLoadAction |
|
1995 |
"invoked after loading a project" |
|
1996 |
||
1997 |
"/ intentionally left blank, to be redefined by subclasses (i.e. real projects) |
|
1998 |
||
1999 |
"Modified: / 17-08-2006 / 19:59:17 / cg" |
|
2000 |
! |
|
2001 |
||
2002 |
preLoadAction |
|
2003 |
"invoked before loading a project" |
|
2004 |
||
2005 |
"/ intentionally left blank, to be redefined by subclasses (i.e. real projects) |
|
2006 |
! |
|
2007 |
||
2008 |
preUnloadAction |
|
2009 |
"invoked before unloading a project" |
|
2010 |
||
2011 |
"/ intentionally left blank, to be redefined by subclasses (i.e. real projects) |
|
2012 |
||
2013 |
"Modified: / 17-08-2006 / 19:59:26 / cg" |
|
2014 |
! ! |
|
2015 |
||
9575 | 2016 |
!ProjectDefinition class methodsFor:'description - classes'! |
2017 |
||
9621 | 2018 |
additionalClassNamesAndAttributes |
2019 |
^ #() |
|
2020 |
||
2021 |
"Created: / 21-08-2006 / 19:53:04 / cg" |
|
2022 |
! |
|
2023 |
||
9607 | 2024 |
classNamesAndAttributes |
12368 | 2025 |
"a correponding method with real names must be present in my concrete subclasses" |
9575 | 2026 |
|
12202 | 2027 |
"/ should this be a subclassResponsibility here ? |
9595 | 2028 |
^ #() |
9536 | 2029 |
|
9575 | 2030 |
"Created: / 07-08-2006 / 19:02:57 / fm" |
2031 |
"Modified: / 07-08-2006 / 21:25:25 / fm" |
|
2032 |
"Modified: / 17-08-2006 / 20:47:20 / cg" |
|
2033 |
! |
|
2034 |
||
2035 |
extensionMethodNames |
|
2036 |
"list class/selector pairs of extensions. |
|
12368 | 2037 |
A correponding method with real names must be present in my concrete subclasses" |
2038 |
||
2039 |
"/ should this be a subclassResponsibility here ? |
|
9595 | 2040 |
^ #() |
9575 | 2041 |
|
2042 |
"Modified: / 17-08-2006 / 20:49:51 / cg" |
|
10350
f70405894961
added optional ignoredClassNames method.
Claus Gittinger <cg@exept.de>
parents:
10331
diff
changeset
|
2043 |
! |
f70405894961
added optional ignoredClassNames method.
Claus Gittinger <cg@exept.de>
parents:
10331
diff
changeset
|
2044 |
|
f70405894961
added optional ignoredClassNames method.
Claus Gittinger <cg@exept.de>
parents:
10331
diff
changeset
|
2045 |
ignoredClassNames |
f70405894961
added optional ignoredClassNames method.
Claus Gittinger <cg@exept.de>
parents:
10331
diff
changeset
|
2046 |
"can be redefined to suppress some classes from being included in a |
f70405894961
added optional ignoredClassNames method.
Claus Gittinger <cg@exept.de>
parents:
10331
diff
changeset
|
2047 |
generated classNamesAndAttributes spec" |
f70405894961
added optional ignoredClassNames method.
Claus Gittinger <cg@exept.de>
parents:
10331
diff
changeset
|
2048 |
|
f70405894961
added optional ignoredClassNames method.
Claus Gittinger <cg@exept.de>
parents:
10331
diff
changeset
|
2049 |
^ #() |
f70405894961
added optional ignoredClassNames method.
Claus Gittinger <cg@exept.de>
parents:
10331
diff
changeset
|
2050 |
|
f70405894961
added optional ignoredClassNames method.
Claus Gittinger <cg@exept.de>
parents:
10331
diff
changeset
|
2051 |
"Created: / 23-01-2007 / 19:08:27 / cg" |
9575 | 2052 |
! ! |
2053 |
||
2054 |
!ProjectDefinition class methodsFor:'description - compilation'! |
|
9536 | 2055 |
|
11940
cb9e5867b474
base address definition moved into a separate spec
Claus Gittinger <cg@exept.de>
parents:
11937
diff
changeset
|
2056 |
additionalBaseAddressDefinition_bc_dot_mak |
cb9e5867b474
base address definition moved into a separate spec
Claus Gittinger <cg@exept.de>
parents:
11937
diff
changeset
|
2057 |
"allows for a base-address definition to be added to the bc.mak file. |
cb9e5867b474
base address definition moved into a separate spec
Claus Gittinger <cg@exept.de>
parents:
11937
diff
changeset
|
2058 |
Subclasses may redefine this to something like |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2059 |
LIB_BASE=$(LIBWIDG_BASE) |
11940
cb9e5867b474
base address definition moved into a separate spec
Claus Gittinger <cg@exept.de>
parents:
11937
diff
changeset
|
2060 |
This will be inserted BEFORE the 'include stdHeader' |
cb9e5867b474
base address definition moved into a separate spec
Claus Gittinger <cg@exept.de>
parents:
11937
diff
changeset
|
2061 |
" |
cb9e5867b474
base address definition moved into a separate spec
Claus Gittinger <cg@exept.de>
parents:
11937
diff
changeset
|
2062 |
|
cb9e5867b474
base address definition moved into a separate spec
Claus Gittinger <cg@exept.de>
parents:
11937
diff
changeset
|
2063 |
^ nil |
cb9e5867b474
base address definition moved into a separate spec
Claus Gittinger <cg@exept.de>
parents:
11937
diff
changeset
|
2064 |
! |
cb9e5867b474
base address definition moved into a separate spec
Claus Gittinger <cg@exept.de>
parents:
11937
diff
changeset
|
2065 |
|
11829
2d880f341cfc
#additionalDefinitions for both bc_dot_mak and make_dot_proto
Stefan Vogel <sv@exept.de>
parents:
11789
diff
changeset
|
2066 |
additionalDefinitions |
2d880f341cfc
#additionalDefinitions for both bc_dot_mak and make_dot_proto
Stefan Vogel <sv@exept.de>
parents:
11789
diff
changeset
|
2067 |
"allows for additional definitions/rules to be added to the make.proto and bc.mak file." |
2d880f341cfc
#additionalDefinitions for both bc_dot_mak and make_dot_proto
Stefan Vogel <sv@exept.de>
parents:
11789
diff
changeset
|
2068 |
|
2d880f341cfc
#additionalDefinitions for both bc_dot_mak and make_dot_proto
Stefan Vogel <sv@exept.de>
parents:
11789
diff
changeset
|
2069 |
^ '' |
2d880f341cfc
#additionalDefinitions for both bc_dot_mak and make_dot_proto
Stefan Vogel <sv@exept.de>
parents:
11789
diff
changeset
|
2070 |
! |
2d880f341cfc
#additionalDefinitions for both bc_dot_mak and make_dot_proto
Stefan Vogel <sv@exept.de>
parents:
11789
diff
changeset
|
2071 |
|
10306 | 2072 |
additionalDefinitions_bc_dot_mak |
2073 |
"allows for additional definitions/rules to be added to the bc.mak file. |
|
10974 | 2074 |
Subclasses may redefine this." |
10306 | 2075 |
|
2076 |
^ self additionalDefinitions_nt_dot_mak |
|
2077 |
||
2078 |
"Created: / 22-08-2006 / 23:59:32 / cg" |
|
2079 |
! |
|
2080 |
||
9625 | 2081 |
additionalDefinitions_make_dot_proto |
2082 |
"allows for additional definitions/rules to be added to the make.proto file." |
|
2083 |
||
11829
2d880f341cfc
#additionalDefinitions for both bc_dot_mak and make_dot_proto
Stefan Vogel <sv@exept.de>
parents:
11789
diff
changeset
|
2084 |
^ self additionalDefinitions |
9625 | 2085 |
|
2086 |
"Created: / 22-08-2006 / 23:53:08 / cg" |
|
2087 |
! |
|
2088 |
||
2089 |
additionalDefinitions_nt_dot_mak |
|
10306 | 2090 |
"obsolete - kept for compatibility with old project files" |
9625 | 2091 |
|
11829
2d880f341cfc
#additionalDefinitions for both bc_dot_mak and make_dot_proto
Stefan Vogel <sv@exept.de>
parents:
11789
diff
changeset
|
2092 |
^ self additionalDefinitions |
9625 | 2093 |
|
2094 |
"Created: / 22-08-2006 / 23:59:32 / cg" |
|
2095 |
! |
|
2096 |
||
13688
4f43dc4a3182
added: #additionalHeaderRulesUsingTemplate:pathConverter:
Claus Gittinger <cg@exept.de>
parents:
13687
diff
changeset
|
2097 |
additionalHeaderRulesUsingTemplate:template pathConverter:pathConverter |
13687
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2098 |
"rules for header files (of autoloaded classes). |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2099 |
For each extended class, which is autoloaded (and therefore, we will not find a header file for it), |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2100 |
generate a rule to create the header file only." |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2101 |
|
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2102 |
^ String streamContents:[:s | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2103 |
(self extensionClassesWithSuperclasses:true) do:[:eachExtendedClass | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2104 |
|headerFileDirPath baseFilename| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2105 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2106 |
(eachExtendedClass isLoaded not or:[eachExtendedClass wasAutoloaded]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2107 |
headerFileDirPath := self perform:pathConverter with:eachExtendedClass package. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2108 |
baseFilename := self filenameForClass:eachExtendedClass. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2109 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2110 |
s nextPutAll:(template |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2111 |
bindWith:headerFileDirPath |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2112 |
with:baseFilename). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2113 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2114 |
]. |
13687
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2115 |
]. |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2116 |
|
13688
4f43dc4a3182
added: #additionalHeaderRulesUsingTemplate:pathConverter:
Claus Gittinger <cg@exept.de>
parents:
13687
diff
changeset
|
2117 |
"Created: / 12-09-2011 / 16:23:52 / cg" |
13687
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2118 |
! |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2119 |
|
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2120 |
additionalHeaderRules_bc_dot_mak |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2121 |
"rules for header files (of autoloaded classes)" |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2122 |
|
13695 | 2123 |
^ self |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2124 |
additionalHeaderRulesUsingTemplate:(self singleHeaderRuleTemplate_bc_dot_mak) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2125 |
pathConverter:#pathToPackage_win32: |
13687
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2126 |
|
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2127 |
"Created: / 12-09-2011 / 15:44:09 / cg" |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2128 |
! |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2129 |
|
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2130 |
additionalHeaderRules_make_dot_proto |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2131 |
"rules for header files (of autoloaded classes)" |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2132 |
|
13695 | 2133 |
^ self |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2134 |
additionalHeaderRulesUsingTemplate:(self singleHeaderRuleTemplate_make_dot_proto) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2135 |
pathConverter:#pathToPackage_unix: |
13687
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2136 |
|
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2137 |
"Created: / 12-09-2011 / 15:44:28 / cg" |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2138 |
! |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2139 |
|
10306 | 2140 |
additionalLinkLibraries_bc_dot_mak |
2141 |
"allows for additional static libraries to be added to the bc.mak file. |
|
2142 |
Subclasses may redefine this" |
|
2143 |
||
2144 |
"backward compatibilty with old projects" |
|
2145 |
||
2146 |
^ self additionalLinkLibraries_nt_dot_mak |
|
2147 |
||
2148 |
||
2149 |
"Created: / 22-08-2006 / 23:53:33 / cg" |
|
2150 |
! |
|
2151 |
||
9733 | 2152 |
additionalLinkLibraries_make_dot_proto |
9972
c63164ec0584
Allow shared libraries to be defined for a class lib (needed for liboracle)
Stefan Vogel <sv@exept.de>
parents:
9964
diff
changeset
|
2153 |
"allows for additional static libraries to be added to the make.proto file." |
9733 | 2154 |
|
2155 |
^ '' |
|
2156 |
||
2157 |
"Created: / 22-08-2006 / 23:53:33 / cg" |
|
2158 |
! |
|
2159 |
||
10299
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
2160 |
additionalLinkLibraries_nt_dot_mak |
10306 | 2161 |
"obsolete - kept for compatibility with old project files" |
10299
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
2162 |
|
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
2163 |
^ '' |
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
2164 |
|
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
2165 |
"Created: / 22-08-2006 / 23:53:33 / cg" |
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
2166 |
! |
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
2167 |
|
12028 | 2168 |
additionalRulesSvn_make_dot_proto |
2169 |
||
2170 |
(self class includesSelector: #svnRevisionNr) ifFalse:[^'']. |
|
2171 |
||
2172 |
^ String streamContents: |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2173 |
[:s|s |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2174 |
nextPutLine:'update-svn-revision:'; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2175 |
tab; nextPutLine: 'if [ !! -r .svnversion -o "$(shell svnversion -n)" !!= "$(shell cat .svnversion)" ]; then \'; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2176 |
tab; tab; nextPutLine: 'svnversion -n > .svnversion; \'; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2177 |
tab; tab; nextPutLine: 'sed -i -e "s/\"\$$SVN\-Revision:\".*\"\$$\"/\"\$$SVN-Revision:\"''$(shell svnversion -n)''\"\$$\"/g" \'; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2178 |
tab; tab; tab; nextPutLine: (self name , '.st; \'); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2179 |
tab; nextPutLine: 'fi'; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2180 |
nextPutLine: '.PHONY: update-svn-revision'] |
12028 | 2181 |
|
2182 |
"Created: / 24-06-2009 / 21:33:32 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
13411 | 2183 |
"Modified: / 07-05-2011 / 13:49:47 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
12028 | 2184 |
! |
2185 |
||
10306 | 2186 |
additionalRules_bc_dot_mak |
10312
7f71d47b09bd
#additionalTargets_bc_dot_mak for applications
Stefan Vogel <sv@exept.de>
parents:
10306
diff
changeset
|
2187 |
"obsolete - kept for compatibility with old project files" |
13419 | 2188 |
|
10312
7f71d47b09bd
#additionalTargets_bc_dot_mak for applications
Stefan Vogel <sv@exept.de>
parents:
10306
diff
changeset
|
2189 |
^ '' |
7f71d47b09bd
#additionalTargets_bc_dot_mak for applications
Stefan Vogel <sv@exept.de>
parents:
10306
diff
changeset
|
2190 |
|
7f71d47b09bd
#additionalTargets_bc_dot_mak for applications
Stefan Vogel <sv@exept.de>
parents:
10306
diff
changeset
|
2191 |
"Created: / 22-08-2006 / 23:59:24 / cg" |
10306 | 2192 |
! |
2193 |
||
9625 | 2194 |
additionalRules_make_dot_proto |
2195 |
"allows for additional rules to be added to the make.proto file." |
|
2196 |
||
2197 |
^ '' |
|
2198 |
||
2199 |
"Created: / 22-08-2006 / 23:59:16 / cg" |
|
2200 |
! |
|
2201 |
||
9972
c63164ec0584
Allow shared libraries to be defined for a class lib (needed for liboracle)
Stefan Vogel <sv@exept.de>
parents:
9964
diff
changeset
|
2202 |
additionalSharedLinkLibraries_make_dot_proto |
c63164ec0584
Allow shared libraries to be defined for a class lib (needed for liboracle)
Stefan Vogel <sv@exept.de>
parents:
9964
diff
changeset
|
2203 |
"allows for additional shared libraries to be added to the make.proto file." |
c63164ec0584
Allow shared libraries to be defined for a class lib (needed for liboracle)
Stefan Vogel <sv@exept.de>
parents:
9964
diff
changeset
|
2204 |
|
c63164ec0584
Allow shared libraries to be defined for a class lib (needed for liboracle)
Stefan Vogel <sv@exept.de>
parents:
9964
diff
changeset
|
2205 |
^ '' |
c63164ec0584
Allow shared libraries to be defined for a class lib (needed for liboracle)
Stefan Vogel <sv@exept.de>
parents:
9964
diff
changeset
|
2206 |
! |
c63164ec0584
Allow shared libraries to be defined for a class lib (needed for liboracle)
Stefan Vogel <sv@exept.de>
parents:
9964
diff
changeset
|
2207 |
|
12028 | 2208 |
additionalTargetsSvn_make_dot_proto |
2209 |
||
2210 |
(self class includesSelector: #svnRevisionNr) ifFalse:[^'']. |
|
2211 |
||
2212 |
^ 'update-svn-revision' |
|
2213 |
||
2214 |
"Created: / 24-06-2009 / 21:35:15 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
2215 |
! |
|
2216 |
||
10306 | 2217 |
additionalTargets_bc_dot_mak |
10312
7f71d47b09bd
#additionalTargets_bc_dot_mak for applications
Stefan Vogel <sv@exept.de>
parents:
10306
diff
changeset
|
2218 |
"obsolete - kept for compatibility with old project files" |
13419 | 2219 |
|
10312
7f71d47b09bd
#additionalTargets_bc_dot_mak for applications
Stefan Vogel <sv@exept.de>
parents:
10306
diff
changeset
|
2220 |
^ '' |
10306 | 2221 |
|
2222 |
"Created: / 23-08-2006 / 00:00:35 / cg" |
|
2223 |
! |
|
2224 |
||
9625 | 2225 |
additionalTargets_make_dot_proto |
2226 |
"allows for additional targets to be added to the make.proto file." |
|
2227 |
||
2228 |
^ '' |
|
2229 |
||
2230 |
"Created: / 22-08-2006 / 23:53:33 / cg" |
|
2231 |
! |
|
2232 |
||
10979 | 2233 |
globalDefines |
2234 |
"allow for the specification of additional defines for stc compilation of prerequisite packages |
|
2235 |
an subprojects" |
|
2236 |
||
2237 |
^ '' |
|
2238 |
! |
|
2239 |
||
2240 |
globalDefines_unix |
|
2241 |
"allow for the specification of additional defines for stc compilation of prerequisite packages |
|
2242 |
an subprojects" |
|
2243 |
||
2244 |
^ self globalDefines |
|
2245 |
! |
|
2246 |
||
2247 |
globalDefines_win32 |
|
2248 |
"allow for the specification of additional defines for stc compilation of prerequisite packages |
|
2249 |
an subprojects" |
|
2250 |
||
2251 |
^ self globalDefines |
|
2252 |
! |
|
2253 |
||
10331 | 2254 |
localDefines |
10979 | 2255 |
"allow for the specification of additional defines for stc compilation" |
10331 | 2256 |
|
2257 |
^ '' |
|
2258 |
! |
|
2259 |
||
2260 |
localDefines_unix |
|
10979 | 2261 |
"allow for the specification of additional defines for stc compilation" |
10331 | 2262 |
|
2263 |
^ self localDefines |
|
2264 |
! |
|
2265 |
||
2266 |
localDefines_win32 |
|
10979 | 2267 |
"allow for the specification of additional defines for stc compilation" |
10331 | 2268 |
|
2269 |
^ self localDefines |
|
2270 |
! |
|
2271 |
||
9826
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
2272 |
localIncludes |
10979 | 2273 |
"allow for the specification of additional include directories" |
9714 | 2274 |
|
2275 |
^ '' |
|
2276 |
||
9826
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
2277 |
"Created: / 06-09-2006 / 18:14:31 / cg" |
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
2278 |
! |
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
2279 |
|
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
2280 |
localIncludes_unix |
10979 | 2281 |
"allow for the specification of additional include directories" |
9826
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
2282 |
|
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
2283 |
^ self makeUnixIncludes:(self localIncludes) |
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
2284 |
|
9714 | 2285 |
"Created: / 18-08-2006 / 12:50:27 / cg" |
9826
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
2286 |
"Modified: / 06-09-2006 / 18:15:26 / cg" |
9714 | 2287 |
! |
2288 |
||
2289 |
localIncludes_win32 |
|
10979 | 2290 |
"allow for the specification of additional include directories" |
9714 | 2291 |
|
9826
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
2292 |
^ self makeWin32Includes:(self localIncludes) |
9714 | 2293 |
|
2294 |
"Created: / 18-08-2006 / 12:50:27 / cg" |
|
9826
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
2295 |
"Modified: / 06-09-2006 / 18:15:37 / cg" |
9714 | 2296 |
! |
2297 |
||
11576
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2298 |
primaryTarget |
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2299 |
"allows the primary make target to be defined in the Make.proto/bc.mak file." |
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2300 |
|
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2301 |
^ '' |
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2302 |
|
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2303 |
"Created: / 22-08-2006 / 23:53:33 / cg" |
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2304 |
! |
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2305 |
|
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2306 |
primaryTarget_bc_dot_mak |
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2307 |
"allows the primary make target to be defined in the bc.mak file." |
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2308 |
|
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2309 |
^ self primaryTarget |
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2310 |
|
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2311 |
"Created: / 22-08-2006 / 23:53:33 / cg" |
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2312 |
! |
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2313 |
|
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2314 |
primaryTarget_make_dot_proto |
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2315 |
"allows the primary make target to be defined in the Make.proto file." |
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2316 |
|
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2317 |
^ self primaryTarget |
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2318 |
|
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2319 |
"Created: / 22-08-2006 / 23:53:33 / cg" |
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2320 |
! |
8b244e994b96
Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents:
11562
diff
changeset
|
2321 |
|
13687
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2322 |
singleHeaderRuleTemplate_bc_dot_mak |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2323 |
"rules for header files (of autoloaded classes)" |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2324 |
|
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2325 |
^ ' |
13688
4f43dc4a3182
added: #additionalHeaderRulesUsingTemplate:pathConverter:
Claus Gittinger <cg@exept.de>
parents:
13687
diff
changeset
|
2326 |
%1\%2.$(H): |
4f43dc4a3182
added: #additionalHeaderRulesUsingTemplate:pathConverter:
Claus Gittinger <cg@exept.de>
parents:
13687
diff
changeset
|
2327 |
pushd %1 \ |
13687
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2328 |
& $(STC) $(FFLAGS) $(STCFLAGS) $(STC_MSGFORMAT) $(DBGFLAGS) $(DEFS) -C -headerOnly %2.st \ |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2329 |
& popd |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2330 |
' |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2331 |
|
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2332 |
"Created: / 12-09-2011 / 15:55:49 / cg" |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2333 |
! |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2334 |
|
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2335 |
singleHeaderRuleTemplate_make_dot_proto |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2336 |
"rules for header files (of autoloaded classes)" |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2337 |
|
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2338 |
^ ' |
13688
4f43dc4a3182
added: #additionalHeaderRulesUsingTemplate:pathConverter:
Claus Gittinger <cg@exept.de>
parents:
13687
diff
changeset
|
2339 |
%1/%2.$(H): |
4f43dc4a3182
added: #additionalHeaderRulesUsingTemplate:pathConverter:
Claus Gittinger <cg@exept.de>
parents:
13687
diff
changeset
|
2340 |
pushd %1 \ |
13687
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2341 |
& $(STC) $(FFLAGS) $(STCFLAGS) $(STC_MSGFORMAT) $(DBGFLAGS) $(DEFS) -C -headerOnly %2.st \ |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2342 |
& popd |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2343 |
' |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2344 |
|
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2345 |
"Created: / 12-09-2011 / 15:55:57 / cg" |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2346 |
! |
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
2347 |
|
9575 | 2348 |
stcOptimizationOptions |
2349 |
"see the stc reference / stc usage for options. |
|
2350 |
For now, the following variants are useful: |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2351 |
+optspace3 most compact code |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2352 |
- use for all gui, application code. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2353 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2354 |
+optinline +optinline2 +inlineNew |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2355 |
fastest code |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2356 |
- use only for computation-intensive classes" |
9575 | 2357 |
|
2358 |
^ '+optspace3' |
|
2359 |
||
2360 |
"Created: / 18-08-2006 / 12:50:27 / cg" |
|
9536 | 2361 |
! |
2362 |
||
9575 | 2363 |
stcWarningOptions |
2364 |
"see the stc reference / stc usage for options. |
|
2365 |
For now, the following variants are useful: |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2366 |
-warn no warnings |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2367 |
-warnNonStandard no warnings about non-standard smalltalk features" |
9575 | 2368 |
|
9714 | 2369 |
^ '-warnNonStandard' |
9575 | 2370 |
|
2371 |
"Created: / 18-08-2006 / 12:51:38 / cg" |
|
2372 |
! ! |
|
9536 | 2373 |
|
9575 | 2374 |
!ProjectDefinition class methodsFor:'description - project information'! |
2375 |
||
11611
fa06cde6bd11
Allow for additional icon files to be placed in resources
Stefan Vogel <sv@exept.de>
parents:
11580
diff
changeset
|
2376 |
applicationAdditionalIconFileNames |
13419 | 2377 |
"Return the icon-filenames for additional icons of the application |
11611
fa06cde6bd11
Allow for additional icon files to be placed in resources
Stefan Vogel <sv@exept.de>
parents:
11580
diff
changeset
|
2378 |
(empty collection if there are none)" |
fa06cde6bd11
Allow for additional icon files to be placed in resources
Stefan Vogel <sv@exept.de>
parents:
11580
diff
changeset
|
2379 |
|
fa06cde6bd11
Allow for additional icon files to be placed in resources
Stefan Vogel <sv@exept.de>
parents:
11580
diff
changeset
|
2380 |
^ #() |
fa06cde6bd11
Allow for additional icon files to be placed in resources
Stefan Vogel <sv@exept.de>
parents:
11580
diff
changeset
|
2381 |
! |
fa06cde6bd11
Allow for additional icon files to be placed in resources
Stefan Vogel <sv@exept.de>
parents:
11580
diff
changeset
|
2382 |
|
11039
1f977c01e7df
Fix usage of #iconFilename vs. #applicationIconFilename
Stefan Vogel <sv@exept.de>
parents:
11035
diff
changeset
|
2383 |
applicationIconFileName |
1f977c01e7df
Fix usage of #iconFilename vs. #applicationIconFilename
Stefan Vogel <sv@exept.de>
parents:
11035
diff
changeset
|
2384 |
"Return the icon-filename for the application (nil if there is none)" |
1f977c01e7df
Fix usage of #iconFilename vs. #applicationIconFilename
Stefan Vogel <sv@exept.de>
parents:
11035
diff
changeset
|
2385 |
|
1f977c01e7df
Fix usage of #iconFilename vs. #applicationIconFilename
Stefan Vogel <sv@exept.de>
parents:
11035
diff
changeset
|
2386 |
^ nil |
1f977c01e7df
Fix usage of #iconFilename vs. #applicationIconFilename
Stefan Vogel <sv@exept.de>
parents:
11035
diff
changeset
|
2387 |
! |
1f977c01e7df
Fix usage of #iconFilename vs. #applicationIconFilename
Stefan Vogel <sv@exept.de>
parents:
11035
diff
changeset
|
2388 |
|
9575 | 2389 |
companyName |
9584 | 2390 |
"Returns a company string which will appear in <lib>.rc. |
2391 |
Under win32, this is placed into the dlls file-info" |
|
9575 | 2392 |
|
13419 | 2393 |
( |
11172 | 2394 |
#( |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2395 |
'stx' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2396 |
'exept' |
11172 | 2397 |
) includes:self module) ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2398 |
^ 'eXept Software AG' |
9575 | 2399 |
]. |
2400 |
||
2401 |
^ 'My Company' |
|
2402 |
||
9584 | 2403 |
"Modified: / 18-08-2006 / 16:08:20 / cg" |
9536 | 2404 |
! |
2405 |
||
2406 |
description |
|
10306 | 2407 |
"Returns a description string which will appear in vc.def / bc.def" |
9536 | 2408 |
|
9803 | 2409 |
^self productName,' ',self packageName |
2410 |
"/ ^ self name |
|
9536 | 2411 |
|
2412 |
"Created: / 08-08-2006 / 11:15:01 / fm" |
|
9575 | 2413 |
"Modified: / 17-08-2006 / 20:53:34 / cg" |
2414 |
! |
|
2415 |
||
2416 |
fileDescription |
|
10416 | 2417 |
"Returns a description string which will appear in libName.rc and the rc-file" |
9575 | 2418 |
|
9803 | 2419 |
^self description |
9575 | 2420 |
|
2421 |
"Modified: / 17-08-2006 / 20:27:07 / cg" |
|
2422 |
! |
|
2423 |
||
2424 |
fileMajorVersionNr |
|
2425 |
"Returns a versionNumber which will appear in libName.rc" |
|
2426 |
||
11100
c9ec12ef4b3b
Set default for fileMajorVersionNumber and fileMajorVersionNumber
Stefan Vogel <sv@exept.de>
parents:
11074
diff
changeset
|
2427 |
^ self majorVersionNr |
9575 | 2428 |
|
2429 |
"Created: / 18-08-2006 / 12:03:32 / cg" |
|
9817 | 2430 |
"Modified: / 30-08-2006 / 18:50:51 / cg" |
9575 | 2431 |
! |
2432 |
||
2433 |
fileMinorVersionNr |
|
2434 |
"Returns a versionNumber which will appear in libName.rc" |
|
2435 |
||
11100
c9ec12ef4b3b
Set default for fileMajorVersionNumber and fileMajorVersionNumber
Stefan Vogel <sv@exept.de>
parents:
11074
diff
changeset
|
2436 |
^ self minorVersionNr |
9575 | 2437 |
|
2438 |
"Created: / 18-08-2006 / 12:03:13 / cg" |
|
9817 | 2439 |
"Modified: / 30-08-2006 / 18:50:46 / cg" |
9575 | 2440 |
! |
2441 |
||
2442 |
fileReleaseNr |
|
2443 |
"Returns a releaseNumber which will appear in libName.rc" |
|
2444 |
||
11035
ff88ec6339a3
Generate valid project.rc files even if the CVS revision string ends with
Stefan Vogel <sv@exept.de>
parents:
10979
diff
changeset
|
2445 |
"take the default revision from the cvs-version, |
ff88ec6339a3
Generate valid project.rc files even if the CVS revision string ends with
Stefan Vogel <sv@exept.de>
parents:
10979
diff
changeset
|
2446 |
but ignore a possibly present 'm'-flag that is set when this revision has been modified" |
ff88ec6339a3
Generate valid project.rc files even if the CVS revision string ends with
Stefan Vogel <sv@exept.de>
parents:
10979
diff
changeset
|
2447 |
|
ff88ec6339a3
Generate valid project.rc files even if the CVS revision string ends with
Stefan Vogel <sv@exept.de>
parents:
10979
diff
changeset
|
2448 |
^ self cvsRevision last upTo:$m |
9575 | 2449 |
|
2450 |
"Created: / 18-08-2006 / 12:02:58 / cg" |
|
9817 | 2451 |
"Modified: / 30-08-2006 / 18:54:48 / cg" |
9536 | 2452 |
! |
2453 |
||
9575 | 2454 |
fileRevisionNr |
2455 |
"Returns a revisionNumber which will appear in libName.rc" |
|
9536 | 2456 |
|
9817 | 2457 |
"take the default revision from the cvs-version" |
9618 | 2458 |
^ self cvsRevision first |
9575 | 2459 |
|
2460 |
"Created: / 18-08-2006 / 12:02:39 / cg" |
|
9817 | 2461 |
"Modified: / 30-08-2006 / 18:54:39 / cg" |
9536 | 2462 |
! |
2463 |
||
9575 | 2464 |
fileVersion |
2465 |
"Returns a fileVersion string which will appear in libName.rc" |
|
2466 |
||
2467 |
"<major>.<minor>.<rev>.<rel> (such as '1.2.17.1') " |
|
2468 |
||
13419 | 2469 |
^ '%1.%2.%3.%4' |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2470 |
bindWith:self fileMajorVersionNr |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2471 |
with:self fileMinorVersionNr |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2472 |
with:self fileRevisionNr |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2473 |
with:self fileReleaseNr. |
9575 | 2474 |
|
2475 |
" |
|
2476 |
self fileVersion |
|
2477 |
" |
|
2478 |
||
9817 | 2479 |
"Modified: / 30-08-2006 / 18:51:49 / cg" |
9575 | 2480 |
! |
9536 | 2481 |
|
9575 | 2482 |
fileVersionCommaSeparated |
2483 |
"Returns a fileVersion string which will appear in libName.rc" |
|
2484 |
||
9817 | 2485 |
"<major>,<minor>,<revision>,<release> (such as '2,17,1,2') " |
2486 |
||
13419 | 2487 |
^ '%1,%2,%3,%4' |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2488 |
bindWith:self fileMajorVersionNr |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2489 |
with:self fileMinorVersionNr |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2490 |
with:self fileRevisionNr |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2491 |
with:self fileReleaseNr. |
9575 | 2492 |
|
2493 |
"Created: / 17-08-2006 / 20:16:17 / cg" |
|
9817 | 2494 |
"Modified: / 30-08-2006 / 18:54:20 / cg" |
2495 |
! |
|
2496 |
||
9575 | 2497 |
internalName |
2498 |
"Returns a name string which will appear in libName.rc" |
|
2499 |
||
11041
3bb26d86e616
Fix #description and #internalName
Stefan Vogel <sv@exept.de>
parents:
11039
diff
changeset
|
2500 |
^ self package |
9575 | 2501 |
|
2502 |
"Modified: / 17-08-2006 / 20:27:37 / cg" |
|
9536 | 2503 |
! |
2504 |
||
9575 | 2505 |
legalCopyright |
9584 | 2506 |
"Returns a copyright string which will appear in <lib>.rc. |
2507 |
Under win32, this is placed into the dlls file-info" |
|
9575 | 2508 |
|
2509 |
self module = 'stx' ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2510 |
"hardwired-default" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2511 |
^ 'Copyright Claus Gittinger 1988-%1\nCopyright eXept Software AG 1998-%1' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2512 |
bindWith:(Date today year printString) |
9575 | 2513 |
]. |
9817 | 2514 |
self module = 'exept' ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2515 |
"hardwired-default" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2516 |
^ 'Copyright eXept Software AG 1998-%1' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2517 |
bindWith:(Date today year printString) |
9817 | 2518 |
]. |
9575 | 2519 |
|
2520 |
^ 'My CopyRight or CopyLeft' |
|
2521 |
||
9817 | 2522 |
"Modified: / 30-08-2006 / 18:53:36 / cg" |
9575 | 2523 |
! |
2524 |
||
2525 |
majorVersionNr |
|
2526 |
"Returns a versionNumber which will appear in libName.rc" |
|
2527 |
||
2528 |
"<major>.<minor>.<revision>.<release> (such as '5.3.2.1') |
|
2529 |
the default here takes smalltalks version number. |
|
2530 |
But thats probably not good for an end-user-app." |
|
2531 |
||
11042 | 2532 |
^ Smalltalk majorVersionNr |
9575 | 2533 |
|
2534 |
"Created: / 17-08-2006 / 20:20:18 / cg" |
|
9817 | 2535 |
"Modified: / 30-08-2006 / 18:52:13 / cg" |
9575 | 2536 |
! |
2537 |
||
2538 |
minorVersionNr |
|
2539 |
"Returns a versionNumber which will appear in libName.rc" |
|
9536 | 2540 |
|
9575 | 2541 |
"<major>.<minor>.<revision>.<release> (such as '5.3.2.1') |
2542 |
the default here takes smalltalks version number. |
|
2543 |
But thats probably not good for an end-user-app." |
|
2544 |
||
11042 | 2545 |
^ Smalltalk minorVersionNr |
9575 | 2546 |
|
2547 |
"Created: / 17-08-2006 / 20:20:32 / cg" |
|
9817 | 2548 |
"Modified: / 30-08-2006 / 18:52:16 / cg" |
9575 | 2549 |
! |
2550 |
||
2551 |
productDate |
|
11043 | 2552 |
"Returns a product-date string which will appear in libName.rc and the installer file" |
9575 | 2553 |
|
2554 |
"take the current date - by default" |
|
9536 | 2555 |
|
9575 | 2556 |
^ Timestamp now printStringRFC1123Format |
2557 |
||
2558 |
"Created: / 17-08-2006 / 20:17:28 / cg" |
|
2559 |
! |
|
2560 |
||
13177 | 2561 |
productDescription |
2562 |
"Returns a description (for autopackage)" |
|
2563 |
||
2564 |
^ self description |
|
2565 |
||
2566 |
"Created: / 21-12-2010 / 09:32:16 / cg" |
|
2567 |
! |
|
2568 |
||
10426 | 2569 |
productFilename |
2570 |
"Returns a filename which be used as linkname, product file name etc." |
|
2571 |
||
2572 |
^ self productNameAsValidFilename |
|
2573 |
||
2574 |
" |
|
13419 | 2575 |
stx_projects_smalltalk productName |
10426 | 2576 |
stx_projects_smalltalk productFilename |
2577 |
" |
|
2578 |
||
2579 |
"Created: / 01-03-2007 / 19:33:06 / cg" |
|
2580 |
! |
|
2581 |
||
9898 | 2582 |
productInstallDir |
13873 | 2583 |
"Returns a default installDir which will appear in <app>.nsi." |
2584 |
||
2585 |
^ '$PROGRAMFILES\',(self productInstallDirBaseName). |
|
2586 |
||
2587 |
" |
|
2588 |
stx_projects_smalltalk productInstallDir |
|
2589 |
stx_clients_Clock_QlockTwoWatchApplication productInstallDir |
|
2590 |
" |
|
9898 | 2591 |
|
2592 |
"Created: / 14-09-2006 / 21:23:01 / cg" |
|
2593 |
! |
|
2594 |
||
13873 | 2595 |
productInstallDirBaseName |
2596 |
"Returns a default installDir which will appear in <app>.nsi. |
|
2597 |
This is usually not the one you want to keep" |
|
2598 |
||
2599 |
^ self module |
|
2600 |
||
2601 |
"Created: / 21-12-2011 / 16:31:38 / cg" |
|
2602 |
! |
|
2603 |
||
13177 | 2604 |
productLicense |
2605 |
"Returns the license (for autopackage)" |
|
2606 |
||
2607 |
^ 'Commercial' |
|
2608 |
||
2609 |
"Created: / 21-12-2010 / 09:31:25 / cg" |
|
2610 |
! |
|
2611 |
||
2612 |
productMaintainer |
|
2613 |
"Returns the maintainer (for autopackage)" |
|
2614 |
||
2615 |
^ self companyName |
|
2616 |
||
2617 |
"Created: / 21-12-2010 / 09:26:16 / cg" |
|
2618 |
! |
|
2619 |
||
9575 | 2620 |
productName |
9584 | 2621 |
"Returns a product name which will appear in <lib>.rc. |
2622 |
Under win32, this is placed into the dlls file-info" |
|
9575 | 2623 |
|
10785
da5023cdf55b
no need for productName string (already inherited)
Claus Gittinger <cg@exept.de>
parents:
10774
diff
changeset
|
2624 |
|m| |
da5023cdf55b
no need for productName string (already inherited)
Claus Gittinger <cg@exept.de>
parents:
10774
diff
changeset
|
2625 |
|
da5023cdf55b
no need for productName string (already inherited)
Claus Gittinger <cg@exept.de>
parents:
10774
diff
changeset
|
2626 |
m := self module. |
da5023cdf55b
no need for productName string (already inherited)
Claus Gittinger <cg@exept.de>
parents:
10774
diff
changeset
|
2627 |
m = 'stx' ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2628 |
^ 'Smalltalk/X' |
9575 | 2629 |
]. |
10785
da5023cdf55b
no need for productName string (already inherited)
Claus Gittinger <cg@exept.de>
parents:
10774
diff
changeset
|
2630 |
m = 'exept' ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2631 |
^ 'eXept addOns' |
10785
da5023cdf55b
no need for productName string (already inherited)
Claus Gittinger <cg@exept.de>
parents:
10774
diff
changeset
|
2632 |
]. |
10296 | 2633 |
Error handle:[:ex | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2634 |
^ 'ProductName' |
10296 | 2635 |
] do:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2636 |
^ self startupClassName |
10296 | 2637 |
]. |
2638 |
||
10785
da5023cdf55b
no need for productName string (already inherited)
Claus Gittinger <cg@exept.de>
parents:
10774
diff
changeset
|
2639 |
"Modified: / 08-11-2007 / 16:45:14 / cg" |
9536 | 2640 |
! |
2641 |
||
10426 | 2642 |
productNameAsValidFilename |
2643 |
"Returns a product name which will appear in <lib>.rc. |
|
2644 |
Under win32, this is placed into the dlls file-info" |
|
2645 |
||
2646 |
|nm| |
|
2647 |
||
2648 |
nm := self productName. |
|
2649 |
^ nm copy replaceAny:'/\:;.,' with:$_ |
|
2650 |
||
2651 |
" |
|
2652 |
'Smalltalk/X' replaceAny:'/\:;.,' with:nil |
|
2653 |
" |
|
2654 |
||
2655 |
"Created: / 01-03-2007 / 19:19:21 / cg" |
|
2656 |
! |
|
2657 |
||
9898 | 2658 |
productPublisher |
2659 |
"Returns a product publisher which will appear in <app>.nsi." |
|
2660 |
||
2661 |
( #('exept' 'stx') includes:self module) ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2662 |
^ 'eXept Software AG' |
9898 | 2663 |
]. |
2664 |
||
11789
8d56dc5fa8a8
Default productPublisher is companyName
Stefan Vogel <sv@exept.de>
parents:
11777
diff
changeset
|
2665 |
^ self companyName |
9898 | 2666 |
|
2667 |
"Created: / 14-09-2006 / 21:12:54 / cg" |
|
2668 |
! |
|
2669 |
||
13177 | 2670 |
productType |
2671 |
"Returns the product type for autopackage" |
|
2672 |
||
2673 |
^ 'Application' |
|
2674 |
||
2675 |
"Created: / 21-12-2010 / 09:28:48 / cg" |
|
2676 |
! |
|
2677 |
||
9575 | 2678 |
productVersion |
11043 | 2679 |
"Returns a product version which will appear in libName.rc and the installer file" |
9575 | 2680 |
|
2681 |
"<major>.<minor>.<revision>.<release> (such as '5.3.2.1')" |
|
9536 | 2682 |
|
13419 | 2683 |
^ '%1.%2.%3.%4' |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2684 |
bindWith:self majorVersionNr |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2685 |
with:self minorVersionNr |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2686 |
with:self revisionNr |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2687 |
with:self releaseNr. |
9536 | 2688 |
|
9575 | 2689 |
" |
2690 |
self productVersion |
|
2691 |
" |
|
2692 |
||
9817 | 2693 |
"Modified: / 30-08-2006 / 18:52:47 / cg" |
9536 | 2694 |
! |
2695 |
||
9575 | 2696 |
productVersionCommaSeparated |
2697 |
"Returns a product version which will appear in libName.rc" |
|
2698 |
||
2699 |
"<major>.<minor>.<revision>.<release> (such as '0,1,1,1') " |
|
9536 | 2700 |
|
13419 | 2701 |
^ '%1,%2,%3,%4' |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2702 |
bindWith:self majorVersionNr |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2703 |
with:self minorVersionNr |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2704 |
with:self revisionNr |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2705 |
with:self releaseNr. |
11042 | 2706 |
|
2707 |
" |
|
2708 |
self productVersionCommaSeparated |
|
2709 |
" |
|
9536 | 2710 |
|
9575 | 2711 |
"Created: / 17-08-2006 / 20:13:32 / cg" |
9817 | 2712 |
"Modified: / 30-08-2006 / 18:52:42 / cg" |
9536 | 2713 |
! |
2714 |
||
9898 | 2715 |
productWebSite |
2716 |
"Returns a product webSite which will appear in <app>.nsi." |
|
2717 |
||
2718 |
( #('exept' 'stx') includes:self module) ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2719 |
^ 'http://www.exept.de' |
9898 | 2720 |
]. |
2721 |
||
10426 | 2722 |
"/ should be redefined by concrete ApplicationDefinition |
9898 | 2723 |
^ 'http://www.yoursite.com' |
2724 |
||
2725 |
"Created: / 14-09-2006 / 21:15:05 / cg" |
|
10426 | 2726 |
"Modified: / 01-03-2007 / 18:11:27 / cg" |
9898 | 2727 |
! |
2728 |
||
9575 | 2729 |
releaseNr |
2730 |
"Returns a releaseNr which will appear in libName.rc" |
|
2731 |
||
2732 |
"<major>.<minor>.<revision>.<release> (such as '5.3.2.1') |
|
2733 |
the default here takes smalltalks version number. |
|
2734 |
But thats probably not good for an end-user-app." |
|
2735 |
||
11042 | 2736 |
^ Smalltalk releaseNr |
9536 | 2737 |
|
9575 | 2738 |
"Created: / 17-08-2006 / 20:20:51 / cg" |
9817 | 2739 |
"Modified: / 30-08-2006 / 18:52:22 / cg" |
9575 | 2740 |
! |
2741 |
||
2742 |
revisionNr |
|
2743 |
"Returns a revisionNr which will appear in libName.rc" |
|
9536 | 2744 |
|
9575 | 2745 |
"<major>.<minor>.<revision>.<release> (such as '5.3.2.1') |
2746 |
the default here takes smalltalks version number. |
|
2747 |
But thats probably not good for an end-user-app." |
|
2748 |
||
11042 | 2749 |
^ Smalltalk revisionNr |
9575 | 2750 |
|
2751 |
"Created: / 17-08-2006 / 20:20:40 / cg" |
|
9817 | 2752 |
"Modified: / 30-08-2006 / 18:52:32 / cg" |
9536 | 2753 |
! |
2754 |
||
2755 |
versionNumber |
|
10306 | 2756 |
"Returns a version string which will appear in bc.def / vc.def " |
9536 | 2757 |
|
9575 | 2758 |
^'' |
9536 | 2759 |
|
2760 |
"Created: / 08-08-2006 / 11:35:52 / fm" |
|
9575 | 2761 |
"Modified: / 17-08-2006 / 19:46:29 / cg" |
9536 | 2762 |
! ! |
2763 |
||
9569 | 2764 |
!ProjectDefinition class methodsFor:'file generation'! |
9536 | 2765 |
|
13177 | 2766 |
apspecFilename |
13968 | 2767 |
"/ for linux |
13177 | 2768 |
^ 'autopackage/default.apspec' |
2769 |
||
2770 |
"Created: / 21-12-2010 / 09:43:13 / cg" |
|
2771 |
! |
|
2772 |
||
9852 | 2773 |
basicFileNamesToGenerate |
13419 | 2774 |
"answer a dictionary (filename -> generator method) with all the files, |
11937 | 2775 |
that have to be generated for this package" |
10864
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2776 |
|
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2777 |
|dict| |
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2778 |
|
13419 | 2779 |
dict := OrderedDictionary withKeysAndValues:#( |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2780 |
'Make.spec' #'generate_make_dot_spec' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2781 |
'Make.proto' #'generate_make_dot_proto' |
13968 | 2782 |
'Makefile' #'generate_makefile' "/ for unix |
2783 |
'bc.mak' #'generate_bc_dot_mak' "/ for windows |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2784 |
'abbrev.stc' #'generate_abbrev_dot_stc' |
13968 | 2785 |
'bmake.bat' #'generate_bmake_dot_mak' "/ for bcc32 |
2786 |
'vcmake.bat' #'generate_vcmake_dot_mak' "/ for msvc |
|
2787 |
'lcmake.bat' #'generate_lcmake_dot_mak' "/ for lcc |
|
10864
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2788 |
). |
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2789 |
|
13419 | 2790 |
dict |
13968 | 2791 |
at:self rcFilename put:#'generate_packageName_dot_rc'; "/ for windows |
2792 |
at:self apspecFilename put:#'generate_autopackage_default_dot_apspec'. "/ for linux |
|
10864
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2793 |
|
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2794 |
^ dict. |
13154
bac0fcd8a888
make sure that the makefiles are generated before the libInit file
Claus Gittinger <cg@exept.de>
parents:
13148
diff
changeset
|
2795 |
|
13177 | 2796 |
"Modified: / 21-12-2010 / 11:02:02 / cg" |
13968 | 2797 |
"Modified (comment): / 21-01-2012 / 12:32:45 / cg" |
9852 | 2798 |
! |
2799 |
||
9536 | 2800 |
fileNamesToGenerate |
12200
7e452033e984
rememberOverwrittenExtensionMethods
Claus Gittinger <cg@exept.de>
parents:
12198
diff
changeset
|
2801 |
"answer the files that have to be generated as a dictionary of names and generator method" |
10864
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2802 |
|
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2803 |
^ self basicFileNamesToGenerate removeAllKeys:self protectedFileNames ifAbsent:[] |
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2804 |
|
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2805 |
" |
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2806 |
stx_libbasic fileNamesToGenerate |
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2807 |
" |
9536 | 2808 |
! |
2809 |
||
13419 | 2810 |
forEachFileNameAndGeneratedContentsDo:aTwoArgBlock |
9544 | 2811 |
|pairs| |
2812 |
||
2813 |
pairs := OrderedCollection new. |
|
13419 | 2814 |
self forEachFileNameAndGeneratorMethodDo:[:fileName :generator | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2815 |
|file| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2816 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2817 |
file := self perform:generator. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2818 |
pairs add:(Array with:fileName with:file) |
9544 | 2819 |
]. |
2820 |
||
2821 |
pairs pairsDo:aTwoArgBlock |
|
2822 |
||
2823 |
"Created: / 16-08-2006 / 18:37:52 / User" |
|
2824 |
! |
|
2825 |
||
13419 | 2826 |
forEachFileNameAndGeneratorMethodDo:aTwoArgBlock |
10864
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2827 |
self fileNamesToGenerate keysAndValuesDo:aTwoArgBlock |
9831 | 2828 |
|
9898 | 2829 |
"Modified: / 14-09-2006 / 21:02:37 / cg" |
9536 | 2830 |
! |
2831 |
||
2832 |
generateFile:filename |
|
10864
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2833 |
|action| |
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2834 |
|
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2835 |
action := self basicFileNamesToGenerate at:filename ifAbsent:[]. |
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2836 |
action notNil ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2837 |
^ self perform:action |
10864
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2838 |
]. |
512cd79cee0e
Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents:
10849
diff
changeset
|
2839 |
(filename = 'app.rc' or:[filename = 'lib.rc']) ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2840 |
^ self generate_packageName_dot_rc |
9607 | 2841 |
]. |
9850 | 2842 |
(filename = 'loadAll') ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2843 |
^ self generate_loadAll |
9850 | 2844 |
]. |
13177 | 2845 |
(filename = 'autopackage/default.apspec' or:[filename = self apspecFilename]) ifTrue:[ |
13968 | 2846 |
"/ for linux |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2847 |
^ self generate_autopackage_default_dot_apspec |
13177 | 2848 |
]. |
2849 |
self error:('File "%1" not appropriate (not generated) for this type of project.' bindWith:filename) |
|
2850 |
||
2851 |
"Modified: / 21-12-2010 / 11:01:10 / cg" |
|
13968 | 2852 |
"Modified (format): / 21-01-2012 / 12:31:40 / cg" |
9536 | 2853 |
! |
2854 |
||
13411 | 2855 |
generateFile:filename in: directory |
2856 |
||
2857 |
| dir s | |
|
2858 |
dir := directory asFilename. |
|
2859 |
dir exists ifFalse:[self error:'Directory does not exist']. |
|
2860 |
[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2861 |
s := ( dir / (filename asFilename baseName) ) writeStream. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2862 |
s nextPutAll: (self generateFile: filename). |
13411 | 2863 |
] ensure:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2864 |
s ifNotNil:[s close] |
13411 | 2865 |
] |
2866 |
||
2867 |
" |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2868 |
stx_projects_smalltalk generateFile:'package.deps.rake' in: '/tmp' |
13411 | 2869 |
" |
2870 |
||
2871 |
"Created: / 26-02-2011 / 10:42:58 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
2872 |
"Modified: / 09-06-2011 / 14:53:01 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
2873 |
! |
|
2874 |
||
11868
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2875 |
generateRemoveShellScriptOn:aStream |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2876 |
"generate a shell script to a cvs remove of broken class filenames. |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2877 |
To be called after the output of #generateRenameShellScript: has been performed" |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2878 |
|
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2879 |
|firstLine| |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2880 |
|
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2881 |
firstLine := true. |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2882 |
self searchForClasses do:[:eachClass| |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2883 |
firstLine ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2884 |
aStream nextPutAll:'cvs rm -f '. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2885 |
firstLine := false. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2886 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2887 |
eachClass classFilename ~= (eachClass generateClassFilename, '.st') ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2888 |
aStream nextPutAll:eachClass classBaseFilename; space. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2889 |
] |
11868
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2890 |
]. |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2891 |
firstLine ifFalse:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2892 |
aStream cr. |
11868
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2893 |
]. |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2894 |
|
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2895 |
" |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2896 |
stx_goodies_webServer_htmlTree generateRemoveShellScriptOn:Transcript |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2897 |
" |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2898 |
! |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2899 |
|
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2900 |
generateRenameShellScriptOn:aStream |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2901 |
"generate a shell script to rename broken class filenames" |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2902 |
|
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2903 |
self searchForClasses do:[:eachClass| |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2904 |
eachClass classFilename ~= (eachClass generateClassFilename, '.st') ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2905 |
aStream nextPutAll:'cp '; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2906 |
nextPutAll:eachClass classBaseFilename; nextPutAll:',v '; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2907 |
nextPutAll:eachClass generateClassFilename; nextPutAll:'.st,v'; cr. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2908 |
] |
11868
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2909 |
]. |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2910 |
|
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2911 |
" |
11981
e479249ba36e
Fix #generateRenameShellScriptOn:
Stefan Vogel <sv@exept.de>
parents:
11980
diff
changeset
|
2912 |
stx_libdb generateRemoveShellScriptOn:Transcript |
11868
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2913 |
" |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2914 |
! |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2915 |
|
9536 | 2916 |
generate_abbrev_dot_stc |
13968 | 2917 |
"/ for stc: provides abbreviations and namespace information |
11868
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
2918 |
self checkIfClassesArePresent. |
10104
96bce48c03b5
some care for incomplete information bein present when
Claus Gittinger <cg@exept.de>
parents:
10103
diff
changeset
|
2919 |
|
13419 | 2920 |
^ String |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2921 |
streamContents:[:s | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2922 |
|addEntry| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2923 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2924 |
addEntry := |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2925 |
[:eachClassName | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2926 |
|cls fn wasLoaded failedToLoad numClassInstvars| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2927 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2928 |
s nextPutAll:eachClassName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2929 |
s nextPutAll:' '. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2930 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2931 |
cls := Smalltalk classNamed:eachClassName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2932 |
cls isNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2933 |
fn := self filenameForClass:eachClassName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2934 |
s nextPutAll:fn. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2935 |
s nextPutAll:' '; nextPutAll:(self package); nextPutAll:' '. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2936 |
s nextPutAll:' '; nextPutAll:'unknownCategory' storeString; nextPutAll:' '. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2937 |
s nextPutAll:' '; nextPutAll:'0'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2938 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2939 |
wasLoaded := cls isLoaded. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2940 |
wasLoaded ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2941 |
failedToLoad := false. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2942 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2943 |
Error handle:[:ex | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2944 |
failedToLoad := true. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2945 |
] do:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2946 |
ParserFlags |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2947 |
withSTCCompilation:#never |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2948 |
do:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2949 |
cls autoload. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2950 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2951 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2952 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2953 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2954 |
fn := self filenameForClass:cls. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2955 |
(fn includes:Character space) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2956 |
s nextPutAll:fn storeString. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2957 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2958 |
s nextPutAll:fn. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2959 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2960 |
s nextPutAll:' '; nextPutAll:(self package); nextPutAll:' '. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2961 |
s nextPutAll: (cls category asString storeString). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2962 |
failedToLoad ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2963 |
s nextPutAll:' 0'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2964 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2965 |
numClassInstvars := cls theMetaclass instSize - Class instSize. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2966 |
s nextPutAll:' '; nextPutAll:numClassInstvars printString. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2967 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2968 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2969 |
wasLoaded ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2970 |
cls unload |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2971 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2972 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2973 |
s cr. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2974 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2975 |
|
13968 | 2976 |
s nextPutLine:'# automagically generated by the project definition'. |
2977 |
s nextPutLine:'# this file is needed for stc to be able to compile modules independently.'. |
|
2978 |
s nextPutLine:'# it provides information about a classes filename, category and especially namespace.'. |
|
2979 |
||
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2980 |
self allClassNames do:addEntry. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2981 |
self namesAndAttributesIn:(self additionalClassNamesAndAttributes) do: [:nm :attr | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2982 |
(attr isEmptyOrNil or:[(attr includes:#autoload) not]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2983 |
addEntry value:nm |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2984 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2985 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2986 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2987 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2988 |
" |
13968 | 2989 |
stx_libbasic generate_abbrev_dot_stc |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2990 |
DapasXProject generate_abbrev_dot_stc |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2991 |
DapasX_Datenbasis generate_abbrev_dot_stc |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
2992 |
bosch_dapasx_interactiver_editor generate_abbrev_dot_stc |
9536 | 2993 |
" |
2994 |
||
2995 |
"Created: / 09-08-2006 / 11:24:39 / fm" |
|
13968 | 2996 |
"Modified: / 21-01-2012 / 12:42:57 / cg" |
9536 | 2997 |
! |
2998 |
||
13177 | 2999 |
generate_autopackage_default_dot_apspec |
3000 |
||
13419 | 3001 |
^self |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3002 |
replaceMappings: self autopackage_default_dot_apspec_mappings |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3003 |
in: self autopackage_default_dot_apspec |
13177 | 3004 |
|
3005 |
" |
|
3006 |
stx_projects_smalltalk generate_autopackage_default_dot_apspec |
|
3007 |
" |
|
3008 |
||
3009 |
"Created: / 21-12-2010 / 09:40:04 / cg" |
|
3010 |
! |
|
3011 |
||
13419 | 3012 |
generate_bc_dot_mak |
3013 |
^ (self |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3014 |
replaceMappings: self bc_dot_mak_mappings |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3015 |
in: self bc_dot_mak) asStringCollection withTabs asString |
10306 | 3016 |
|
3017 |
" |
|
3018 |
DapasXProject generate_bc_dot_mak |
|
3019 |
DapasX_Datenbasis generate_bc_dot_mak |
|
3020 |
" |
|
3021 |
||
3022 |
"Modified: / 09-08-2006 / 11:46:14 / fm" |
|
3023 |
! |
|
3024 |
||
13419 | 3025 |
generate_bmake_dot_mak |
3026 |
||
3027 |
^self replaceMappings: self bmake_dot_mak_mappings |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3028 |
in: self bmake_dot_mak |
9575 | 3029 |
|
3030 |
"Created: / 17-08-2006 / 20:03:43 / cg" |
|
3031 |
! |
|
3032 |
||
13411 | 3033 |
generate_builder_baseline_dot_rbspec |
3034 |
^ self replaceMappings:self builder_baseline_dot_rbspec_mappings |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3035 |
in:self builder_baseline_dot_rbspec |
13411 | 3036 |
|
3037 |
" |
|
3038 |
stx_projects_smalltalk generate_builder_baseline_dot_rbspec |
|
3039 |
||
3040 |
" |
|
3041 |
||
3042 |
"Created: / 24-02-2011 / 11:38:47 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
3043 |
! |
|
3044 |
||
13419 | 3045 |
generate_lcmake_dot_mak |
3046 |
||
3047 |
^self replaceMappings: self bmake_dot_mak_mappings |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3048 |
in: self lcmake_dot_mak |
11979 | 3049 |
! |
3050 |
||
9850 | 3051 |
generate_loadAll |
13419 | 3052 |
^ String |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3053 |
streamContents:[:s | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3054 |
|classNames classesLoaded classNamesUnloaded classesSorted classNamesSorted| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3055 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3056 |
classNames := self compiled_classNames_common. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3057 |
classesLoaded := classNames |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3058 |
collect:[:nm | Smalltalk classNamed:nm] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3059 |
thenSelect:[:cls | cls notNil and:[cls isLoaded] ]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3060 |
classNamesUnloaded := classNames |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3061 |
select:[:nm | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3062 |
|cls| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3063 |
cls := Smalltalk classNamed:nm. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3064 |
cls isNil or:[cls isLoaded not] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3065 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3066 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3067 |
classesSorted := Class classesSortedByLoadOrder:classesLoaded. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3068 |
classNamesSorted := classesSorted collect:[:cls | cls name]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3069 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3070 |
s nextPutAll:'"/ |
9850 | 3071 |
"/ $' , 'Header' , '$ |
3072 |
"/ |
|
3073 |
"/ loadAll-file to fileIn code for: ' , self package , ' |
|
3074 |
"/ |
|
3075 |
"/ Automatically generated from the ProjectDefinition. |
|
9911
114cf30d0561
Handle (load) binary class libraryies.
Stefan Vogel <sv@exept.de>
parents:
9909
diff
changeset
|
3076 |
"/ DO NOT MODIFY THIS FILE; |
9850 | 3077 |
"/ |
3078 |
"/ |
|
3079 |
"/ Prerequisites: |
|
3080 |
"/ |
|
3081 |
"/ Smalltalk loadPackage:''module:directory''. |
|
3082 |
"/ Smalltalk loadPackage:''....''. |
|
3083 |
!! |
|
3084 |
||
3085 |
"{ package:''' , self package, ''' }" |
|
3086 |
!! |
|
3087 |
||
3088 |
|files| |
|
3089 |
||
9911
114cf30d0561
Handle (load) binary class libraryies.
Stefan Vogel <sv@exept.de>
parents:
9909
diff
changeset
|
3090 |
''loading package ' , self package ,'...'' infoPrint. |
9850 | 3091 |
|
3092 |
files := #( |
|
3093 |
'. |
|
3094 |
||
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3095 |
classesSorted do:[:eachClass | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3096 |
s nextPutLine:' ''' , (self filenameForClass:eachClass), ''''. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3097 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3098 |
classNamesUnloaded do:[:nm | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3099 |
s nextPutLine:' ''' , (self filenameForClass:nm), ''''. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3100 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3101 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3102 |
self namesAndAttributesIn:(self additionalClassNamesAndAttributes) do:[:nm :attr | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3103 |
(attr isEmptyOrNil or:[(attr includes:#autoload) not]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3104 |
s nextPutLine:' ''' , (self filenameForClass:nm), ''''. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3105 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3106 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3107 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3108 |
self hasExtensionMethods ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3109 |
s nextPutLine:' ''extensions.st'''. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3110 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3111 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3112 |
s nextPutAll:' |
9911
114cf30d0561
Handle (load) binary class libraryies.
Stefan Vogel <sv@exept.de>
parents:
9909
diff
changeset
|
3113 |
). |
9850 | 3114 |
|
3115 |
"/ see if there is a classLibrary |
|
9911
114cf30d0561
Handle (load) binary class libraryies.
Stefan Vogel <sv@exept.de>
parents:
9909
diff
changeset
|
3116 |
(Smalltalk fileInClassLibrary:''' , (self libraryName) , ''') ifTrue:[ |
9850 | 3117 |
|handle loaded| |
3118 |
||
13419 | 3119 |
handle := ObjectFileLoader loadedObjectHandles |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3120 |
detect:[:h | h package = ''' , self package , '''] ifNone:nil. |
9850 | 3121 |
handle ifNotNil:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3122 |
loaded := Set new:(handle classes size). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3123 |
handle classes do:[:c| c isMeta ifFalse:[loaded add:c classBaseFilename]]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3124 |
files := files \ loaded. |
9850 | 3125 |
]. |
3126 |
]. |
|
3127 |
||
3128 |
"/ load files which are not in the classLibrary (all if there is none) |
|
9911
114cf30d0561
Handle (load) binary class libraryies.
Stefan Vogel <sv@exept.de>
parents:
9909
diff
changeset
|
3129 |
files notEmpty ifTrue:[ |
114cf30d0561
Handle (load) binary class libraryies.
Stefan Vogel <sv@exept.de>
parents:
9909
diff
changeset
|
3130 |
'''' infoPrintCR. |
9850 | 3131 |
files do:[:f | |
3132 |
''.'' infoPrint. |
|
3133 |
f asFilename exists ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3134 |
Smalltalk fileIn:f. |
9850 | 3135 |
] ifFalse:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3136 |
Smalltalk fileIn:(''source/'' , f) |
9850 | 3137 |
] |
3138 |
]. |
|
3139 |
'' '' infoPrintCR. |
|
3140 |
]. |
|
9911
114cf30d0561
Handle (load) binary class libraryies.
Stefan Vogel <sv@exept.de>
parents:
9909
diff
changeset
|
3141 |
''done (' , self package ,').'' infoPrintCR. |
9850 | 3142 |
'. |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3143 |
]. |
9850 | 3144 |
|
3145 |
"Created: / 14-09-2006 / 14:21:31 / cg" |
|
10080 | 3146 |
"Modified: / 12-10-2006 / 15:55:00 / cg" |
9850 | 3147 |
! |
3148 |
||
13419 | 3149 |
generate_make_dot_proto |
3150 |
||
3151 |
^ (self |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3152 |
replaceMappings: self make_dot_proto_mappings |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3153 |
in: self make_dot_proto) asStringCollection withTabs asString |
9536 | 3154 |
|
9733 | 3155 |
" |
12428 | 3156 |
stx_libbasic2 generate_make_dot_proto |
9733 | 3157 |
" |
9536 | 3158 |
|
3159 |
"Modified: / 09-08-2006 / 11:31:01 / fm" |
|
3160 |
! |
|
3161 |
||
3162 |
generate_make_dot_spec |
|
13419 | 3163 |
^ (self |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3164 |
replaceMappings: self make_dot_spec_mappings |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3165 |
in: self make_dot_spec) asStringCollection withTabs asString |
9536 | 3166 |
|
9733 | 3167 |
" |
3168 |
DapasXProject generate_make_dot_spec |
|
3169 |
DapasX_Datenbasis generate_make_dot_spec |
|
3170 |
bosch_dapasx_kernel_Definition generate_make_dot_spec |
|
3171 |
" |
|
9536 | 3172 |
|
3173 |
"Modified: / 09-08-2006 / 11:31:09 / fm" |
|
3174 |
! |
|
3175 |
||
13419 | 3176 |
generate_makefile |
3177 |
||
3178 |
^ (self |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3179 |
replaceMappings: self makefile_mappings |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3180 |
in: self makefile) asStringCollection withTabs asString |
12428 | 3181 |
|
3182 |
" |
|
3183 |
stx_libbasic2 generate_makefile |
|
3184 |
" |
|
3185 |
! |
|
3186 |
||
9536 | 3187 |
generate_packageName_dot_rc |
3188 |
||
13419 | 3189 |
^self replaceMappings: self packageName_dot_rc_mappings |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3190 |
in: self packageName_dot_rc |
9536 | 3191 |
|
3192 |
" |
|
3193 |
bosch_dapasx_datenbasis generate_packageName_dot_rc |
|
3194 |
bosch_dapasx_hw_schnittstellen generate_packageName_dot_rc |
|
9575 | 3195 |
stx_libbasic3 generate_packageName_dot_rc |
9618 | 3196 |
stx_libwidg3 generate_packageName_dot_rc |
13419 | 3197 |
stx_libwidg3 productVersion |
9536 | 3198 |
|
3199 |
" |
|
3200 |
||
3201 |
"Modified: / 09-08-2006 / 11:31:09 / fm" |
|
9618 | 3202 |
"Modified: / 21-08-2006 / 19:33:21 / cg" |
9831 | 3203 |
! |
3204 |
||
13411 | 3205 |
generate_package_dot_deps_dot_rake |
3206 |
^ (self replaceMappings:self package_dot_deps_dot_rake_mappings |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3207 |
in:self package_dot_deps_dot_rake) asStringCollection |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3208 |
withTabs asString |
13411 | 3209 |
|
3210 |
" |
|
3211 |
stx_libjava generate_dependencies_dot_rake" |
|
3212 |
||
3213 |
"Created: / 24-02-2011 / 22:32:10 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
3214 |
! |
|
3215 |
||
13419 | 3216 |
generate_vc_dot_def |
3217 |
||
3218 |
^self replaceMappings: self vc_dot_def_mappings |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3219 |
in: self vc_dot_def |
10306 | 3220 |
|
3221 |
" |
|
3222 |
DapasXProject generate_vc_dot_def |
|
3223 |
DapasX_Datenbasis generate_vc_dot_def |
|
3224 |
||
3225 |
" |
|
3226 |
||
3227 |
"Modified: / 09-08-2006 / 11:31:21 / fm" |
|
3228 |
! |
|
3229 |
||
13419 | 3230 |
generate_vcmake_dot_mak |
3231 |
||
3232 |
^self replaceMappings: self bmake_dot_mak_mappings |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3233 |
in: self vcmake_dot_mak |
11937 | 3234 |
! |
3235 |
||
9852 | 3236 |
protectedFileNames |
13178
07e3a9bb37c8
changed: #protectedFileNames
Claus Gittinger <cg@exept.de>
parents:
13177
diff
changeset
|
3237 |
"names of files which should NOT be generated (because they are hand-maintained) |
12200
7e452033e984
rememberOverwrittenExtensionMethods
Claus Gittinger <cg@exept.de>
parents:
12198
diff
changeset
|
3238 |
- redefine this to protect a hand-written Make.proto or other handwritten support files" |
9852 | 3239 |
|
3240 |
^ #() |
|
3241 |
||
3242 |
"Created: / 14-09-2006 / 14:38:40 / cg" |
|
13178
07e3a9bb37c8
changed: #protectedFileNames
Claus Gittinger <cg@exept.de>
parents:
13177
diff
changeset
|
3243 |
"Modified: / 21-12-2010 / 11:36:46 / cg" |
9852 | 3244 |
! |
3245 |
||
9831 | 3246 |
rcFilename |
3247 |
^ self packageName,'.rc'. |
|
3248 |
||
3249 |
"Created: / 07-09-2006 / 17:07:00 / cg" |
|
9536 | 3250 |
! ! |
3251 |
||
12364 | 3252 |
!ProjectDefinition class methodsFor:'file mappings'! |
9536 | 3253 |
|
13177 | 3254 |
autopackage_default_dot_apspec_mappings |
3255 |
|mappings| |
|
3256 |
||
3257 |
mappings := Dictionary new. |
|
3258 |
||
3259 |
mappings |
|
3260 |
"/ at: 'TOP' put: ( self pathToTop_unix ); |
|
3261 |
"/ at: 'NSI_FILENAME' put: self nsiFilename ; |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3262 |
at: 'DESCRIPTION' put: (self description); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3263 |
at: 'PRODUCT_VERSION' put: (self productVersion); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3264 |
at: 'PRODUCT_DATE' put: (self productDate); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3265 |
at: 'PRODUCT_PUBLISHER' put: (self productPublisher); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3266 |
at: 'PRODUCT_WEBSITE' put: (self productWebSite); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3267 |
at: 'PRODUCT_INSTALLDIR' put: (self productInstallDir); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3268 |
at: 'PRODUCT_TYPE' put: (self productType); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3269 |
at: 'PRODUCT_LICENSE' put: (self productLicense); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3270 |
at: 'PRODUCT_DESCRIPTION' put: (self productDescription); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3271 |
at: 'MAINTAINER' put: (self productMaintainer); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3272 |
at: 'PACKAGER' put: (self productPublisher); |
13177 | 3273 |
"/ at: 'STARTUP_CLASS' put: (self startupClassName); |
3274 |
"/ at: 'STARTUP_SELECTOR' put: (self startupSelector); |
|
3275 |
"/ at: 'MAIN_DEFINES' put: (self mainDefines); |
|
13419 | 3276 |
"/ at: 'REQUIRED_LIBS' put: (self generateRequiredLibs_make_dot_proto); |
3277 |
"/ at: 'PREREQUISITES_LIBS' put: (self generatePreRequisiteLines_make_dot_proto); |
|
3278 |
"/ at: 'SUBPROJECTS_LIBS' put: (self generateSubProjectLines_make_dot_proto); |
|
13177 | 3279 |
"/ at: 'REQUIRED_LIBOBJS' put: (self generateRequiredLibobjs_make_dot_proto); |
3280 |
"/ at: 'REQUIRED_LINK_LIBOBJS' put: (self generateRequiredLinkLibobjs_make_dot_proto); |
|
3281 |
"/ at: 'DEPENDENCIES' put: (self generateDependencies_unix); |
|
13419 | 3282 |
"/ at: 'SUBPROJECTS_LIBS' put: (self generateSubProjectLines_make_dot_proto ); |
13177 | 3283 |
"/ at: 'BUILD_TARGET' put: (self buildTarget ); |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3284 |
yourself. |
13419 | 3285 |
|
3286 |
"/ self offerSmalltalkSourceCode ifTrue:[ |
|
13177 | 3287 |
"/ mappings |
13419 | 3288 |
"/ at: 'STX_SOURCE_RULES' put: ( self replaceMappings: mappings |
13177 | 3289 |
"/ in: self make_dot_proto_stx_source_rules). |
3290 |
"/ ]. |
|
3291 |
||
13419 | 3292 |
"/ self offerApplicationSourceCode ifTrue:[ |
13177 | 3293 |
"/ mappings |
13419 | 3294 |
"/ at: 'SOURCE_RULES' put:( self replaceMappings: mappings |
13177 | 3295 |
"/ in: self make_dot_proto_app_source_rules ). |
3296 |
"/ ]. |
|
3297 |
||
3298 |
"/ self needResources ifTrue:[ |
|
3299 |
"/ mappings |
|
3300 |
"/ at: 'REQUIRED_SUPPORT_DIRS' put: 'RESOURCEFILES'; |
|
13419 | 3301 |
"/ at: 'RESOURCE_RULES' put:( self replaceMappings: mappings |
13177 | 3302 |
"/ in: self make_dot_proto_resource_rules ); |
13419 | 3303 |
"/ at: 'STX_RESOURCE_RULES' put: ( self replaceMappings: mappings |
13177 | 3304 |
"/ in: self make_dot_proto_stx_resource_rules); |
3305 |
"/ at: 'ADDITIONAL_RESOURCE_TARGETS' put:( self additionalResourceTargets asStringWith:' '); |
|
3306 |
"/ yourself. |
|
3307 |
"/ ]. |
|
3308 |
||
3309 |
^ mappings |
|
3310 |
||
3311 |
"Created: / 21-12-2010 / 09:00:49 / cg" |
|
3312 |
"Modified: / 21-12-2010 / 11:14:41 / cg" |
|
3313 |
! |
|
3314 |
||
10306 | 3315 |
bc_dot_mak_mappings |
3316 |
|d| |
|
3317 |
||
3318 |
d := Dictionary new. |
|
13419 | 3319 |
d |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3320 |
at: 'TAB' put: ( Character tab asString ); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3321 |
at: 'TOP' put: ( self pathToTop_win32 ); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3322 |
at: 'MODULE' put: ( self module ); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3323 |
at: 'MODULE_DIRECTORY' put: ( self moduleDirectory ); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3324 |
at: 'MODULE_PATH' put: ( self moduleDirectory_win32 ); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3325 |
at: 'PRIMARY_TARGET' put: (self primaryTarget_bc_dot_mak); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3326 |
at: 'ADDITIONAL_BASE_ADDRESS_DEFINITION' put: (self additionalBaseAddressDefinition_bc_dot_mak ? ''); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3327 |
at: 'ADDITIONAL_DEFINITIONS' put: (self additionalDefinitions_bc_dot_mak ? ''); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3328 |
at: 'ADDITIONAL_HEADERRULES' put: (self additionalHeaderRules_bc_dot_mak); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3329 |
at: 'ADDITIONAL_RULES' put: (self additionalRules_bc_dot_mak ? ''); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3330 |
at: 'ADDITIONAL_TARGETS' put: (self additionalTargets_bc_dot_mak ? ''); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3331 |
at: 'ADDITIONAL_LINK_LIBRARIES' put: (self additionalLinkLibraries_bc_dot_mak ? ''); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3332 |
at: 'LOCAL_INCLUDES' put: (self generateLocalIncludes_win32 ? ''); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3333 |
at: 'LOCAL_DEFINES' put: self localDefines_win32 ? ''; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3334 |
at: 'GLOBAL_DEFINES' put: self globalDefines_win32 ? ''; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3335 |
at: 'MAKE_PREREQUISITES' put: (self generateRequiredMakePrerequisites_bc_dot_mak ? ''). |
10306 | 3336 |
^ d |
3337 |
||
3338 |
"Created: / 18-08-2006 / 11:43:39 / cg" |
|
13687
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
3339 |
"Modified: / 12-09-2011 / 15:43:30 / cg" |
10306 | 3340 |
! |
3341 |
||
9627 | 3342 |
bmake_dot_mak_mappings |
3343 |
^ (Dictionary new) |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3344 |
at:'SUBPROJECT_BMAKE_CALLS' put:(self subProjectBmakeCalls); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3345 |
at:'SUBPROJECT_VCMAKE_CALLS' put:(self subProjectVCmakeCalls); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3346 |
at:'SUBPROJECT_LCMAKE_CALLS' put:(self subProjectLCmakeCalls); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3347 |
yourself |
9627 | 3348 |
|
3349 |
"Created: / 17-08-2006 / 21:41:56 / cg" |
|
9887 | 3350 |
"Modified: / 14-09-2006 / 18:55:33 / cg" |
9575 | 3351 |
! |
3352 |
||
13411 | 3353 |
builder_baseline_dot_rbspec_mappings |
3354 |
|mappings| |
|
3355 |
||
3356 |
mappings := Dictionary new. |
|
3357 |
mappings |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3358 |
at:'APPLICATION' put:(self perform:#applicationName ifNotUnderstood:[self packageName]); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3359 |
at:'APPLICATION_PACKAGE' put:self package printString; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3360 |
at:'PREAMBLE' put:self builder_baseline_dot_rbspec_preamble; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3361 |
at:'POSTAMBLE' put:self builder_baseline_dot_rbspec_postamble; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3362 |
at:'PACKAGES' put:self builder_baseline_dot_rbspec_packages; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3363 |
yourself. |
13411 | 3364 |
^ mappings |
3365 |
||
3366 |
"Modified: / 21-12-2010 / 11:00:22 / cg" |
|
3367 |
"Created: / 24-02-2011 / 11:58:06 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
3368 |
"Modified: / 09-06-2011 / 14:55:31 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
3369 |
! |
|
3370 |
||
3371 |
builder_baseline_dot_rbspec_packages |
|
3372 |
^ String streamContents: |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3373 |
[:s | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3374 |
self allPreRequisitesSorted do: |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3375 |
[:packageId | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3376 |
s |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3377 |
nextPutAll:(' package "%1"' bindWith:packageId); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3378 |
cr ] ]. |
13411 | 3379 |
|
3380 |
"Created: / 24-02-2011 / 11:59:32 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
3381 |
! |
|
3382 |
||
13419 | 3383 |
classLine_mappings:aClassName |
12545 | 3384 |
^ Dictionary new |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3385 |
at:'CLASS' put:(self st2c:aClassName); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3386 |
yourself |
9962
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3387 |
|
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3388 |
"Modified: / 09-08-2006 / 18:27:07 / fm" |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3389 |
"Created: / 19-09-2006 / 22:47:43 / cg" |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3390 |
! |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3391 |
|
10299
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
3392 |
make_dot_proto_mappings |
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
3393 |
^ Dictionary new |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3394 |
at: 'TAB' put: ( Character tab asString ); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3395 |
at: 'TOP' put: ( self pathToTop_unix ); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3396 |
at: 'LIBRARY_NAME' put: ( self libraryName ); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3397 |
at: 'SUBDIRECTORIES' put: (self generateSubDirectories); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3398 |
at: 'LOCAL_INCLUDES' put: (self generateLocalIncludes_unix); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3399 |
at: 'LOCAL_DEFINES' put: self localDefines_unix; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3400 |
at: 'GLOBAL_DEFINES' put: self globalDefines_unix; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3401 |
at: 'COMMONSYMFLAG' put: (self commonSymbolsFlag); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3402 |
at: 'HEADEROUTPUTARG' put: (self headerFileOutputArg); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3403 |
at: 'PRIMARY_TARGET' put: (self primaryTarget_make_dot_proto); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3404 |
at: 'ADDITIONAL_DEFINITIONS' put: (self additionalDefinitions_make_dot_proto); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3405 |
at: 'ADDITIONAL_HEADERRULES' put: (self additionalHeaderRules_make_dot_proto); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3406 |
at: 'ADDITIONAL_RULES' put: (self additionalRules_make_dot_proto); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3407 |
at: 'ADDITIONAL_RULES_SVN' put: (self additionalRulesSvn_make_dot_proto); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3408 |
at: 'ADDITIONAL_TARGETS' put: (self additionalTargets_make_dot_proto); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3409 |
at: 'ADDITIONAL_TARGETS_SVN' put: (self additionalTargetsSvn_make_dot_proto); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3410 |
at: 'ADDITIONAL_LINK_LIBRARIES' put: (self additionalLinkLibraries_make_dot_proto); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3411 |
at: 'ADDITIONAL_SHARED_LINK_LIBRARIES' put: (self additionalSharedLinkLibraries_make_dot_proto); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3412 |
at: 'DEPENDENCIES' put: (self generateDependencies_unix); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3413 |
at: 'MODULE' put: ( self module ); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3414 |
at: 'MODULE_DIRECTORY' put: ( self moduleDirectory ); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3415 |
at: 'MODULE_PATH' put: ( self moduleDirectory ); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3416 |
at: 'MAKE_PREREQUISITES' put: (self generateRequiredMakePrerequisites_make_dot_proto); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3417 |
yourself |
10299
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
3418 |
|
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
3419 |
"Created: / 09-08-2006 / 11:20:45 / fm" |
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
3420 |
"Modified: / 09-08-2006 / 16:44:48 / fm" |
12028 | 3421 |
"Modified: / 24-06-2009 / 21:50:13 / Jan Vrany <vranyj1@fel.cvut.cz>" |
3422 |
"Modified: / 22-08-2009 / 12:03:25 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
13687
1577ea868878
generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents:
13650
diff
changeset
|
3423 |
"Modified: / 12-09-2011 / 15:43:06 / cg" |
10299
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
3424 |
! |
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
3425 |
|
9627 | 3426 |
make_dot_spec_mappings |
3427 |
^ Dictionary new |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3428 |
at: 'TAB' put: ( Character tab asString ); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3429 |
at: 'MODULE' put: ( self module ); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3430 |
at: 'MODULE_DIRECTORY' put: ( self moduleDirectory ); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3431 |
at: 'STCWARNINGOPTIONS' put: (self stcWarningOptions); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3432 |
at: 'STCOPTIMIZATIONOPTIONS' put: (self stcOptimizationOptions); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3433 |
at: 'CLASSES' put: [self generateClasses_make_dot_spec]; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3434 |
at: 'OBJECTS' put: [self generateObjects_make_dot_spec]; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3435 |
yourself |
9627 | 3436 |
|
3437 |
"Created: / 18-08-2006 / 11:44:23 / cg" |
|
9887 | 3438 |
"Modified: / 14-09-2006 / 18:51:24 / cg" |
9575 | 3439 |
! |
3440 |
||
12428 | 3441 |
makefile_mappings |
3442 |
^ Dictionary new |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3443 |
yourself |
12428 | 3444 |
! |
3445 |
||
9627 | 3446 |
packageName_dot_rc_mappings |
11611
fa06cde6bd11
Allow for additional icon files to be placed in resources
Stefan Vogel <sv@exept.de>
parents:
11580
diff
changeset
|
3447 |
|d s resourceCount| |
9627 | 3448 |
|
9630 | 3449 |
d := Dictionary new. |
3450 |
d |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3451 |
at: 'PRODUCT_NAME' put: (self productName); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3452 |
at: 'PRODUCT_VERSION' put: (self productVersion); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3453 |
at: 'PRODUCT_DATE' put: (self productDate); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3454 |
at: 'FILETYPE' put: ( 'VFT_DLL' ); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3455 |
at: 'FILE_VERSION_COMMASEPARATED' put: (self fileVersionCommaSeparated); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3456 |
at: 'PRODUCT_VERSION_COMMASEPARATED' put: (self productVersionCommaSeparated); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3457 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3458 |
at: 'COMPANY_NAME' put: (self companyName); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3459 |
at: 'FILE_DESCRIPTION' put: (self fileDescription); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3460 |
at: 'FILE_VERSION' put: (self fileVersion); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3461 |
at: 'INTERNAL_NAME' put: (self internalName). |
11377 | 3462 |
|
9630 | 3463 |
s := self legalCopyright. |
3464 |
s notNil ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3465 |
d at: 'LEGAL_COPYRIGHT_LINE' put: ' VALUE "LegalCopyright", "',s,'\0"' |
9630 | 3466 |
]. |
11611
fa06cde6bd11
Allow for additional icon files to be placed in resources
Stefan Vogel <sv@exept.de>
parents:
11580
diff
changeset
|
3467 |
s := String streamContents:[:stream| |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3468 |
|suff| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3469 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3470 |
s := self applicationIconFileName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3471 |
s notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3472 |
s asFilename suffix isEmptyOrNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3473 |
suff := '.ico' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3474 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3475 |
suff := '' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3476 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3477 |
'IDR_MAINFRAME ICON DISCARDABLE "%1%2"' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3478 |
expandPlaceholdersWith:(Array with:s with:suff) on:stream. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3479 |
stream cr. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3480 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3481 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3482 |
s := self splashFileName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3483 |
s notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3484 |
s asFilename suffix isEmptyOrNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3485 |
suff := '.bmp' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3486 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3487 |
suff := '' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3488 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3489 |
'IDR_SPLASH BITMAP DISCARDABLE "%1%2"' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3490 |
expandPlaceholdersWith:(Array with:s with:suff) on:stream. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3491 |
stream cr. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3492 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3493 |
resourceCount := 2. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3494 |
self applicationAdditionalIconFileNames do:[:eachFilename| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3495 |
'IDR_MAINFRAME+%1 ICON DISCARDABLE "%2"' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3496 |
expandPlaceholdersWith:(Array with:resourceCount with:eachFilename) on:stream. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3497 |
stream cr. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3498 |
resourceCount := resourceCount+1. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3499 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3500 |
]. |
11611
fa06cde6bd11
Allow for additional icon files to be placed in resources
Stefan Vogel <sv@exept.de>
parents:
11580
diff
changeset
|
3501 |
d at: #'ICONDEFINITION_LINE' put:s. |
9817 | 3502 |
|
9630 | 3503 |
^ d |
9627 | 3504 |
|
3505 |
"Created: / 09-08-2006 / 11:21:21 / fm" |
|
13309
27f463f6c0cb
changed: #packageName_dot_rc_mappings
Claus Gittinger <cg@exept.de>
parents:
13285
diff
changeset
|
3506 |
"Modified: / 22-02-2011 / 11:30:36 / cg" |
9536 | 3507 |
! |
3508 |
||
13411 | 3509 |
package_dot_deps_dot_rake_mappings |
3510 |
| dependencies | |
|
3511 |
||
3512 |
dependencies := String streamContents: |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3513 |
[:s| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3514 |
self allPreRequisites do: |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3515 |
[:package| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3516 |
(self preRequisitesFor: package) do: |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3517 |
[:prereq| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3518 |
s nextPutAll: ('task "%1" => "%2"' bindWith: package with: prereq); cr]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3519 |
s cr]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3520 |
self effectivePreRequisites do: |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3521 |
[:prereq| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3522 |
s nextPutAll: ('task "%1" => "%2"' bindWith: self package with: prereq); cr]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3523 |
]. |
13411 | 3524 |
|
3525 |
^ (Dictionary new) |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3526 |
at:'DEPENDENCIES' put:dependencies; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3527 |
yourself |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3528 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3529 |
" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3530 |
stx_libjava generate_package_dot_deps_dot_rake |
13411 | 3531 |
" |
3532 |
||
3533 |
"Created: / 24-02-2011 / 22:32:08 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
3534 |
! |
|
3535 |
||
9627 | 3536 |
replaceMappings: mappings in: fileTemplate |
9733 | 3537 |
"Replaces the defined variable mappings found in a file template with the corresponding information" |
9627 | 3538 |
|
9733 | 3539 |
^ fileTemplate bindWithArguments:mappings. |
9627 | 3540 |
|
9733 | 3541 |
" |
13419 | 3542 |
self replaceMappings: (self nt_dot_def_mappingsFor: self) in: self nt_dot_def |
9733 | 3543 |
" |
9627 | 3544 |
|
3545 |
"Created: / 08-08-2006 / 11:44:27 / fm" |
|
3546 |
"Modified: / 08-08-2006 / 12:46:13 / fm" |
|
9962
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3547 |
! |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3548 |
|
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3549 |
st2c:aString |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3550 |
^ (aString asString |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3551 |
copyReplaceString:'_' withString:('_',($_ codePoint printStringRadix:8))) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3552 |
replaceAny:':' with:$_ |
9536 | 3553 |
! ! |
3554 |
||
12364 | 3555 |
!ProjectDefinition class methodsFor:'file mappings support'! |
9817 | 3556 |
|
12545 | 3557 |
classNamesByCategory |
3558 |
"answer a dictionary |
|
13728 | 3559 |
category -> classNames topological sorted" |
12545 | 3560 |
|
3561 |
|pivateClassesOf sorter classes classNames mapping| |
|
3562 |
||
3563 |
mapping := Dictionary new. |
|
3564 |
||
3565 |
classes := self compiled_classes_common. |
|
3566 |
pivateClassesOf := IdentityDictionary new. |
|
3567 |
classes do:[:each | pivateClassesOf at:each put:(each allPrivateClasses)]. |
|
3568 |
||
3569 |
sorter := [:a :b | |
|
13728 | 3570 |
"/ a must come before b iff: |
3571 |
"/ b is a subclass of a |
|
3572 |
"/ b has a private class which is a subclass of a |
|
3573 |
"/ a is a sharedPool, used by b |
|
3574 |
||
3575 |
|mustComeBefore pivateClassesOfB| |
|
3576 |
||
3577 |
mustComeBefore := false. |
|
3578 |
mustComeBefore := (a isSharedPool and:[(b sharedPoolNames includes: a name)]). |
|
3579 |
mustComeBefore := mustComeBefore or:[b isSubclassOf:a]. |
|
3580 |
mustComeBefore ifFalse:[ |
|
3581 |
pivateClassesOfB := pivateClassesOf at:b ifAbsent:[ #() ]. |
|
3582 |
pivateClassesOfB do:[:eachClassInB | |
|
3583 |
mustComeBefore := mustComeBefore or:[eachClassInB isSubclassOf:a] |
|
3584 |
]. |
|
3585 |
]. |
|
3586 |
mustComeBefore |
|
12545 | 3587 |
]. |
3588 |
||
3589 |
classes topologicalSort:sorter. |
|
3590 |
||
3591 |
OperatingSystem knownPlatformNames do:[:platformID | |
|
13728 | 3592 |
|prefix depClasses depClassNames| |
3593 |
||
3594 |
prefix := platformID asUppercase. |
|
3595 |
depClasses := self compiled_classesForArchitecture:platformID. |
|
3596 |
depClasses notEmpty ifTrue:[ |
|
3597 |
(self compiled_classNamesForPlatform:platformID) |
|
3598 |
select:[:nm | (Smalltalk at:nm ifAbsent:nil) isNil] |
|
3599 |
thenDo:[:nm | Transcript showCR:nm]. |
|
3600 |
(depClasses includes:nil) ifTrue:[ |
|
13836
97abd31bbd13
changed: #classNamesByCategory
Claus Gittinger <cg@exept.de>
parents:
13823
diff
changeset
|
3601 |
(Dialog confirm:'Dependencies (and therefore build-order) might be incorrect\(some classes are not present; see Transcript).\\Continue anyway ?' withCRs) |
13728 | 3602 |
ifFalse:[ |
3603 |
AbortOperationRequest raise. |
|
3604 |
]. |
|
3605 |
depClassNames := self compiled_classNamesForPlatform:platformID. |
|
3606 |
] ifFalse:[ |
|
3607 |
depClasses topologicalSort:sorter. |
|
3608 |
depClassNames := depClasses collect:[:eachClass| eachClass name]. |
|
3609 |
]. |
|
3610 |
mapping at:prefix put:depClassNames. |
|
3611 |
]. |
|
3612 |
||
3613 |
classNames := classes collect:[:eachClass| eachClass name]. |
|
3614 |
self namesAndAttributesIn:(self additionalClassNamesAndAttributes) do: [:nm :attr | |
|
3615 |
(attr isEmptyOrNil or:[(attr includes:#autoload) not]) ifTrue:[ |
|
3616 |
classNames add:nm. |
|
3617 |
]. |
|
3618 |
]. |
|
3619 |
||
3620 |
mapping at:'COMMON' put:classNames. |
|
12545 | 3621 |
]. |
3622 |
^ mapping |
|
3623 |
||
3624 |
" |
|
3625 |
stx_libbasic classNamesByCategory |
|
3626 |
stx_libbasic3 classNamesByCategory |
|
3627 |
stx_libview classNamesByCategory |
|
3628 |
" |
|
3629 |
||
3630 |
"Created: / 09-08-2006 / 11:24:39 / fm" |
|
13836
97abd31bbd13
changed: #classNamesByCategory
Claus Gittinger <cg@exept.de>
parents:
13823
diff
changeset
|
3631 |
"Modified: / 25-11-2011 / 16:41:47 / cg" |
12545 | 3632 |
! |
3633 |
||
10299
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
3634 |
commonSymbolsFlag |
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
3635 |
"only for libraries" |
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
3636 |
|
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
3637 |
^ '' |
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
3638 |
! |
af27a10749c2
add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents:
10296
diff
changeset
|
3639 |
|
11868
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3640 |
filenameForClass:classNameOrClass |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3641 |
"answer the base filename of the class without suffix" |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3642 |
|
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3643 |
"/ "enable this code if you want to convert old filenames to new filenames. |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3644 |
"/ See also: #generateRemoveShellScriptOn: and #generateRenamShellScriptOn:" |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3645 |
"/ classNameOrClass isBehavior ifTrue:[ |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3646 |
"/ ^ classNameOrClass generateClassFilename. |
13419 | 3647 |
"/ ] ifFalse:[ |
11868
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3648 |
"/ |cls| |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3649 |
"/ |
13419 | 3650 |
"/ cls := Smalltalk classNamed:classNameOrClass. |
11868
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3651 |
"/ cls notNil ifTrue:[ |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3652 |
"/ ^ cls generateClassFilename. |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3653 |
"/ ]. |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3654 |
"/ ]. |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3655 |
"/ "end special code" |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3656 |
|
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3657 |
^ Smalltalk fileNameForClass:classNameOrClass. |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3658 |
|
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3659 |
" |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3660 |
self filenameForClass:HTML::Encoder |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3661 |
Smalltalk fileNameForClass:HTML::Encoder |
11868
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3662 |
" |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3663 |
|
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3664 |
"Created: / 08-08-2006 / 20:17:28 / fm" |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3665 |
"Modified: / 20-10-2006 / 16:22:58 / cg" |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3666 |
! |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
3667 |
|
13419 | 3668 |
generateClassLines:classLineTemplate |
12771
878fc210c8e7
add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents:
12749
diff
changeset
|
3669 |
"for the init-file: generate class-init-lines for all classes" |
878fc210c8e7
add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents:
12749
diff
changeset
|
3670 |
|
878fc210c8e7
add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents:
12749
diff
changeset
|
3671 |
^ self generateClassLines:classLineTemplate forClasses:(self compiled_classNames_common) |
878fc210c8e7
add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents:
12749
diff
changeset
|
3672 |
! |
878fc210c8e7
add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents:
12749
diff
changeset
|
3673 |
|
878fc210c8e7
add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents:
12749
diff
changeset
|
3674 |
generateClassLines:classLineTemplate forClasses:classNames |
878fc210c8e7
add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents:
12749
diff
changeset
|
3675 |
"for the init-file: generate class-init-lines for a collection of classes" |
878fc210c8e7
add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents:
12749
diff
changeset
|
3676 |
|
13419 | 3677 |
^ self generateClassLines:classLineTemplate forClasses:classNames includeAdditionalClasses:true |
12804
079b692e0776
added: #generateClassLines:forClasses:includeAdditionalClasses:
sr
parents:
12771
diff
changeset
|
3678 |
! |
079b692e0776
added: #generateClassLines:forClasses:includeAdditionalClasses:
sr
parents:
12771
diff
changeset
|
3679 |
|
079b692e0776
added: #generateClassLines:forClasses:includeAdditionalClasses:
sr
parents:
12771
diff
changeset
|
3680 |
generateClassLines:classLineTemplate forClasses:classNames includeAdditionalClasses:includeAdditionalClasses |
079b692e0776
added: #generateClassLines:forClasses:includeAdditionalClasses:
sr
parents:
12771
diff
changeset
|
3681 |
"for the init-file: generate class-init-lines for a collection of classes" |
079b692e0776
added: #generateClassLines:forClasses:includeAdditionalClasses:
sr
parents:
12771
diff
changeset
|
3682 |
|
13419 | 3683 |
^ String |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3684 |
streamContents:[:s | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3685 |
|classesLoaded classNamesUnloaded classNamesSorted putLineForClassName| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3686 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3687 |
putLineForClassName := [:className | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3688 |
|newClassLine mappings| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3689 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3690 |
mappings := self classLine_mappings:className. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3691 |
newClassLine := self replaceMappings:mappings in:classLineTemplate. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3692 |
s nextPutLine:newClassLine |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3693 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3694 |
classesLoaded := classNames collect:[:eachClassName | Smalltalk classNamed:eachClassName] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3695 |
thenSelect:[:eachClass | eachClass notNil and:[eachClass isLoaded]]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3696 |
classNamesUnloaded := classNames |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3697 |
select:[:nm | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3698 |
|cls| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3699 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3700 |
cls := Smalltalk classNamed:nm. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3701 |
cls isNil or:[ cls isLoaded not ] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3702 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3703 |
classNamesSorted := (Class classesSortedByLoadOrder:classesLoaded) collect:[:cls | cls name]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3704 |
classNamesSorted do:putLineForClassName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3705 |
classNamesUnloaded do:putLineForClassName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3706 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3707 |
includeAdditionalClasses ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3708 |
self namesAndAttributesIn:(self additionalClassNamesAndAttributes) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3709 |
do:[:nm :attr | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3710 |
(attr isEmptyOrNil or:[ (attr includes:#autoload) not ]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3711 |
putLineForClassName value:nm. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3712 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3713 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3714 |
#( ('UNIX' unix) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3715 |
('WIN32' win32) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3716 |
('VMS' vms) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3717 |
('BEOS' beos) ) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3718 |
pairsDo:[:ifdef :platformName | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3719 |
|archClassNames archClassesLoaded| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3720 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3721 |
archClassNames := self compiled_classNamesForPlatform:platformName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3722 |
archClassNames notEmpty ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3723 |
s nextPutLine:'#ifdef ' , ifdef. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3724 |
archClassNames do:[:clsName | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3725 |
putLineForClassName value:clsName |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3726 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3727 |
s nextPutLine:'#endif /* ' , ifdef , ' */'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3728 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3729 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3730 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3731 |
] |
9962
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3732 |
|
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3733 |
" |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3734 |
bosch_dapasx_datenbasis generateClassLines_libInit_dot_cc |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3735 |
bosch_dapasx_kernel generateClassLines_libInit_dot_cc |
10010 | 3736 |
stx_libbasic3 generateClassLines_libInit_dot_cc |
3737 |
" |
|
3738 |
||
9962
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3739 |
"Modified: / 16-08-2006 / 18:52:10 / User" |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3740 |
"Created: / 19-09-2006 / 22:47:50 / cg" |
9979
e2e247d73233
oops - libInit forgot non-loaded, alien-OS files.
Claus Gittinger <cg@exept.de>
parents:
9972
diff
changeset
|
3741 |
"Modified: / 20-09-2006 / 11:47:25 / cg" |
9962
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3742 |
! |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3743 |
|
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3744 |
generateClassLines_libInit_dot_cc |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3745 |
^ self generateClassLines:(self classLine_libInit_dot_cc) |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3746 |
|
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3747 |
" |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3748 |
bosch_dapasx_datenbasis generateClassLines_libInit_dot_cc |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3749 |
bosch_dapasx_kernel generateClassLines_libInit_dot_cc |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3750 |
stx_libbasic3 generateClassLines_libInit_dot_cc |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3751 |
" |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3752 |
|
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3753 |
"Created: / 09-08-2006 / 11:21:48 / fm" |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3754 |
"Modified: / 16-08-2006 / 18:52:10 / User" |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3755 |
"Modified: / 19-09-2006 / 22:48:14 / cg" |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3756 |
! |
905898cca08c
also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents:
9956
diff
changeset
|
3757 |
|
13419 | 3758 |
generateClasses_make_dot_spec |
12545 | 3759 |
|classNamesDict| |
3760 |
||
3761 |
classNamesDict := self classNamesByCategory. |
|
3762 |
||
3763 |
^ String streamContents:[:s | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3764 |
classNamesDict keysAndValuesDo:[:eachCategory :classNames| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3765 |
s nextPutLine:eachCategory,'_CLASSES= \'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3766 |
classNames do:[:eachClassName| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3767 |
s tab; nextPutAll:eachClassName; nextPutLine:' \'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3768 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3769 |
s cr. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3770 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3771 |
s cr. |
12545 | 3772 |
]. |
3773 |
||
3774 |
" |
|
3775 |
stx_libbasic generateClasses_make_dot_spec |
|
3776 |
stx_libbasic3 generateClasses_make_dot_spec |
|
3777 |
stx_libview generateClasses_make_dot_spec |
|
3778 |
stx_libboss generateClasses_make_dot_spec |
|
3779 |
" |
|
3780 |
||
3781 |
"Created: / 09-08-2006 / 11:24:39 / fm" |
|
3782 |
"Modified: / 20-10-2006 / 16:18:54 / cg" |
|
3783 |
! |
|
3784 |
||
13419 | 3785 |
generateDependencies:whichArchitecture |
3786 |
^ String |
|
13763
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3787 |
streamContents:[:s | |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3788 |
|classNames classesPresent classesLoaded clsBaseName putDependencyForClassBlock |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3789 |
putDependencyForClassBaseNameBlock |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3790 |
archClassNames archClassesPresent archClassesLoaded |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3791 |
putSingleClassDependencyEntryBlock putDependencyForExtensionsBlock| |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3792 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3793 |
putSingleClassDependencyEntryBlock := [:cls | |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3794 |
|sclsBaseName| |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3795 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3796 |
s nextPutAll:' $(INCLUDE_TOP)'. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3797 |
s nextPutAll:(self pathSeparator:whichArchitecture) asString. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3798 |
sclsBaseName := self filenameForClass:cls. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3799 |
s nextPutAll:(self |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3800 |
topRelativePathTo:sclsBaseName |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3801 |
inPackage:cls package |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3802 |
architecture:whichArchitecture). |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3803 |
s nextPutAll:'.$(H)'. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3804 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3805 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3806 |
putDependencyForClassBaseNameBlock := [:clsBaseName | |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3807 |
s nextPutAll:'$(OUTDIR)'. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3808 |
s nextPutAll:clsBaseName. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3809 |
s nextPutAll:'.$(O)'. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3810 |
s nextPutAll:' '. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3811 |
s nextPutAll:clsBaseName. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3812 |
s nextPutAll:'.$(H)'. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3813 |
s nextPutAll:': '. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3814 |
s nextPutAll:clsBaseName. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3815 |
s nextPutAll:'.st'. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3816 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3817 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3818 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3819 |
putDependencyForClassBlock := [:cls | |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3820 |
|clsBaseName already| |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3821 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3822 |
clsBaseName := self filenameForClass:cls. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3823 |
putDependencyForClassBaseNameBlock value:clsBaseName. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3824 |
cls isLoaded ifTrue:[ |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3825 |
already := IdentitySet new. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3826 |
cls |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3827 |
sharedPools do:[:poolClass | |
13798
894c48237cd5
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13797
diff
changeset
|
3828 |
poolClass isNil ifTrue:[ |
894c48237cd5
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13797
diff
changeset
|
3829 |
Dialog warn:'At least one pool class is missing.\\Dependencies are incomplete.' withCRs |
894c48237cd5
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13797
diff
changeset
|
3830 |
] ifFalse:[ |
894c48237cd5
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13797
diff
changeset
|
3831 |
putSingleClassDependencyEntryBlock value:poolClass. |
894c48237cd5
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13797
diff
changeset
|
3832 |
already add:poolClass. |
894c48237cd5
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13797
diff
changeset
|
3833 |
] |
13763
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3834 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3835 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3836 |
cls |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3837 |
allSuperclassesDo:[:scls | |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3838 |
putSingleClassDependencyEntryBlock value:scls. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3839 |
already add:scls. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3840 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3841 |
cls |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3842 |
allPrivateClassesDo:[:eachPrivateClass | |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3843 |
eachPrivateClass |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3844 |
allSuperclassesDo:[:scls | |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3845 |
|sclsBaseName| |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3846 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3847 |
scls ~~ cls ifTrue:[ |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3848 |
scls isPrivate ifFalse:[ |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3849 |
(already includes:scls) ifFalse:[ |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3850 |
putSingleClassDependencyEntryBlock value:scls. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3851 |
already add:scls. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3852 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3853 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3854 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3855 |
] |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3856 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3857 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3858 |
s nextPutLine:' $(STCHDR)'. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3859 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3860 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3861 |
putDependencyForExtensionsBlock := [ |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3862 |
|already| |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3863 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3864 |
s nextPutAll:'$(OUTDIR)extensions.$(O): extensions.st'. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3865 |
already := Set new. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3866 |
self extensionMethodNames pairWiseDo:[:className :selector | |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3867 |
|mthdCls cls| |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3868 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3869 |
((mthdCls := Smalltalk classNamed:className) notNil |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3870 |
and:[ mthdCls isLoaded ]) |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3871 |
ifTrue:[ |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3872 |
cls := mthdCls theNonMetaclass. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3873 |
(already includes:cls) ifFalse:[ |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3874 |
cls |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3875 |
withAllSuperclassesDo:[:scls | |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3876 |
(already includes:scls) ifFalse:[ |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3877 |
putSingleClassDependencyEntryBlock value:scls. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3878 |
already add:scls. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3879 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3880 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3881 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3882 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3883 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3884 |
s nextPutLine:' $(STCHDR)'. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3885 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3886 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3887 |
classNames := self compiled_classNames_common. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3888 |
classesPresent := classNames |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3889 |
collect:[:className | Smalltalk classNamed:className] |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3890 |
thenSelect:[:cls | cls notNil]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3891 |
classesLoaded := classesPresent |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3892 |
select:[:cls | cls isLoaded]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3893 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3894 |
(Class classesSortedByLoadOrder:classesLoaded) |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3895 |
do:putDependencyForClassBlock. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3896 |
(classesPresent select:[:cls | cls isLoaded not]) |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3897 |
do:putDependencyForClassBlock. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3898 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3899 |
self namesAndAttributesIn:(self additionalClassNamesAndAttributes) |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3900 |
do:[:className :attr | |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3901 |
|cls| |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3902 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3903 |
(attr isEmptyOrNil or:[ (attr includes:#autoload) not ]) ifTrue:[ |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3904 |
((cls := Smalltalk classNamed:className) notNil) ifTrue:[ |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3905 |
putDependencyForClassBlock value:cls. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3906 |
] |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3907 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3908 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3909 |
archClassNames := self compiled_classNamesForPlatform:whichArchitecture. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3910 |
archClassesPresent := archClassNames |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3911 |
collect:[:className | Smalltalk classNamed:className] |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3912 |
thenSelect:[:cls | cls notNil]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3913 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3914 |
archClassesLoaded := archClassesPresent |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3915 |
select:[:cls | cls isLoaded]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3916 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3917 |
(Class classesSortedByLoadOrder:archClassesLoaded) |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3918 |
do:putDependencyForClassBlock. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3919 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3920 |
"some classes are not loaded - probably this is the wrong architecture. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3921 |
Sorry, but for these classes, we do not know the superclass chain" |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3922 |
archClassesPresent |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3923 |
select:[:cls | cls isLoaded not] |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3924 |
thenDo:putDependencyForClassBlock. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3925 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3926 |
"for the following classes, we do not know the superclass chain |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3927 |
and neither the real class file name" |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3928 |
archClassNames |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3929 |
select:[:eachClassName | (Smalltalk classNamed:eachClassName) isNil] |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3930 |
thenDo:[:eachClassName | |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3931 |
putDependencyForClassBaseNameBlock value:(self filenameForClass:eachClassName). |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3932 |
s nextPutLine:' $(STCHDR)'. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3933 |
]. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3934 |
|
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3935 |
self hasExtensionMethods ifTrue:putDependencyForExtensionsBlock. |
560aef322c65
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13734
diff
changeset
|
3936 |
] |
9887 | 3937 |
|
3938 |
" |
|
3939 |
stx_libbasic3 generateDependencies:#unix |
|
10010 | 3940 |
stx_libbasic3 generateDependencies:#win32 |
3941 |
" |
|
3942 |
||
9887 | 3943 |
"Created: / 14-09-2006 / 12:38:57 / cg" |
13798
894c48237cd5
changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents:
13797
diff
changeset
|
3944 |
"Modified: / 27-10-2011 / 16:35:59 / cg" |
9887 | 3945 |
! |
3946 |
||
3947 |
generateDependencies_unix |
|
3948 |
^ self generateDependencies:#unix |
|
3949 |
||
3950 |
" |
|
3951 |
stx_libbasic3 generateDependencies:#unix |
|
3952 |
stx_libbasic3 generateDependencies:#win32 |
|
3953 |
" |
|
3954 |
||
3955 |
"Modified: / 14-09-2006 / 13:32:34 / cg" |
|
3956 |
! |
|
3957 |
||
3958 |
generateDependencies_win32 |
|
3959 |
^ self generateDependencies:#win32 |
|
3960 |
||
3961 |
"Created: / 14-09-2006 / 12:39:18 / cg" |
|
3962 |
! |
|
3963 |
||
9956 | 3964 |
generateLocalIncludes_unix |
3965 |
^ String streamContents:[:s | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3966 |
s nextPutAll:(self localIncludes_unix). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3967 |
self searchForProjectsWhichProvideHeaderFiles |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3968 |
do:[:includeProject | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3969 |
s nextPutAll:' -I$(INCLUDE_TOP)/',(self topRelativePathToPackage_unix: includeProject) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3970 |
] |
9956 | 3971 |
] |
3972 |
||
3973 |
" |
|
3974 |
bosch_dapasx generateLocalIncludes_unix |
|
13419 | 3975 |
bosch_dapasx_datenbasis generateLocalIncludes_unix |
3976 |
stx_libbasic generateLocalIncludes_unix |
|
3977 |
stx_libview generateLocalIncludes_unix |
|
3978 |
stx_libtool2 generateLocalIncludes_unix |
|
3979 |
stx_libui generateLocalIncludes_unix |
|
9956 | 3980 |
" |
3981 |
||
3982 |
"Created: / 09-08-2006 / 16:46:49 / fm" |
|
10251 | 3983 |
"Modified: / 07-12-2006 / 17:47:06 / cg" |
9956 | 3984 |
! |
3985 |
||
9887 | 3986 |
generateLocalIncludes_win32 |
3987 |
^ String streamContents:[:s | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3988 |
s nextPutAll:(self localIncludes_win32). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3989 |
self searchForProjectsWhichProvideHeaderFiles |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3990 |
do:[:includeProject | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3991 |
s nextPutAll:' -I$(INCLUDE_TOP)\',(self topRelativePathToPackage_win32: includeProject) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
3992 |
] |
9887 | 3993 |
] |
3994 |
||
3995 |
" |
|
3996 |
bosch_dapasx_application generateLocalIncludes_win32 |
|
13419 | 3997 |
bosch_dapasx_datenbasis generateLocalIncludes_win32 |
3998 |
stx_libbasic generateLocalIncludes_win32 |
|
3999 |
stx_libview generateLocalIncludes_win32 |
|
4000 |
stx_libtool2 generateLocalIncludes_win32 |
|
9887 | 4001 |
" |
4002 |
||
4003 |
"Created: / 09-08-2006 / 16:46:49 / fm" |
|
10251 | 4004 |
"Modified: / 07-12-2006 / 17:47:10 / cg" |
9887 | 4005 |
! |
4006 |
||
13419 | 4007 |
generateObjects_make_dot_spec |
12545 | 4008 |
|classNamesDict| |
4009 |
||
4010 |
classNamesDict := self classNamesByCategory. |
|
9883
c641767d1483
include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents:
9880
diff
changeset
|
4011 |
|
9817 | 4012 |
^ String streamContents:[:s | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4013 |
|putLineForClassName| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4014 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4015 |
putLineForClassName := |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4016 |
[:eachClassName | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4017 |
|mappings newObjectLine| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4018 |
mappings := self objectLine_make_dot_spec_mappings: eachClassName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4019 |
newObjectLine := self replaceMappings: mappings in: self objectLine_make_dot_spec. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4020 |
s nextPutLine:newObjectLine. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4021 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4022 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4023 |
classNamesDict keysAndValuesDo:[:eachCategory :classNames| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4024 |
s nextPutLine:eachCategory,'_OBJS= \'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4025 |
classNames do:putLineForClassName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4026 |
(eachCategory = 'COMMON' and:[self hasExtensionMethods]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4027 |
s nextPutLine:' $(OUTDIR)extensions.$(O) \'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4028 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4029 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4030 |
s cr. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4031 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4032 |
s cr. |
12545 | 4033 |
]. |
9817 | 4034 |
|
4035 |
" |
|
12545 | 4036 |
stx_libbasic generateObjects_make_dot_spec |
9817 | 4037 |
stx_libbasic3 generateObjects_make_dot_spec |
12545 | 4038 |
stx_libview generateObjects_make_dot_spec |
4039 |
stx_libboss generateObjects_make_dot_spec |
|
9817 | 4040 |
" |
4041 |
||
4042 |
"Created: / 09-08-2006 / 11:24:39 / fm" |
|
10103
f63f419f9e27
some care for incomplete information bein present when
Claus Gittinger <cg@exept.de>
parents:
10086
diff
changeset
|
4043 |
"Modified: / 20-10-2006 / 16:18:54 / cg" |
9887 | 4044 |
! |
4045 |
||
11157
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4046 |
generateRequiredMakePrerequisites_bc_dot_mak |
11380
ac50ce4321b5
Fix prerequisite makes (pushd)
Stefan Vogel <sv@exept.de>
parents:
11377
diff
changeset
|
4047 |
|myProjectId| |
11157
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4048 |
|
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4049 |
^ String streamContents:[:s | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4050 |
myProjectId := self package. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4051 |
"Note: the trailing blank in 'CFLAGS_LOCAL=$(GLOBALDEFINES) ' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4052 |
is required!! |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4053 |
Use 'pushd' instead of 'cd', since cd is executed by borland make directly. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4054 |
'popd' is not needed, since each line is executed in |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4055 |
an own cmd.exe process. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4056 |
'popd' is not desireable, since it masks a possible |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4057 |
error return from the 'bmake'. |
11380
ac50ce4321b5
Fix prerequisite makes (pushd)
Stefan Vogel <sv@exept.de>
parents:
11377
diff
changeset
|
4058 |
" |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4059 |
(self allPreRequisitesSorted copyWith:'stx:librun') do:[:eachProjectId | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4060 |
s tab; nextPutAll:'pushd '; |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4061 |
nextPutAll:(self msdosPathToPackage:eachProjectId from:myProjectId); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4062 |
nextPutLine:' & $(MAKE_BAT) "CFLAGS_LOCAL=$(GLOBALDEFINES) "'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4063 |
]. |
11157
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4064 |
]. |
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4065 |
|
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4066 |
" |
13419 | 4067 |
exept_expecco_application generateRequiredMakePrerequisites_bc_dot_mak |
4068 |
alspa_batch_application generateRequiredMakePrerequisites_bc_dot_mak |
|
11157
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4069 |
" |
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4070 |
! |
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4071 |
|
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4072 |
generateRequiredMakePrerequisites_make_dot_proto |
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4073 |
|libPath| |
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4074 |
|
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4075 |
^ String streamContents:[:s | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4076 |
(self allPreRequisitesSorted copyWith:'stx:librun') do:[:projectID | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4077 |
libPath := self pathToPackage_unix:projectID. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4078 |
s tab; nextPutAll: 'cd ', libPath; nextPutLine:' && $(MAKE) "CFLAGS_LOCAL=$(GLOBALDEFINES)"'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4079 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4080 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4081 |
s cr. |
11157
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4082 |
]. |
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4083 |
|
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4084 |
" |
13419 | 4085 |
exept_expecco_application generateRequiredMakePrerequisites_make_dot_proto |
4086 |
alspa_batch_application generateRequiredMakePrerequisites_make_dot_proto |
|
11157
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4087 |
" |
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4088 |
! |
5bef68f784c7
prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents:
11152
diff
changeset
|
4089 |
|
10022 | 4090 |
generateSubDirectories |
4091 |
^ String streamContents:[:s | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4092 |
self subProjects |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4093 |
do:[:eachProjectID | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4094 |
s space; nextPutAll:(self unixPathToPackage:eachProjectID from:self package) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4095 |
] |
10022 | 4096 |
] |
4097 |
||
4098 |
" |
|
10380
ff1cfee6130b
Fix subproject incluseion in Make.proto
Stefan Vogel <sv@exept.de>
parents:
10369
diff
changeset
|
4099 |
exept_expecco generateSubDirectories |
10022 | 4100 |
" |
4101 |
||
4102 |
"Created: / 09-08-2006 / 11:26:59 / fm" |
|
4103 |
"Modified: / 14-09-2006 / 18:46:18 / cg" |
|
4104 |
! |
|
4105 |
||
12771
878fc210c8e7
add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents:
12749
diff
changeset
|
4106 |
generate_definitionClassLine_libInit_dot_cc |
878fc210c8e7
add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents:
12749
diff
changeset
|
4107 |
"for the init-file: generate a single class-init-line for the definition class itself" |
878fc210c8e7
add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents:
12749
diff
changeset
|
4108 |
|
13419 | 4109 |
^ self |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4110 |
generateClassLines:(self classLine_libInit_dot_cc) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4111 |
forClasses:(Array with:self name) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4112 |
includeAdditionalClasses:false |
12804
079b692e0776
added: #generateClassLines:forClasses:includeAdditionalClasses:
sr
parents:
12771
diff
changeset
|
4113 |
|
079b692e0776
added: #generateClassLines:forClasses:includeAdditionalClasses:
sr
parents:
12771
diff
changeset
|
4114 |
" |
079b692e0776
added: #generateClassLines:forClasses:includeAdditionalClasses:
sr
parents:
12771
diff
changeset
|
4115 |
stx_libbasic generate_definitionClassLine_libInit_dot_cc |
12771
878fc210c8e7
add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents:
12749
diff
changeset
|
4116 |
" |
878fc210c8e7
add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents:
12749
diff
changeset
|
4117 |
! |
878fc210c8e7
add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents:
12749
diff
changeset
|
4118 |
|
10022 | 4119 |
headerFileOutputArg |
4120 |
"/ "all stx stuff goes to the common include directory. |
|
4121 |
"/ Everything else is left locally" |
|
4122 |
"/ |
|
4123 |
"/ ( |
|
4124 |
"/ #( |
|
13419 | 4125 |
"/ 'stx:libbasic' 'stx:libview' 'stx:libtool' |
10022 | 4126 |
"/ 'stx:libbasic2' 'stx:libview2' 'stx:libtool2' |
4127 |
"/ 'stx:libbasic3' 'stx:libwidg' 'stx:libhtml' |
|
4128 |
"/ 'stx:libcomp' 'stx:libwidg2' 'stx:libui' |
|
4129 |
"/ 'stx:libboss' 'stx:libdb' |
|
4130 |
"/ ) |
|
4131 |
"/ includes:self package) ifTrue:[ |
|
4132 |
"/ ^ '-H$(INCLUDE)' |
|
4133 |
"/ ]. |
|
13875
2e01d09fa4c4
-headerDir= instead of --headerDir=
Claus Gittinger <cg@exept.de>
parents:
13873
diff
changeset
|
4134 |
^ '-headerDir=.' |
10022 | 4135 |
|
4136 |
"Created: / 18-08-2006 / 13:01:52 / cg" |
|
13875
2e01d09fa4c4
-headerDir= instead of --headerDir=
Claus Gittinger <cg@exept.de>
parents:
13873
diff
changeset
|
4137 |
"Modified: / 23-12-2011 / 15:07:27 / cg" |
10022 | 4138 |
! |
4139 |
||
11868
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4140 |
objectLine_make_dot_spec_mappings: aClassName |
13419 | 4141 |
^ Dictionary new |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4142 |
at: 'CLASSFILE' put:(self filenameForClass:aClassName); |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4143 |
yourself |
11868
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4144 |
|
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4145 |
"Created: / 08-08-2006 / 20:17:28 / fm" |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4146 |
"Modified: / 09-08-2006 / 18:26:52 / fm" |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4147 |
"Modified: / 20-10-2006 / 16:22:58 / cg" |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4148 |
! |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4149 |
|
9887 | 4150 |
subProjectBmakeCalls |
12439 | 4151 |
"generate submake-calls for borland bcc" |
4152 |
||
13419 | 4153 |
^ self subProjectMakeCallsUsing:'call bmake %1 %2'. |
12438
26bbeae51816
added: #subProjectMakeCallsUsing:
Claus Gittinger <cg@exept.de>
parents:
12428
diff
changeset
|
4154 |
! |
26bbeae51816
added: #subProjectMakeCallsUsing:
Claus Gittinger <cg@exept.de>
parents:
12428
diff
changeset
|
4155 |
|
26bbeae51816
added: #subProjectMakeCallsUsing:
Claus Gittinger <cg@exept.de>
parents:
12428
diff
changeset
|
4156 |
subProjectLCmakeCalls |
12439 | 4157 |
"generate submake-calls for lc" |
4158 |
||
13419 | 4159 |
^ self subProjectMakeCallsUsing:'call lcmake %1 %2'. |
12438
26bbeae51816
added: #subProjectMakeCallsUsing:
Claus Gittinger <cg@exept.de>
parents:
12428
diff
changeset
|
4160 |
! |
26bbeae51816
added: #subProjectMakeCallsUsing:
Claus Gittinger <cg@exept.de>
parents:
12428
diff
changeset
|
4161 |
|
26bbeae51816
added: #subProjectMakeCallsUsing:
Claus Gittinger <cg@exept.de>
parents:
12428
diff
changeset
|
4162 |
subProjectMakeCallsUsing:callString |
9887 | 4163 |
^ String streamContents:[:s | |
13734 | 4164 |
self subProjects do:[:packageID | |
4165 |
s nextPutLine:'@echo "***********************************"'. |
|
4166 |
s nextPutLine:'@echo "Buildung ',(packageID copyReplaceAll:$: with:$/). |
|
4167 |
s nextPutLine:'@echo "***********************************"'. |
|
4168 |
s nextPutLine:'@cd ', (self msdosPathToPackage:packageID from:(self package)). |
|
4169 |
s nextPutAll:'@'; nextPutLine:callString. |
|
4170 |
s nextPutLine:'@cd ', (self msdosPathToPackage:(self package) from:packageID). |
|
4171 |
s cr. |
|
4172 |
] |
|
9887 | 4173 |
] |
4174 |
||
4175 |
"Created: / 14-09-2006 / 18:40:09 / cg" |
|
13734 | 4176 |
"Modified: / 27-09-2011 / 19:36:12 / cg" |
11937 | 4177 |
! |
4178 |
||
4179 |
subProjectVCmakeCalls |
|
12439 | 4180 |
"generate submake-calls for visual-C" |
4181 |
||
13419 | 4182 |
^ self subProjectMakeCallsUsing:'call vcmake %1 %2'. |
9817 | 4183 |
! ! |
4184 |
||
12364 | 4185 |
!ProjectDefinition class methodsFor:'file templates'! |
4186 |
||
13177 | 4187 |
autopackage_default_dot_apspec |
4188 |
"for linux's autopackage" |
|
4189 |
||
4190 |
^ |
|
4191 |
'# -*- shell-script -*- |
|
4192 |
[Meta] |
|
4193 |
ShortName: %(APPLICATION) |
|
4194 |
SoftwareVersion: %(PRODUCT_VERSION) |
|
4195 |
DisplayName: %(DESCRIPTION) |
|
4196 |
RootName: @exept.de/expecco:$SOFTWAREVERSION |
|
4197 |
Summary: %(DESCRIPTION) |
|
4198 |
Maintainer: %(MAINTAINER) |
|
4199 |
Packager: %(PACKAGER) |
|
4200 |
PackageVersion: 1 |
|
4201 |
CPUArchitectures: x86 |
|
4202 |
AutopackageTarget: 1.0 |
|
4203 |
Type: %(PRODUCT_TYPE) |
|
13419 | 4204 |
License: %(PRODUCT_LICENSE) |
13177 | 4205 |
|
4206 |
[Description] |
|
4207 |
%(PRODUCT_DESCRIPTION) |
|
4208 |
||
4209 |
[BuildPrepare] |
|
4210 |
# If you''re using autotools, the default should be enough. |
|
4211 |
# prepareBuild will set up apbuild and run configure for you. If you |
|
4212 |
# need to pass arguments to configure, just add them to prepareBuild: |
|
4213 |
# prepareBuild --enable-foo --disable-bar |
|
4214 |
#prepareBuild |
|
4215 |
||
4216 |
[BuildUnprepare] |
|
4217 |
# If you''re using prepareBuild above, there is no need to change this!! |
|
4218 |
#unprepareBuild |
|
4219 |
||
4220 |
[Globals] |
|
4221 |
# Variables declared in this section will be available in all other sections |
|
4222 |
export APKG_BUILD_SKIP_CONFIGURE=1 |
|
4223 |
export APKG_BUILD_SKIP_MAKE=1 |
|
4224 |
export MYPREFIX=/opt/%(APPLICATION) |
|
4225 |
||
4226 |
[Prepare] |
|
4227 |
#recommend ''@autopackage.org/autopackage-gtk'' 1 |
|
4228 |
||
4229 |
[Imports] |
|
4230 |
import <<EOF |
|
4231 |
$source_dir/%(APPLICATION) |
|
4232 |
$source_dir/resources |
|
4233 |
$source_dir/keyboard.rc |
|
4234 |
$source_dir/display.rc |
|
4235 |
$source_dir/../doc |
|
4236 |
$source_dir/../testsuites/webedition |
|
4237 |
$source_dir/../projects/libraries |
|
4238 |
$source_dir/../reportGenerator/tools |
|
4239 |
$source_dir/../../pdf/afm |
|
4240 |
$source_dir/../plugin/selenium/libexept_expecco_plugin_selenium.so |
|
4241 |
$source_dir/../externalTools |
|
4242 |
EOF |
|
4243 |
||
4244 |
for i in $source_dir/*.so |
|
4245 |
do |
|
4246 |
echo $source_dir/$(readlink $i) |
|
4247 |
done | import |
|
4248 |
||
4249 |
[Install] |
|
4250 |
if [ "$PREFIX" !!= "/usr" ] |
|
4251 |
then |
|
4252 |
export MYPREFIX=$PREFIX |
|
4253 |
fi |
|
4254 |
||
4255 |
find . -type d \( -name CVS -or -name ''not_*'' \) -print | xargs rm -rf |
|
4256 |
mkdir -p $MYPREFIX |
|
4257 |
copyFiles expecco *.rc resources $MYPREFIX/bin |
|
4258 |
copyFiles *.so $MYPREFIX/lib |
|
4259 |
copyFiles doc externalTools $MYPREFIX/packages/exept/expecco |
|
4260 |
copyFiles webedition/projects libraries $MYPREFIX/testsuites |
|
4261 |
copyFiles tools $MYPREFIX/packages/exept/expecco/reportGenerator |
|
4262 |
copyFiles afm $MYPREFIX/packages/exept/pdf |
|
4263 |
copyFiles libexept_expecco_plugin_selenium.so $MYPREFIX/plugin |
|
4264 |
||
4265 |
#installExe expecco |
|
4266 |
#installLib *.so |
|
4267 |
#installData resources |
|
4268 |
#installData keyboard.rc |
|
4269 |
#installData doc |
|
4270 |
||
4271 |
[Uninstall] |
|
4272 |
# Leaving this at the default is safe unless you use custom commands in |
|
4273 |
# "Install" to create files. All autopackage API functions |
|
4274 |
# that installs files are logged. |
|
4275 |
uninstallFromLog |
|
4276 |
' |
|
4277 |
||
4278 |
"Created: / 21-12-2010 / 09:06:21 / cg" |
|
4279 |
! |
|
4280 |
||
12364 | 4281 |
bc_dot_mak |
4282 |
"answer a template for the bc.mak makefile. |
|
4283 |
Any variable definition %(Variable) will be later replaced by the mapping. |
|
4284 |
$% characters have to be duplicated. |
|
4285 |
Only needed for WIN" |
|
4286 |
||
4287 |
^ self subclassResponsibility |
|
4288 |
! |
|
4289 |
||
4290 |
bmake_dot_mak |
|
4291 |
"the template code for the bmake.bat file" |
|
4292 |
||
13419 | 4293 |
^ |
12364 | 4294 |
'@REM ------- |
4295 |
@REM make using borland bcc |
|
4296 |
@REM type bmake, and wait... |
|
4297 |
@REM do not edit - automatically generated from ProjectDefinition |
|
4298 |
@REM ------- |
|
13797 | 4299 |
make.exe -N -f bc.mak %%* |
12364 | 4300 |
|
4301 |
%(SUBPROJECT_BMAKE_CALLS) |
|
4302 |
' |
|
4303 |
||
4304 |
"Created: / 17-08-2006 / 20:04:14 / cg" |
|
4305 |
"Modified: / 14-09-2006 / 19:46:40 / cg" |
|
4306 |
! |
|
4307 |
||
13411 | 4308 |
builder_baseline_dot_rbspec |
4309 |
"For rake-base automatic builder" |
|
13419 | 4310 |
|
13411 | 4311 |
^ ' |
4312 |
# generated from project definition |
|
4313 |
||
4314 |
# load package dependencies |
|
4315 |
load ''package.deps.rake'' |
|
4316 |
||
4317 |
# kludge: clear some invalid dependencies of libwidg |
|
4318 |
# (should be fixed in baseline) |
|
4319 |
clear "stx:libwidg" => "stx:libui" |
|
4320 |
clear "stx:libwidg2" => "stx:libui" |
|
4321 |
||
4322 |
project :''%(APPLICATION):baseline'' do |
|
4323 |
# preamble |
|
4324 |
%(PREAMBLE) |
|
4325 |
# -------- |
|
4326 |
||
4327 |
%(PACKAGES) |
|
4328 |
||
4329 |
application "%(APPLICATION_PACKAGE)" |
|
4330 |
||
4331 |
# postamble |
|
4332 |
%(POSTABLE) |
|
4333 |
# --------- |
|
4334 |
||
4335 |
end |
|
4336 |
' |
|
4337 |
||
4338 |
"Created: / 24-02-2011 / 11:39:00 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
4339 |
"Modified: / 27-02-2011 / 12:42:04 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
4340 |
! |
|
4341 |
||
4342 |
builder_baseline_dot_rbspec_postamble |
|
4343 |
^ '' |
|
4344 |
||
4345 |
"Created: / 24-02-2011 / 11:58:06 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
4346 |
! |
|
4347 |
||
4348 |
builder_baseline_dot_rbspec_preamble |
|
4349 |
^ '' |
|
4350 |
||
4351 |
"Created: / 24-02-2011 / 11:58:05 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
4352 |
! |
|
4353 |
||
12364 | 4354 |
classLine_libInit_dot_cc |
4355 |
||
4356 |
^'_%(CLASS)_Init(pass,__pRT__,snd);' |
|
4357 |
||
4358 |
"Created: / 08-08-2006 / 12:51:44 / fm" |
|
4359 |
"Modified: / 08-08-2006 / 15:46:05 / fm" |
|
4360 |
! |
|
4361 |
||
4362 |
lcmake_dot_mak |
|
4363 |
"the template code for the lcmake.bat file" |
|
4364 |
||
13419 | 4365 |
^ |
12364 | 4366 |
'@REM ------- |
4367 |
@REM make using lcc compiler |
|
4368 |
@REM type lcmake, and wait... |
|
4369 |
@REM do not edit - automatically generated from ProjectDefinition |
|
4370 |
@REM ------- |
|
4371 |
make.exe -N -f bc.mak USELCC=1 %%1 %%2 |
|
4372 |
||
4373 |
%(SUBPROJECT_LCCMAKE_CALLS) |
|
4374 |
' |
|
4375 |
! |
|
4376 |
||
4377 |
make_dot_proto |
|
4378 |
"the template code for the make.proto file" |
|
4379 |
||
4380 |
^ self subclassResponsibility |
|
4381 |
! |
|
4382 |
||
4383 |
make_dot_spec |
|
4384 |
||
13419 | 4385 |
^ |
12364 | 4386 |
'# $','Header','$ |
4387 |
# |
|
13419 | 4388 |
# DO NOT EDIT |
13734 | 4389 |
# automagically generated from the projectDefinition: ',self name,' at ',Timestamp now printString,'. |
12364 | 4390 |
# |
4391 |
# Warning: once you modify this file, do not rerun |
|
4392 |
# stmkmp or projectDefinition-build again - otherwise, your changes are lost. |
|
4393 |
# |
|
4394 |
# This file contains specifications which are common to all platforms. |
|
4395 |
# |
|
4396 |
||
4397 |
# Do NOT CHANGE THESE DEFINITIONS |
|
4398 |
# (otherwise, ST/X will have a hard time to find out the packages location from its packageID, |
|
4399 |
# to find the source code of a class and to find the library for a package) |
|
4400 |
MODULE=%(MODULE) |
|
4401 |
MODULE_DIR=%(MODULE_DIRECTORY) |
|
4402 |
PACKAGE=$(MODULE):$(MODULE_DIR) |
|
4403 |
||
4404 |
||
4405 |
# Argument(s) to the stc compiler (stc --usage). |
|
13875
2e01d09fa4c4
-headerDir= instead of --headerDir=
Claus Gittinger <cg@exept.de>
parents:
13873
diff
changeset
|
4406 |
# -headerDir=. : create header files locally |
12364 | 4407 |
# (if removed, they will be created as common |
4408 |
# -Pxxx : defines the package |
|
4409 |
# -Zxxx : a prefix for variables within the classLib |
|
4410 |
# -Dxxx : defines passed to to CC for inline C-code |
|
4411 |
# -Ixxx : include path passed to CC for inline C-code |
|
4412 |
# +optspace : optimized for space |
|
4413 |
# +optspace2 : optimized more for space |
|
4414 |
# +optspace3 : optimized even more for space |
|
4415 |
# +optinline : generate inline code for some ST constructs |
|
4416 |
# +inlineNew : additionally inline new |
|
4417 |
# +inlineMath : additionally inline some floatPnt math stuff |
|
4418 |
# |
|
4419 |
# ********** OPTIONAL: MODIFY the next line(s) *** |
|
4420 |
# STCLOCALOPTIMIZATIONS=+optinline +inlineNew |
|
4421 |
# STCLOCALOPTIMIZATIONS=+optspace3 |
|
4422 |
STCLOCALOPTIMIZATIONS=%(STCOPTIMIZATIONOPTIONS) |
|
4423 |
||
4424 |
||
4425 |
# Argument(s) to the stc compiler (stc --usage). |
|
4426 |
# -warn : no warnings |
|
4427 |
# -warnNonStandard : no warnings about ST/X extensions |
|
4428 |
# -warnEOLComments : no warnings about EOL comment extension |
|
4429 |
# -warnPrivacy : no warnings about privateClass extension |
|
4430 |
# |
|
4431 |
# ********** OPTIONAL: MODIFY the next line(s) *** |
|
4432 |
# STCWARNINGS=-warn |
|
4433 |
# STCWARNINGS=-warnNonStandard |
|
4434 |
# STCWARNINGS=-warnEOLComments |
|
4435 |
STCWARNINGS=%(STCWARNINGOPTIONS) |
|
4436 |
||
12545 | 4437 |
%(CLASSES) |
4438 |
||
12364 | 4439 |
%(OBJECTS) |
4440 |
' |
|
4441 |
||
4442 |
"Created: / 08-08-2006 / 19:31:29 / fm" |
|
4443 |
"Modified: / 09-08-2006 / 15:10:57 / fm" |
|
13875
2e01d09fa4c4
-headerDir= instead of --headerDir=
Claus Gittinger <cg@exept.de>
parents:
13873
diff
changeset
|
4444 |
"Modified: / 23-12-2011 / 15:07:23 / cg" |
12364 | 4445 |
! |
4446 |
||
12428 | 4447 |
makefile |
13419 | 4448 |
^ |
12428 | 4449 |
'# |
13419 | 4450 |
# DO NOT EDIT |
12428 | 4451 |
# |
13419 | 4452 |
# make uses this file (Makefile) only, if there is no |
12428 | 4453 |
# file named "makefile" (lower-case m) in the same directory. |
4454 |
# My only task is to generate the real makefile and call make again. |
|
4455 |
# Thereafter, I am no longer used and needed. |
|
4456 |
# |
|
4457 |
||
4458 |
.PHONY: run |
|
4459 |
||
4460 |
run: makefile |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4461 |
$(MAKE) -f makefile |
12428 | 4462 |
|
4463 |
#only needed for the definition of $(TOP) |
|
4464 |
include Make.proto |
|
4465 |
||
4466 |
makefile: |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4467 |
$(TOP)/rules/stmkmf |
12428 | 4468 |
' |
4469 |
! |
|
4470 |
||
12364 | 4471 |
objectLine_make_dot_spec |
4472 |
||
4473 |
^' $(OUTDIR)%(CLASSFILE).$(O) \' |
|
4474 |
||
4475 |
"Created: / 08-08-2006 / 20:16:46 / fm" |
|
4476 |
"Modified: / 23-08-2006 / 11:11:38 / cg" |
|
4477 |
! |
|
4478 |
||
4479 |
packageName_dot_rc |
|
4480 |
"the template code for the <libName>.rc file. |
|
4481 |
Only used for WIN" |
|
4482 |
||
13419 | 4483 |
^ |
12364 | 4484 |
'// |
13419 | 4485 |
// DO NOT EDIT |
12364 | 4486 |
// automagically generated from the projectDefinition: ',self name,'. |
4487 |
// |
|
4488 |
VS_VERSION_INFO VERSIONINFO |
|
4489 |
FILEVERSION %(FILE_VERSION_COMMASEPARATED) |
|
4490 |
PRODUCTVERSION %(PRODUCT_VERSION_COMMASEPARATED) |
|
13769
8259f3bf7fa2
changed: #packageName_dot_rc
Claus Gittinger <cg@exept.de>
parents:
13763
diff
changeset
|
4491 |
#if (__BORLANDC__) |
12364 | 4492 |
FILEFLAGSMASK VS_FF_DEBUG | VS_FF_PRERELEASE |
4493 |
FILEFLAGS VS_FF_PRERELEASE | VS_FF_SPECIALBUILD |
|
4494 |
FILEOS VOS_NT_WINDOWS32 |
|
4495 |
FILETYPE %(FILETYPE) |
|
4496 |
FILESUBTYPE VS_USER_DEFINED |
|
13769
8259f3bf7fa2
changed: #packageName_dot_rc
Claus Gittinger <cg@exept.de>
parents:
13763
diff
changeset
|
4497 |
#endif |
12364 | 4498 |
|
4499 |
BEGIN |
|
4500 |
BLOCK "StringFileInfo" |
|
4501 |
BEGIN |
|
4502 |
BLOCK "040904E4" |
|
4503 |
BEGIN |
|
4504 |
VALUE "CompanyName", "%(COMPANY_NAME)\0" |
|
4505 |
VALUE "FileDescription", "%(FILE_DESCRIPTION)\0" |
|
4506 |
VALUE "FileVersion", "%(FILE_VERSION)\0" |
|
4507 |
VALUE "InternalName", "%(INTERNAL_NAME)\0" |
|
4508 |
%(LEGAL_COPYRIGHT_LINE) |
|
4509 |
VALUE "ProductName", "%(PRODUCT_NAME)\0" |
|
4510 |
VALUE "ProductVersion", "%(PRODUCT_VERSION)\0" |
|
4511 |
VALUE "ProductDate", "%(PRODUCT_DATE)\0" |
|
4512 |
END |
|
4513 |
||
4514 |
END |
|
4515 |
||
4516 |
BLOCK "VarFileInfo" |
|
4517 |
BEGIN // Language | Translation |
|
4518 |
VALUE "Translation", 0x409, 0x4E4 // U.S. English, Windows Multilingual |
|
4519 |
END |
|
4520 |
END |
|
4521 |
' |
|
4522 |
" |
|
4523 |
stx_libbasic3 packageName_dot_rc |
|
4524 |
stx_libbasic3 generate_packageName_dot_rc |
|
4525 |
" |
|
4526 |
||
4527 |
"Created: / 08-08-2006 / 19:31:29 / fm" |
|
4528 |
"Modified: / 09-08-2006 / 15:10:57 / fm" |
|
13769
8259f3bf7fa2
changed: #packageName_dot_rc
Claus Gittinger <cg@exept.de>
parents:
13763
diff
changeset
|
4529 |
"Modified: / 07-10-2011 / 10:51:34 / cg" |
12364 | 4530 |
! |
4531 |
||
13411 | 4532 |
package_dot_deps_dot_rake |
4533 |
^ ' |
|
4534 |
# Package dependencies. |
|
4535 |
# Automatically generated by project defintion. |
|
4536 |
||
4537 |
%(DEPENDENCIES) |
|
4538 |
||
4539 |
' |
|
4540 |
||
4541 |
"Created: / 24-02-2011 / 22:32:10 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
4542 |
! |
|
4543 |
||
12364 | 4544 |
vcmake_dot_mak |
4545 |
"the template code for the vcmake.bat file" |
|
4546 |
||
13419 | 4547 |
^ |
12364 | 4548 |
'@REM ------- |
4549 |
@REM make using microsoft visual c |
|
4550 |
@REM type vcmake, and wait... |
|
4551 |
@REM do not edit - automatically generated from ProjectDefinition |
|
4552 |
@REM ------- |
|
13789 | 4553 |
|
4554 |
@if not defined VSINSTALLDIR ( |
|
4555 |
call "C:\Program Files\Microsoft Visual Studio 10.0"\VC\bin\vcvars32.bat |
|
4556 |
) |
|
13797 | 4557 |
make.exe -N -f bc.mak -DUSEVC %%* |
12364 | 4558 |
|
4559 |
%(SUBPROJECT_VCMAKE_CALLS) |
|
4560 |
' |
|
12966 | 4561 |
|
13789 | 4562 |
"Modified: / 08-10-2011 / 10:43:20 / cg" |
12364 | 4563 |
! ! |
4564 |
||
4565 |
!ProjectDefinition class methodsFor:'loading'! |
|
4566 |
||
12397 | 4567 |
ensureFullyLoaded |
4568 |
"ensure that all classes and extensions are loaded properly. |
|
4569 |
This is normally no problem for compiled classLibs - however, if a package |
|
4570 |
has only be installedAsAutoloaded, some classes might want to ensure that |
|
4571 |
when being loaded themself." |
|
4572 |
||
4573 |
self hasAllExtensionsLoaded ifFalse:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4574 |
self breakPoint:#cg. |
12397 | 4575 |
]. |
4576 |
self hasAllClassesFullyLoaded ifFalse:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4577 |
self hasAllClassesLoaded ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4578 |
self breakPoint:#cg. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4579 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4580 |
self installAutoloadedClasses. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4581 |
self classes do:[:cls | cls autoload ]. |
12397 | 4582 |
]. |
4583 |
||
4584 |
" |
|
4585 |
stx_libbasic ensureFullyLoaded |
|
4586 |
" |
|
12731 | 4587 |
"Verbose := true |
4588 |
stx_libjavascript hasAllExtensionsLoaded |
|
4589 |
" |
|
12735
215f7514f56b
comment/format in: #ensureFullyLoaded
Claus Gittinger <cg@exept.de>
parents:
12731
diff
changeset
|
4590 |
"Verbose := true |
215f7514f56b
comment/format in: #ensureFullyLoaded
Claus Gittinger <cg@exept.de>
parents:
12731
diff
changeset
|
4591 |
stx_goodies_soap_xe hasAllExtensionsLoaded |
215f7514f56b
comment/format in: #ensureFullyLoaded
Claus Gittinger <cg@exept.de>
parents:
12731
diff
changeset
|
4592 |
" |
13689
9d93d5e56029
changed: #ensureFullyLoaded
Claus Gittinger <cg@exept.de>
parents:
13688
diff
changeset
|
4593 |
|
9d93d5e56029
changed: #ensureFullyLoaded
Claus Gittinger <cg@exept.de>
parents:
13688
diff
changeset
|
4594 |
"Modified: / 12-09-2011 / 16:57:53 / cg" |
12397 | 4595 |
! |
4596 |
||
12364 | 4597 |
load |
4598 |
"load the project |
|
13419 | 4599 |
Answer true, if new classes have been installed for this package, |
12364 | 4600 |
false if the package's classes have been already present." |
4601 |
||
4602 |
^ self loadAsAutoloaded:false. |
|
4603 |
! |
|
4604 |
||
4605 |
loadAsAutoloaded:asAutoloaded |
|
4606 |
"load the project. |
|
4607 |
If asAutoloaded == true, install all new classes as autoloaded. |
|
4608 |
Answer true, if new classes have been installed for this package, |
|
4609 |
false if the package's classes have been already present." |
|
4610 |
||
4611 |
|newStuffHasBeenLoaded meOrMySecondIncarnation| |
|
4612 |
||
13614
5606bfa8cbec
added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13610
diff
changeset
|
4613 |
self projectIsLoaded ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4614 |
asAutoloaded ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4615 |
"/ to be considered !! |
13614
5606bfa8cbec
added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13610
diff
changeset
|
4616 |
"/ self isFullyLoaded ifFalse:[ |
5606bfa8cbec
added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13610
diff
changeset
|
4617 |
"/ self hasAllExtensionsLoaded ifFalse:[ |
5606bfa8cbec
added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13610
diff
changeset
|
4618 |
"/ self loadExtensions. |
5606bfa8cbec
added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13610
diff
changeset
|
4619 |
"/ ]. |
5606bfa8cbec
added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13610
diff
changeset
|
4620 |
"/ self loadAllAutoloadedClasses |
5606bfa8cbec
added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13610
diff
changeset
|
4621 |
"/ ]. |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4622 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4623 |
^ false |
13614
5606bfa8cbec
added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13610
diff
changeset
|
4624 |
]. |
12749 | 4625 |
thisContext isRecursive ifTrue:[self breakPoint:#cg. ^ false]. "/ avoid endless loops |
12364 | 4626 |
|
4627 |
newStuffHasBeenLoaded := false. |
|
4628 |
||
4629 |
(self infoPrinting and:[Smalltalk silentLoading not]) ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4630 |
"/ thisContext fullPrintAll. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4631 |
Transcript showCR:('loading %1%2...' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4632 |
bindWith:(asAutoloaded ifTrue:['as autoloaded '] ifFalse:['']) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4633 |
with:self name). |
12364 | 4634 |
]. |
4635 |
||
4636 |
self rememberOverwrittenExtensionMethods. |
|
4637 |
||
4638 |
self activityNotification:'Executing pre-load action'. |
|
4639 |
self preLoadAction. |
|
4640 |
||
4641 |
meOrMySecondIncarnation := self. |
|
4642 |
||
4643 |
Class withoutUpdatingChangesDo:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4644 |
self activityNotification:'Loading prerequisities'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4645 |
self loadPreRequisitesAsAutoloaded:asAutoloaded. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4646 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4647 |
self checkPrerequisitesForLoading. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4648 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4649 |
asAutoloaded ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4650 |
self loadClassLibrary. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4651 |
"/ could have overloaded my first incarnation |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4652 |
meOrMySecondIncarnation := (Smalltalk at:(self name)) ? self. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4653 |
meOrMySecondIncarnation ~~ self ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4654 |
meOrMySecondIncarnation fetchSlotsFrom:self. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4655 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4656 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4657 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4658 |
self hasAllExtensionsLoaded ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4659 |
self activityNotification:'Loading extensions'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4660 |
newStuffHasBeenLoaded := newStuffHasBeenLoaded | meOrMySecondIncarnation loadExtensions. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4661 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4662 |
self hasAllClassesLoaded ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4663 |
self activityNotification:'Loading classes'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4664 |
newStuffHasBeenLoaded := newStuffHasBeenLoaded | (meOrMySecondIncarnation loadAllClassesAsAutoloaded:asAutoloaded). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4665 |
]. |
12743 | 4666 |
"/ no, don't load subProjects here - will lead to a recursion, which leads |
4667 |
"/ to some classes being loaded from source (soap) |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4668 |
self activityNotification:'Loading sub projects'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4669 |
meOrMySecondIncarnation loadSubProjectsAsAutoloaded:asAutoloaded. |
12364 | 4670 |
]. |
13194
8e451f8ff654
changed: #loadAsAutoloaded:
Claus Gittinger <cg@exept.de>
parents:
13178
diff
changeset
|
4671 |
self activityNotification:('Executing post-load action for %1' bindWith:self package). |
12372 | 4672 |
|
4673 |
"/ mhmh - already done for dll-loaded packages |
|
4674 |
"/ meOrMySecondIncarnation initializeAllClasses. |
|
12364 | 4675 |
meOrMySecondIncarnation postLoadAction. |
4676 |
||
4677 |
meOrMySecondIncarnation projectIsLoaded:true. |
|
12736
e18f8f352186
changed: #loadAsAutoloaded:
Claus Gittinger <cg@exept.de>
parents:
12735
diff
changeset
|
4678 |
meOrMySecondIncarnation ~~ self ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4679 |
self projectIsLoaded:true. |
12736
e18f8f352186
changed: #loadAsAutoloaded:
Claus Gittinger <cg@exept.de>
parents:
12735
diff
changeset
|
4680 |
]. |
12364 | 4681 |
|
13194
8e451f8ff654
changed: #loadAsAutoloaded:
Claus Gittinger <cg@exept.de>
parents:
13178
diff
changeset
|
4682 |
self activityNotification:('Done (%1).' bindWith:self package). |
12364 | 4683 |
^ newStuffHasBeenLoaded |
4684 |
||
4685 |
"Created: / 17-08-2006 / 01:01:41 / cg" |
|
4686 |
"Modified: / 30-10-2008 / 08:16:21 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
4687 |
"Modified: / 22-08-2009 / 12:02:14 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
13623
46625f58d8ee
changed: #loadAsAutoloaded:
Claus Gittinger <cg@exept.de>
parents:
13614
diff
changeset
|
4688 |
"Modified: / 04-09-2011 / 10:01:53 / cg" |
12364 | 4689 |
! |
4690 |
||
4691 |
unloadPackage |
|
4692 |
"unload the project. |
|
4693 |
Fails if there are still instances of any of my classes in the system" |
|
4694 |
||
4695 |
self projectIsLoaded ifFalse:[^ false]. |
|
4696 |
thisContext isRecursive ifTrue:[^ false]. |
|
4697 |
||
4698 |
(self infoPrinting and:[Smalltalk silentLoading not]) ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4699 |
"/ thisContext fullPrintAll. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4700 |
Transcript show:'unloading '; showCR:self name. |
12364 | 4701 |
]. |
4702 |
||
4703 |
self activityNotification:'Executing pre-unload action'. |
|
4704 |
self preUnloadAction. |
|
4705 |
||
4706 |
self activityNotification:'Restoring original methods'. |
|
4707 |
self restoreOverwrittenExtensionMethods. |
|
4708 |
||
4709 |
Class withoutUpdatingChangesDo:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4710 |
self activityNotification:'Unloading sunprojects'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4711 |
self unloadSubProjects. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4712 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4713 |
self activityNotification:'Unloading classes'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4714 |
self unloadClassLibrary. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4715 |
self unloadAllClasses. |
12364 | 4716 |
]. |
4717 |
self projectIsLoaded:false. |
|
4718 |
^ true |
|
4719 |
! ! |
|
4720 |
||
12086 | 4721 |
!ProjectDefinition class methodsFor:'misc ui support'! |
4722 |
||
4723 |
iconInBrowserSymbol |
|
4724 |
<resource: #programImage> |
|
4725 |
||
4726 |
self theNonMetaclass isApplicationDefinition ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4727 |
self theNonMetaclass isGUIApplication ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4728 |
^ #guiApplicationDefinitionClassIcon |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4729 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4730 |
^ #applicationDefinitionClassIcon |
12086 | 4731 |
]. |
4732 |
^ super iconInBrowserSymbol |
|
4733 |
! ! |
|
4734 |
||
9575 | 4735 |
!ProjectDefinition class methodsFor:'private'! |
9536 | 4736 |
|
13411 | 4737 |
abbrevs |
13592 | 4738 |
"return a dictionary containing my abbreviations; |
4739 |
this dictionary is read from my project-directory's abbrev.stc file, |
|
4740 |
and cached for future use" |
|
4741 |
||
4742 |
|abbrevs| |
|
4743 |
||
4744 |
AccessLock critical:[ |
|
13959 | 4745 |
|mustRead file myPackageDirectory| |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4746 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4747 |
AbbrevDictionary isNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4748 |
AbbrevDictionary := WeakIdentityDictionary new. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4749 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4750 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4751 |
mustRead := false. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4752 |
abbrevs := AbbrevDictionary at:self ifAbsent:[ mustRead := true. Dictionary new ]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4753 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4754 |
mustRead ifTrue:[ |
13959 | 4755 |
myPackageDirectory := self packageDirectory. |
4756 |
myPackageDirectory isNil ifTrue:[ |
|
4757 |
] ifFalse:[ |
|
4758 |
file := myPackageDirectory / 'abbrev.stc'. |
|
4759 |
file exists ifTrue: [ |
|
4760 |
file readingFileDo:[:stream | |
|
4761 |
Smalltalk |
|
4762 |
withAbbreviationsFromStream:stream |
|
4763 |
do:[:nm :fn :pkg :cat :sz| |
|
4764 |
abbrevs at: nm put: (AbbrevEntry new className:nm fileName:fn category:cat numClassInstVars:sz) |
|
4765 |
] |
|
4766 |
] |
|
4767 |
]. |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4768 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4769 |
]. |
13419 | 4770 |
]. |
13695 | 4771 |
|
13411 | 4772 |
^abbrevs |
4773 |
||
4774 |
"Created: / 06-03-2011 / 18:25:49 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
13959 | 4775 |
"Modified: / 20-01-2012 / 15:42:47 / cg" |
13411 | 4776 |
! |
4777 |
||
12368 | 4778 |
additionalClassAttributesFor: aClass |
4779 |
"Answers additional set of class attributes for given class |
|
4780 |
Individual project definitions may override this method, but |
|
4781 |
overriding method should always merge its attributes with result |
|
4782 |
of 'super additionalClassAttributesFor: aClass'. |
|
4783 |
||
4784 |
Here, we add #autoload attributes to all test cases and |
|
4785 |
test resources, as they are not neccessary for the package |
|
4786 |
and should not be compiled (because of unwanted dependency |
|
4787 |
on stx:goodies/sunit package) |
|
4788 |
" |
|
4789 |
||
4790 |
(aClass inheritsFrom: TestCase) ifTrue:[^#(autoload)]. |
|
4791 |
(aClass inheritsFrom: TestResource) ifTrue:[^#(autoload)]. |
|
4792 |
||
4793 |
"No additional attributes" |
|
4794 |
^#() |
|
4795 |
||
4796 |
" |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4797 |
stx_libbasic additionalClassAttributesFor: Object |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4798 |
stx_libtool additionalClassAttributesFor: Tools::NavigationHistoryTests |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4799 |
stx_goodies_sunit additionalClassAttributesFor: TestCase |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4800 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4801 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4802 |
stx_libtool classNamesAndAttributes_code_ignoreOldEntries:true ignoreOldDefinition: true |
12368 | 4803 |
|
4804 |
" |
|
4805 |
||
4806 |
"Created: / 26-10-2009 / 12:54:38 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
4807 |
! |
|
4808 |
||
11868
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4809 |
checkIfClassesArePresent |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4810 |
"check if all classes defined by this project are present and |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4811 |
offer a dialog to abort the current operation if not" |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4812 |
|
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4813 |
|check nonExistantClasses| |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4814 |
|
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4815 |
nonExistantClasses := Set new. |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4816 |
|
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4817 |
check := |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4818 |
[:eachClassName | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4819 |
|cls fn wasLoaded failedToLoad numClassInstvars| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4820 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4821 |
cls := Smalltalk classNamed:eachClassName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4822 |
cls isNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4823 |
Transcript showCR:eachClassName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4824 |
nonExistantClasses add:eachClassName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4825 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4826 |
]. |
11868
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4827 |
|
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4828 |
self allClassNames do:check. |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4829 |
self namesAndAttributesIn:(self additionalClassNamesAndAttributes) do:[:nm :attr | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4830 |
(attr isEmptyOrNil or:[(attr includes:#autoload) not]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4831 |
check value:nm |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4832 |
]. |
11868
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4833 |
]. |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4834 |
|
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4835 |
nonExistantClasses notEmpty ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4836 |
(Dialog confirm:(Dialog classResources |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4837 |
stringWithCRs:'"%1" and possibly more classes are missing.\Cannot generate a correct "abbrev.stc" file.\\Continue anyway?' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4838 |
with:nonExistantClasses anElement allBold)) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4839 |
ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4840 |
AbortOperationRequest raise. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4841 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4842 |
^ false. |
11868
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4843 |
]. |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4844 |
|
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4845 |
^ true |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4846 |
! |
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
4847 |
|
12368 | 4848 |
classNamesAndAttributesAsSpecArray |
13419 | 4849 |
"given a classNamesAndAttributes array, make this a spec array (array of arrays). |
12368 | 4850 |
This decompresses class-name entries into a one-element array for easier processing" |
4851 |
||
4852 |
^ self classNamesAndAttributes |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4853 |
collect:[:entry | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4854 |
entry isArray ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4855 |
entry first isSymbol ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4856 |
entry |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4857 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4858 |
(Array with:entry first asSymbol) , (entry copyFrom:2) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4859 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4860 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4861 |
Array with:entry asSymbol. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4862 |
]]. |
12368 | 4863 |
|
4864 |
"Created: / 19-02-2007 / 16:11:53 / cg" |
|
4865 |
! |
|
4866 |
||
9627 | 4867 |
classNamesAndAttributesDo: aBlock |
4868 |
self namesAndAttributesIn:(self classNamesAndAttributes) do: aBlock |
|
4869 |
||
4870 |
"Modified: / 22-08-2006 / 18:20:21 / cg" |
|
9607 | 4871 |
! |
4872 |
||
12368 | 4873 |
classNamesAndAttributesFromSpecArray:aSpecArray |
4874 |
"given a spec array (array of arrays), make this a classNamesAndAttributes array |
|
4875 |
as stored literally in the method. |
|
4876 |
This compresses single element array-elements into plain names |
|
4877 |
(to save code in the compiled binaries)" |
|
4878 |
||
4879 |
^ aSpecArray |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4880 |
collect:[:entry | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4881 |
(entry isArray and:[entry size == 1]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4882 |
entry first |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4883 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4884 |
entry |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4885 |
]]. |
12368 | 4886 |
|
4887 |
"Created: / 19-02-2007 / 16:12:32 / cg" |
|
4888 |
! |
|
4889 |
||
9664 | 4890 |
compile:someCode categorized:category |
13419 | 4891 |
Class packageQuerySignal |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4892 |
answer:self package |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4893 |
do:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4894 |
self theMetaclass compilerClass |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4895 |
compile:someCode |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4896 |
forClass:self theMetaclass |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4897 |
inCategory:category |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4898 |
notifying:nil |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4899 |
install:true |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4900 |
skipIfSame:true |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4901 |
silent:true. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4902 |
] |
9664 | 4903 |
|
4904 |
"Created: / 23-08-2006 / 14:36:53 / cg" |
|
4905 |
! |
|
4906 |
||
9627 | 4907 |
compiled_classes |
13419 | 4908 |
^ self compiled_classNames |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4909 |
collect: |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4910 |
[:eachName| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4911 |
|cls| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4912 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4913 |
cls := (Smalltalk at:eachName asSymbol). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4914 |
(cls isNil or:[cls isBehavior not]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4915 |
Transcript showCR:('ProjectDefinition: missing/invalid class: ', eachName). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4916 |
cls := nil. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4917 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4918 |
cls. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4919 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4920 |
thenSelect:[:cls | cls notNil] |
9627 | 4921 |
|
4922 |
"Created: / 09-08-2006 / 16:28:15 / fm" |
|
4923 |
"Modified: / 09-08-2006 / 18:02:28 / fm" |
|
10251 | 4924 |
"Modified: / 07-12-2006 / 17:48:11 / cg" |
9536 | 4925 |
! |
4926 |
||
9627 | 4927 |
compiled_classesDo:aBlock |
4928 |
self compiled_classes do:aBlock. |
|
4929 |
||
4930 |
"Created: / 09-08-2006 / 16:28:15 / fm" |
|
4931 |
"Modified: / 09-08-2006 / 18:02:28 / fm" |
|
4932 |
! |
|
4933 |
||
13419 | 4934 |
compiled_classesForArchitecture:arch |
4935 |
^ (self compiled_classNamesForPlatform:arch) |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4936 |
collect:[:eachName | (Smalltalk at:eachName asSymbol) ] |
9627 | 4937 |
|
10251 | 4938 |
" |
4939 |
stx_libbasic compiled_classesForArchitecture:#win32 |
|
4940 |
stx_libbasic compiled_classesForArchitecture:#macos |
|
4941 |
stx_libbasic compiled_classesForArchitecture:#unix |
|
4942 |
" |
|
4943 |
||
9627 | 4944 |
"Created: / 09-08-2006 / 16:28:15 / fm" |
4945 |
"Modified: / 09-08-2006 / 18:02:28 / fm" |
|
10251 | 4946 |
"Modified: / 07-12-2006 / 17:43:17 / cg" |
9627 | 4947 |
! |
4948 |
||
4949 |
compiled_classes_common |
|
13419 | 4950 |
^ self |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4951 |
compiled_classNames_common |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4952 |
collect:[:eachName | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4953 |
|cls| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4954 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4955 |
cls := (Smalltalk at:eachName asSymbol). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4956 |
cls isBehavior ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4957 |
self warn:('Missing/invalid class: %1\\%2' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4958 |
bindWith:eachName |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4959 |
with:('Warning: The class is skipped in the list of compiled classes.' allBold)) withCRs. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4960 |
cls := nil. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4961 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4962 |
cls |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4963 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4964 |
thenSelect:[:cls| cls notNil "isBehavior"] |
9627 | 4965 |
|
4966 |
"Created: / 09-08-2006 / 16:28:15 / fm" |
|
4967 |
"Modified: / 09-08-2006 / 18:02:28 / fm" |
|
13090
827d5322948f
changed: #compiled_classes_common
Claus Gittinger <cg@exept.de>
parents:
13088
diff
changeset
|
4968 |
"Modified: / 11-10-2010 / 12:11:06 / cg" |
9607 | 4969 |
! |
4970 |
||
9627 | 4971 |
cvsRevision |
4972 |
|rev| |
|
4973 |
||
4974 |
rev := self revision. |
|
4975 |
rev isNil ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4976 |
"not yet pubplished" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
4977 |
^ #( '0' '1' ) |
9627 | 4978 |
]. |
4979 |
^ rev asCollectionOfSubstringsSeparatedBy:$. . |
|
4980 |
||
4981 |
" |
|
4982 |
self cvsRevision |
|
13419 | 4983 |
stx_libbasic3 cvsRevision |
9627 | 4984 |
" |
4985 |
||
4986 |
"Created: / 17-08-2006 / 20:19:03 / cg" |
|
9575 | 4987 |
! |
4988 |
||
13411 | 4989 |
defaultClassAttributesFor: aClass |
4990 |
"Answers default set of class attributes for given class. |
|
4991 |
This is internal method only, to per-project customization |
|
4992 |
please override either #additionalClassAttributes or |
|
4993 |
#additional classAttributesFor:" |
|
4994 |
||
4995 |
| attrs | |
|
4996 |
||
4997 |
"JV @ 2010-06-19 |
|
4998 |
Add a programming language attribute for non-smalltalk classes. |
|
4999 |
Used by multi-lang enabled loading mechanism" |
|
13419 | 5000 |
attrs := aClass programmingLanguage isSmalltalk |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5001 |
ifTrue:[#()] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5002 |
ifFalse:[Array with: (Array with: #lang with: aClass programmingLanguage name asSymbol)]. |
13419 | 5003 |
|
13411 | 5004 |
|
5005 |
"JV @ 2009-10-26 |
|
5006 |
Give a project definition to specify additional attributes for given class." |
|
5007 |
attrs := attrs , (self additionalClassAttributesFor: aClass). |
|
5008 |
||
5009 |
^attrs |
|
5010 |
||
5011 |
"Created: / 19-06-2010 / 10:44:13 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
5012 |
! |
|
5013 |
||
9627 | 5014 |
inconsistency:message |
5015 |
Dialog warn:message |
|
9536 | 5016 |
|
9627 | 5017 |
" |
5018 |
self searchForNeverCompiledSuperclasses |
|
13419 | 5019 |
DapasX_Datenbasis searchForNeverCompiledSuperclasses |
9627 | 5020 |
" |
5021 |
||
5022 |
"Created: / 09-08-2006 / 16:32:31 / fm" |
|
9536 | 5023 |
! |
5024 |
||
9826
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5025 |
makeOSIncludesWith:fileSeparator from:aString |
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5026 |
^ aString copy replaceAny:'/\' with:fileSeparator |
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5027 |
|
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5028 |
" |
13419 | 5029 |
self makeOSIncludesWith:$/ from:'-I$(TOP)/foo/bar' |
5030 |
self makeOSIncludesWith:$\ from:'-I$(TOP)/foo/bar' |
|
9826
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5031 |
" |
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5032 |
|
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5033 |
"Created: / 06-09-2006 / 18:17:03 / cg" |
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5034 |
! |
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5035 |
|
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5036 |
makeUnixIncludes:aString |
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5037 |
^ self makeOSIncludesWith:$/ from:aString |
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5038 |
|
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5039 |
"Created: / 06-09-2006 / 18:16:19 / cg" |
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5040 |
! |
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5041 |
|
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5042 |
makeWin32Includes:aString |
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5043 |
^ self makeOSIncludesWith:$\ from:aString |
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5044 |
|
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5045 |
"Created: / 06-09-2006 / 18:16:13 / cg" |
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5046 |
! |
8d5fe8462720
common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents:
9825
diff
changeset
|
5047 |
|
13411 | 5048 |
mergeClassAttributes: attr1 with: attr2 |
5049 |
||
5050 |
^attr1 , (attr2 reject:[:each|attr1 includes: each]) |
|
5051 |
||
5052 |
"Created: / 19-06-2010 / 10:50:02 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
5053 |
! |
|
5054 |
||
5055 |
mergeDefaultClassAttributesFor: aClass with: attributes |
|
5056 |
||
5057 |
^self mergeClassAttributes: attributes with: (self defaultClassAttributesFor: aClass) |
|
5058 |
||
5059 |
"Created: / 19-06-2010 / 10:51:49 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
5060 |
! |
|
5061 |
||
9627 | 5062 |
namesAndAttributesIn:aCollection do: aBlock |
5063 |
aCollection do:[:entry | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5064 |
|className attributes| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5065 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5066 |
entry isArray ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5067 |
className := entry. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5068 |
attributes := #(). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5069 |
] ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5070 |
className := entry first. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5071 |
attributes := entry copyFrom:2. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5072 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5073 |
aBlock value: className value: attributes |
9627 | 5074 |
]. |
5075 |
||
5076 |
"Created: / 22-08-2006 / 18:20:09 / cg" |
|
9621 | 5077 |
! |
5078 |
||
9627 | 5079 |
searchForClasses |
10010 | 5080 |
"answer all non-private classes that belong to this project. |
10005 | 5081 |
They are sorted in load order" |
5082 |
||
13419 | 5083 |
^ Class classesSortedByLoadOrder:(self searchForClassesWithProject: self package) |
9627 | 5084 |
|
5085 |
" |
|
10010 | 5086 |
stx_libbasic3 searchForClasses |
11868
59e160ca3419
First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents:
11829
diff
changeset
|
5087 |
stx_goodies_webServer_htmlTree searchForClasses |
9627 | 5088 |
" |
5089 |
||
5090 |
"Modified: / 07-08-2006 / 21:56:25 / fm" |
|
5091 |
"Created: / 17-08-2006 / 21:18:30 / cg" |
|
9536 | 5092 |
! |
5093 |
||
9627 | 5094 |
searchForClassesWithProject: aProjectID |
5095 |
||
13419 | 5096 |
^ Smalltalk allClasses |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5097 |
select:[:cls | (cls package = aProjectID) ]. |
9627 | 5098 |
|
5099 |
" |
|
5100 |
self searchForClassesWithProject: #'bosch:dapasx' |
|
5101 |
self searchForClassesWithProject: #'bosch:dapasx/datenbasis' |
|
5102 |
self searchForClassesWithProject: #'bosch:dapasx/kernel' |
|
5103 |
" |
|
5104 |
||
5105 |
"Created: / 07-08-2006 / 20:42:39 / fm" |
|
5106 |
"Modified: / 07-08-2006 / 21:56:25 / fm" |
|
5107 |
"Modified: / 16-08-2006 / 18:50:48 / User" |
|
9536 | 5108 |
! |
5109 |
||
9627 | 5110 |
searchForExtensions |
5111 |
^ self searchForExtensionsWithProject:self package |
|
5112 |
||
5113 |
" |
|
13419 | 5114 |
self searchForExtensions |
9627 | 5115 |
DapasXProject searchForExtensions |
5116 |
DapasX_Datenbasis searchForExtensions |
|
10106
c26879b72dfe
extensionlist generator was buggy
Claus Gittinger <cg@exept.de>
parents:
10104
diff
changeset
|
5117 |
stx_libtool searchForExtensions |
9627 | 5118 |
" |
5119 |
||
5120 |
"Modified: / 09-08-2006 / 13:01:26 / fm" |
|
5121 |
"Created: / 17-08-2006 / 21:17:46 / cg" |
|
10106
c26879b72dfe
extensionlist generator was buggy
Claus Gittinger <cg@exept.de>
parents:
10104
diff
changeset
|
5122 |
"Modified: / 23-10-2006 / 11:03:07 / cg" |
9575 | 5123 |
! |
5124 |
||
9627 | 5125 |
searchForExtensionsWithProject:aProjectID |
5126 |
"search for any class which has extensions from aProjectID. |
|
10086
024ea420d1a6
extension method stuff refactored
Claus Gittinger <cg@exept.de>
parents:
10080
diff
changeset
|
5127 |
Return the extension-methods sorted by classname-selector" |
9627 | 5128 |
|
5129 |
|methods| |
|
5130 |
||
11152 | 5131 |
methods := Smalltalk allExtensionsForPackage:aProjectID. |
13419 | 5132 |
methods |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5133 |
sort:[:m1 :m2 | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5134 |
|c1 c2| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5135 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5136 |
c1 := m1 mclass. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5137 |
c2 := m2 mclass. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5138 |
c1 == c2 ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5139 |
m1 selector < m2 selector |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5140 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5141 |
(c2 isMeta and:[c1 isMeta not]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5142 |
true |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5143 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5144 |
(c1 isMeta and:[c2 isMeta not]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5145 |
false |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5146 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5147 |
c1 name < c2 name |
9908
eede5b535b1e
extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents:
9906
diff
changeset
|
5148 |
"/ (c2 isSubclassOf:c1) ifTrue:[ |
eede5b535b1e
extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents:
9906
diff
changeset
|
5149 |
"/ true |
eede5b535b1e
extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents:
9906
diff
changeset
|
5150 |
"/ ] ifFalse:[ |
eede5b535b1e
extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents:
9906
diff
changeset
|
5151 |
"/ (c1 isSubclassOf:c2) ifTrue:[ |
eede5b535b1e
extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents:
9906
diff
changeset
|
5152 |
"/ false |
eede5b535b1e
extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents:
9906
diff
changeset
|
5153 |
"/ ] ifFalse:[ |
eede5b535b1e
extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents:
9906
diff
changeset
|
5154 |
"/ "/ leave as is |
eede5b535b1e
extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents:
9906
diff
changeset
|
5155 |
"/ true |
eede5b535b1e
extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents:
9906
diff
changeset
|
5156 |
"/ ]. |
eede5b535b1e
extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents:
9906
diff
changeset
|
5157 |
"/ ]. |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5158 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5159 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5160 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5161 |
]. |
9627 | 5162 |
^ methods |
5163 |
||
5164 |
" |
|
5165 |
self searchForExtensionsWithProject:#'bosch:dapasx' |
|
5166 |
self searchForExtensionsWithProject:#'cg:oyster' |
|
10086
024ea420d1a6
extension method stuff refactored
Claus Gittinger <cg@exept.de>
parents:
10080
diff
changeset
|
5167 |
self searchForExtensionsWithProject:#'stx:libboss' |
9627 | 5168 |
" |
5169 |
||
5170 |
"Created: / 17-08-2006 / 21:19:04 / cg" |
|
10086
024ea420d1a6
extension method stuff refactored
Claus Gittinger <cg@exept.de>
parents:
10080
diff
changeset
|
5171 |
"Modified: / 12-10-2006 / 20:45:39 / cg" |
9536 | 5172 |
! |
5173 |
||
9627 | 5174 |
searchForProjectsWhichProvideHeaderFiles |
9883
c641767d1483
include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents:
9880
diff
changeset
|
5175 |
|addPackage myPackageID requiredPackages| |
c641767d1483
include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents:
9880
diff
changeset
|
5176 |
|
c641767d1483
include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents:
9880
diff
changeset
|
5177 |
myPackageID := self package. |
c641767d1483
include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents:
9880
diff
changeset
|
5178 |
requiredPackages := Set new. |
c641767d1483
include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents:
9880
diff
changeset
|
5179 |
|
c641767d1483
include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents:
9880
diff
changeset
|
5180 |
addPackage := |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5181 |
[:package | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5182 |
(package ~= myPackageID) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5183 |
true "(package startsWith:'stx:') not" ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5184 |
package ~= PackageId noProjectID ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5185 |
requiredPackages add:package. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5186 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5187 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5188 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5189 |
]. |
9883
c641767d1483
include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents:
9880
diff
changeset
|
5190 |
|
12555
9924562388ed
changed: #searchForProjectsWhichProvideHeaderFiles
Claus Gittinger <cg@exept.de>
parents:
12554
diff
changeset
|
5191 |
"/ need them also... |
9924562388ed
changed: #searchForProjectsWhichProvideHeaderFiles
Claus Gittinger <cg@exept.de>
parents:
12554
diff
changeset
|
5192 |
self preRequisites do:[:eachPreRequisitePackage | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5193 |
addPackage value:eachPreRequisitePackage |
12555
9924562388ed
changed: #searchForProjectsWhichProvideHeaderFiles
Claus Gittinger <cg@exept.de>
parents:
12554
diff
changeset
|
5194 |
]. |
9924562388ed
changed: #searchForProjectsWhichProvideHeaderFiles
Claus Gittinger <cg@exept.de>
parents:
12554
diff
changeset
|
5195 |
|
10788 | 5196 |
self compiled_classesDo:[:cls | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5197 |
cls allSuperclassesDo:[:eachSuperClass | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5198 |
addPackage value:(eachSuperClass package) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5199 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5200 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5201 |
cls allPrivateClassesDo:[:eachPrivateClass | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5202 |
eachPrivateClass allSuperclassesDo:[:eachSuperClass | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5203 |
eachSuperClass isPrivate ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5204 |
addPackage value:(eachSuperClass package) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5205 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5206 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5207 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5208 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5209 |
cls sharedPoolNames do:[:eachPoolName | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5210 |
|eachPoolClass| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5211 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5212 |
eachPoolClass := Smalltalk classNamed:eachPoolName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5213 |
eachPoolClass isNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5214 |
Transcript showCR:('Warning: missing pool: %1 (required by %2)' bindWith:eachPoolName with:cls name) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5215 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5216 |
eachPoolClass withAllSuperclassesDo:[:eachPoolSuperClass | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5217 |
addPackage value:(eachPoolSuperClass package) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5218 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5219 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5220 |
]. |
9883
c641767d1483
include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents:
9880
diff
changeset
|
5221 |
]. |
c641767d1483
include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents:
9880
diff
changeset
|
5222 |
|
c641767d1483
include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents:
9880
diff
changeset
|
5223 |
self extensionMethodNames pairWiseDo:[:className :selector | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5224 |
|cls| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5225 |
((cls := Smalltalk classNamed:className) notNil and:[cls isLoaded]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5226 |
cls withAllSuperclassesDo:[:eachSuperClass | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5227 |
addPackage value:(eachSuperClass package) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5228 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5229 |
] |
9883
c641767d1483
include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents:
9880
diff
changeset
|
5230 |
]. |
c641767d1483
include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents:
9880
diff
changeset
|
5231 |
^ requiredPackages |
9627 | 5232 |
|
9880 | 5233 |
" |
13419 | 5234 |
stx_libtool searchForProjectsWhichProvideHeaderFiles |
9880 | 5235 |
" |
9627 | 5236 |
|
10251 | 5237 |
"Created: / 07-12-2006 / 17:46:38 / cg" |
13216 | 5238 |
"Modified: / 18-01-2011 / 17:58:33 / cg" |
9664 | 5239 |
! |
5240 |
||
9667 | 5241 |
searchForSiblingProjects |
10132 | 5242 |
"answer all the packages (package names) having the my parent package" |
5243 |
||
9667 | 5244 |
|myPackage myParentPackage| |
5245 |
||
5246 |
myPackage := self package asPackageId. |
|
5247 |
myParentPackage := myPackage parentPackage. |
|
5248 |
myParentPackage isNil ifTrue:[^ #() ]. |
|
5249 |
||
13419 | 5250 |
^ Smalltalk allProjectIDs |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5251 |
select:[:projectID | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5252 |
|thisPackage| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5253 |
thisPackage := projectID asPackageId. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5254 |
(thisPackage parentPackage = myParentPackage) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5255 |
and:[ thisPackage ~= myPackage ]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5256 |
] |
9667 | 5257 |
|
5258 |
" |
|
5259 |
self searchForSiblingProjects |
|
5260 |
bosch_dapasx_Application searchForSiblingProjects |
|
5261 |
stx_goodies_refactoryBrowser_changes searchForSiblingProjects |
|
5262 |
" |
|
5263 |
||
5264 |
"Modified: / 07-08-2006 / 21:56:25 / fm" |
|
5265 |
"Created: / 23-08-2006 / 15:06:12 / cg" |
|
5266 |
! |
|
5267 |
||
9664 | 5268 |
searchForSubProjects |
10132 | 5269 |
"answer all packages (package names), that are my subProjects" |
5270 |
||
9664 | 5271 |
|myPackage| |
5272 |
||
5273 |
myPackage := self package. |
|
13419 | 5274 |
^ Smalltalk allProjectIDs |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5275 |
select:[:projectID | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5276 |
projectID ~= PackageId noProjectID |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5277 |
and:[ (projectID asPackageId parentPackage) = myPackage ]]. |
13419 | 5278 |
|
5279 |
" |
|
5280 |
self searchForSubProjects |
|
9664 | 5281 |
bosch_dapasx_Application searchForSubProjects |
5282 |
stx_goodies_refactoryBrowser_changes searchForSubProjects |
|
5283 |
" |
|
5284 |
||
5285 |
"Created: / 07-08-2006 / 20:42:39 / fm" |
|
5286 |
"Modified: / 07-08-2006 / 21:56:25 / fm" |
|
10215 | 5287 |
"Modified: / 05-12-2006 / 18:04:27 / cg" |
9664 | 5288 |
! |
5289 |
||
5290 |
setupForType:typeOrNil |
|
9714 | 5291 |
typeOrNil = GUIApplicationType ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5292 |
self compile: |
12425 | 5293 |
'isGUIApplication |
5294 |
"return true, if this is a GUI application. |
|
5295 |
(these need more libraries and use a different startup procedure)" |
|
5296 |
||
5297 |
^ true |
|
5298 |
' |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5299 |
categorized:'description'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5300 |
self superclass: ApplicationDefinition. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5301 |
^ self |
9664 | 5302 |
]. |
12856
1651184275a2
comment/format in: #setupForType:
Claus Gittinger <cg@exept.de>
parents:
12804
diff
changeset
|
5303 |
|
9714 | 5304 |
typeOrNil = NonGUIApplicationType ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5305 |
self compile: |
12425 | 5306 |
'isGUIApplication |
5307 |
"return true, if this is a GUI application. |
|
5308 |
(these need more libraries and use a different startup procedure)" |
|
5309 |
||
5310 |
^ false |
|
5311 |
' |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5312 |
categorized:'description'. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5313 |
self superclass: ApplicationDefinition. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5314 |
^ self |
13419 | 5315 |
]. |
12856
1651184275a2
comment/format in: #setupForType:
Claus Gittinger <cg@exept.de>
parents:
12804
diff
changeset
|
5316 |
|
12349 | 5317 |
self theMetaclass removeSelector: #isGUIApplication. |
12353 | 5318 |
self superclass: LibraryDefinition. |
9664 | 5319 |
^ self. |
5320 |
||
5321 |
"Created: / 23-08-2006 / 14:26:10 / cg" |
|
13411 | 5322 |
! |
5323 |
||
5324 |
shouldExcludeTest: test |
|
5325 |
||
5326 |
self excludedFromTestSuite do: |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5327 |
[:spec| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5328 |
(spec isSymbol and:[test class name == spec]) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5329 |
ifTrue:[^true]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5330 |
(spec isArray and:[test class name == spec first and:[test selector == spec second]]) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5331 |
ifTrue:[^true]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5332 |
]. |
13411 | 5333 |
^false |
5334 |
||
5335 |
"Created: / 03-06-2011 / 17:01:14 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
9536 | 5336 |
! ! |
5337 |
||
12210 | 5338 |
!ProjectDefinition class methodsFor:'private-extension handling'! |
5339 |
||
5340 |
hasSavedOverwrittenMethods |
|
5341 |
"true, if any of my methods was overwritten by another loaded package. |
|
5342 |
These methods are now in my safe" |
|
5343 |
||
12208
0b65ddcb68f2
added: #hasSafedOverwrittenMethods
Michael Beyl <mb@exept.de>
parents:
12202
diff
changeset
|
5344 |
^ safeForOverwrittenMethods notEmptyOrNil |
0b65ddcb68f2
added: #hasSafedOverwrittenMethods
Michael Beyl <mb@exept.de>
parents:
12202
diff
changeset
|
5345 |
! |
0b65ddcb68f2
added: #hasSafedOverwrittenMethods
Michael Beyl <mb@exept.de>
parents:
12202
diff
changeset
|
5346 |
|
12213
73371949b807
overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents:
12210
diff
changeset
|
5347 |
methodOverwrittenBy:aMethod |
73371949b807
overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents:
12210
diff
changeset
|
5348 |
"return the (hidden) original method, which was located in another package |
73371949b807
overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents:
12210
diff
changeset
|
5349 |
and which got overwritten by one of my extension methods. Nil if there is none." |
73371949b807
overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents:
12210
diff
changeset
|
5350 |
|
73371949b807
overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents:
12210
diff
changeset
|
5351 |
|mclass selector oldPackage| |
73371949b807
overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents:
12210
diff
changeset
|
5352 |
|
12218
a3662ecd1438
changed: #methodOverwrittenBy:
Claus Gittinger <cg@exept.de>
parents:
12213
diff
changeset
|
5353 |
extensionOverwriteInfo isNil ifTrue:[^ nil]. |
a3662ecd1438
changed: #methodOverwrittenBy:
Claus Gittinger <cg@exept.de>
parents:
12213
diff
changeset
|
5354 |
|
12213
73371949b807
overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents:
12210
diff
changeset
|
5355 |
mclass := aMethod mclass. |
73371949b807
overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents:
12210
diff
changeset
|
5356 |
selector := aMethod selector. |
73371949b807
overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents:
12210
diff
changeset
|
5357 |
oldPackage := extensionOverwriteInfo at:(mclass name,'>>',selector) ifAbsent:nil. |
73371949b807
overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents:
12210
diff
changeset
|
5358 |
oldPackage isNil ifTrue:[^ nil]. |
13419 | 5359 |
^ oldPackage asPackageId projectDefinitionClass |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5360 |
savedOverwrittenMethodForClass:mclass selector:selector. |
12213
73371949b807
overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents:
12210
diff
changeset
|
5361 |
! |
73371949b807
overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents:
12210
diff
changeset
|
5362 |
|
12210 | 5363 |
rememberOverwrittenExtensionMethods |
5364 |
"before loading, tell other packages to keep a safe reference to any method |
|
5365 |
which gets overloaded by me, and also remember here, whome I have overloaded. |
|
5366 |
This allows for two things: |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5367 |
a) correct fileout of the other base-package (for example, when checking in any of its class) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5368 |
b) correct unloading of myself" |
12210 | 5369 |
|
5370 |
self extensionMethodNames pairWiseDo:[:className :selector | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5371 |
|class oldMethod oldPackage defClass| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5372 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5373 |
class := Smalltalk classNamed:className. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5374 |
class notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5375 |
oldMethod := class compiledMethodAt:selector. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5376 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5377 |
oldMethod notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5378 |
oldPackage := oldMethod package. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5379 |
oldPackage ~= PackageId noProjectID ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5380 |
defClass := oldPackage asPackageId projectDefinitionClass. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5381 |
defClass notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5382 |
defClass rememberOverwrittenMethod:oldMethod inClass:class. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5383 |
extensionOverwriteInfo isNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5384 |
extensionOverwriteInfo := Dictionary new. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5385 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5386 |
extensionOverwriteInfo at:(className,'>>',selector) put:oldPackage. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5387 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5388 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5389 |
]. |
12210 | 5390 |
]. |
5391 |
! |
|
5392 |
||
5393 |
rememberOverwrittenMethod:oldMethod inClass:aClass |
|
5394 |
"invoked from another projectDefinition, when that package is about to be loaded |
|
13419 | 5395 |
and about to overwrite one of my methods. |
5396 |
I will save the method locally, to allow for correct fileout of this class/project or |
|
12210 | 5397 |
to correctly reestablish my methods when the other package is unloaded later." |
5398 |
||
5399 |
|thisIsOneOfMyMethods selector| |
|
5400 |
||
5401 |
selector := oldMethod selector. |
|
5402 |
||
12293
983b9555f6e8
changed: #rememberOverwrittenMethod:inClass:
Claus Gittinger <cg@exept.de>
parents:
12286
diff
changeset
|
5403 |
thisIsOneOfMyMethods := (self classNames includes:aClass theNonMetaclass name) |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5404 |
or:[ aClass isPrivate and:[ self classNames includes: aClass topOwningClass theNonMetaclass name ]]. |
12210 | 5405 |
thisIsOneOfMyMethods ifFalse:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5406 |
self extensionMethodNames pairWiseDo:[:extClassName :extSelector | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5407 |
extClassName = aClass name ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5408 |
selector = extSelector ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5409 |
thisIsOneOfMyMethods := true |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5410 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5411 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5412 |
] |
12210 | 5413 |
]. |
5414 |
thisIsOneOfMyMethods ifFalse:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5415 |
self error:'oops - this is not one of my methods' mayProceed:true. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5416 |
^ self |
12210 | 5417 |
]. |
5418 |
||
5419 |
safeForOverwrittenMethods isNil ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5420 |
safeForOverwrittenMethods := Dictionary new. |
12210 | 5421 |
]. |
5422 |
safeForOverwrittenMethods at:(aClass name -> selector) put:oldMethod. |
|
12213
73371949b807
overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents:
12210
diff
changeset
|
5423 |
! |
73371949b807
overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents:
12210
diff
changeset
|
5424 |
|
12624 | 5425 |
restoreOverwrittenExtensionMethods |
5426 |
"after unloading, tell other packages to restore any safed reference to any method |
|
5427 |
which got overloaded by me." |
|
5428 |
||
5429 |
self extensionMethodNames pairWiseDo:[:className :selector | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5430 |
|class oldMethod oldPackage| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5431 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5432 |
oldPackage := extensionOverwriteInfo at:(className,'>>',selector). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5433 |
oldPackage notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5434 |
class := Smalltalk classNamed:className. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5435 |
class notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5436 |
oldMethod := oldPackage savedOverwrittenMethodForClass:class selector:selector. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5437 |
oldMethod notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5438 |
self breakPoint:#cg. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5439 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5440 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5441 |
]. |
12624 | 5442 |
]. |
5443 |
! |
|
5444 |
||
12213
73371949b807
overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents:
12210
diff
changeset
|
5445 |
savedOverwrittenMethodForClass:aClass selector:aSelector |
73371949b807
overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents:
12210
diff
changeset
|
5446 |
"return one of my saved original methods" |
73371949b807
overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents:
12210
diff
changeset
|
5447 |
|
13692
2dffef08a4ac
changed: #savedOverwrittenMethodForClass:selector:
Stefan Vogel <sv@exept.de>
parents:
13689
diff
changeset
|
5448 |
safeForOverwrittenMethods isNil ifTrue:[^ nil]. |
12274 | 5449 |
^ safeForOverwrittenMethods at:(aClass name,'>>',aSelector) ifAbsent:nil |
12210 | 5450 |
! ! |
5451 |
||
5452 |
!ProjectDefinition class methodsFor:'private-loading'! |
|
5453 |
||
12262
24861bbf25fc
added: #checkPrerequisitesForLoading
Claus Gittinger <cg@exept.de>
parents:
12251
diff
changeset
|
5454 |
checkPrerequisitesForLoading |
12264 | 5455 |
|classesAlreadyWarned| |
5456 |
||
5457 |
classesAlreadyWarned := Set new. |
|
5458 |
||
13419 | 5459 |
self extensionMethodNames |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5460 |
pairWiseDo:[:className :selector | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5461 |
|class | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5462 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5463 |
class := Smalltalk classNamed:className. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5464 |
class isNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5465 |
(classesAlreadyWarned includes:className) ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5466 |
self error:'missing class for extension: ', className mayProceed:true. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5467 |
classesAlreadyWarned add:className. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5468 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5469 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5470 |
] |
12263
c6d50824fbba
comment/format in: #checkPrerequisitesForLoading
Claus Gittinger <cg@exept.de>
parents:
12262
diff
changeset
|
5471 |
|
c6d50824fbba
comment/format in: #checkPrerequisitesForLoading
Claus Gittinger <cg@exept.de>
parents:
12262
diff
changeset
|
5472 |
"/ todo: more needed here... |
12731 | 5473 |
|
5474 |
" |
|
5475 |
stx_libjavascript checkPrerequisitesForLoading |
|
5476 |
" |
|
12262
24861bbf25fc
added: #checkPrerequisitesForLoading
Claus Gittinger <cg@exept.de>
parents:
12251
diff
changeset
|
5477 |
! |
24861bbf25fc
added: #checkPrerequisitesForLoading
Claus Gittinger <cg@exept.de>
parents:
12251
diff
changeset
|
5478 |
|
12294
c46be62dee24
when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents:
12293
diff
changeset
|
5479 |
extensionOverwriteInfo |
c46be62dee24
when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents:
12293
diff
changeset
|
5480 |
^ extensionOverwriteInfo |
c46be62dee24
when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents:
12293
diff
changeset
|
5481 |
! |
c46be62dee24
when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents:
12293
diff
changeset
|
5482 |
|
c46be62dee24
when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents:
12293
diff
changeset
|
5483 |
fetchSlotsFrom:myFirstIncarnation |
c46be62dee24
when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents:
12293
diff
changeset
|
5484 |
"this is invoked in a just loaded instance of myself, |
c46be62dee24
when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents:
12293
diff
changeset
|
5485 |
to fetch the safe and extensionInfo from my first incarnation" |
c46be62dee24
when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents:
12293
diff
changeset
|
5486 |
|
c46be62dee24
when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents:
12293
diff
changeset
|
5487 |
safeForOverwrittenMethods := myFirstIncarnation safeForOverwrittenMethods. |
c46be62dee24
when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents:
12293
diff
changeset
|
5488 |
extensionOverwriteInfo := myFirstIncarnation extensionOverwriteInfo. |
c46be62dee24
when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents:
12293
diff
changeset
|
5489 |
! |
c46be62dee24
when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents:
12293
diff
changeset
|
5490 |
|
13614
5606bfa8cbec
added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13610
diff
changeset
|
5491 |
loadAllAutoloadedClasses |
5606bfa8cbec
added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13610
diff
changeset
|
5492 |
self allClasses do:[:cls | cls autoload] |
5606bfa8cbec
added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13610
diff
changeset
|
5493 |
|
5606bfa8cbec
added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13610
diff
changeset
|
5494 |
"Created: / 21-08-2011 / 17:24:13 / cg" |
5606bfa8cbec
added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13610
diff
changeset
|
5495 |
! |
5606bfa8cbec
added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13610
diff
changeset
|
5496 |
|
10399
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5497 |
loadAllClassesAsAutoloaded:asAutoloaded |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5498 |
"load (fileIn) classes that should be present - |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5499 |
install as autoloaded classes marked to be autoloaded. |
10401 | 5500 |
If asAutoloaded == true, all classes will be installed as autoloaded, even if not marked. |
5501 |
||
5502 |
Answer true, if classes have been loaded" |
|
12028 | 5503 |
|
13411 | 5504 |
^self loadAllClassesAsAutoloaded:asAutoloaded languages: ProgrammingLanguage all |
5505 |
||
5506 |
"Created: / 17-08-2006 / 01:01:14 / cg" |
|
5507 |
"Modified: / 26-10-2006 / 12:30:01 / cg" |
|
5508 |
"Modified: / 16-08-2009 / 13:31:40 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
5509 |
"Modified: / 19-06-2010 / 11:37:47 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
5510 |
! |
|
5511 |
||
5512 |
loadAllClassesAsAutoloaded:asAutoloaded languages: langs |
|
5513 |
"load (fileIn) classes in given languages that should be present - |
|
5514 |
install as autoloaded classes marked to be autoloaded. |
|
5515 |
If asAutoloaded == true, all classes will be installed as autoloaded, even if not marked. |
|
5516 |
langs should be collection of ProgrammingLanguage available in the system. |
|
5517 |
||
5518 |
Answer true, if classes have been loaded" |
|
5519 |
||
5520 |
|classNamesToLoad classNamesToAutoload classNamesToLangs hasClassesToLoad loadedClasses platformName |
|
10399
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5521 |
classesWhichFailedToLoad| |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5522 |
|
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5523 |
platformName := OperatingSystem platformName. |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5524 |
classNamesToLoad := OrderedCollection new. |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5525 |
classNamesToAutoload := OrderedCollection new. |
13411 | 5526 |
classNamesToLangs := Dictionary new. |
10399
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5527 |
|
12315
71599fb91dcf
comment/format in: #packageDirectory
Claus Gittinger <cg@exept.de>
parents:
12314
diff
changeset
|
5528 |
hasClassesToLoad := false. |
13419 | 5529 |
self classNamesAndAttributesDo:[:eachClassname :eachAttributes | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5530 |
|eachClassnameSym isAutoload clsLangAttr clsLang cls | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5531 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5532 |
eachClassnameSym := eachClassname asSymbol. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5533 |
isAutoload := asAutoloaded or:[eachAttributes includes:#autoload]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5534 |
clsLangAttr := eachAttributes detect:[:a|a isArray and: [a size == 2 and:[a first == #lang]]] ifNone:[nil]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5535 |
clsLang := clsLangAttr |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5536 |
ifNil:[SmalltalkLanguage instance] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5537 |
ifNotNil:[ProgrammingLanguage named: clsLangAttr second ifNone:[nil]]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5538 |
classNamesToLangs at: eachClassname put: clsLang. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5539 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5540 |
"no need to (re-)load an existing class, but install if should be loaded" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5541 |
cls := Smalltalk loadedClassNamed:eachClassnameSym. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5542 |
((cls isNil or:[cls isLoaded not and:[isAutoload not]]) and:[clsLang notNil and:[langs includes: clsLang]]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5543 |
(eachAttributes isEmpty |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5544 |
or:[(eachAttributes size == 1 and:[isAutoload]) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5545 |
or:[(eachAttributes includes:platformName) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5546 |
or:[eachAttributes contains:[:a|a isArray]]]]) "/FIXME: Hack." |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5547 |
ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5548 |
hasClassesToLoad := true. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5549 |
isAutoload ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5550 |
classNamesToAutoload add:eachClassnameSym. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5551 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5552 |
classNamesToLoad add:eachClassnameSym. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5553 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5554 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5555 |
]. |
10399
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5556 |
]. |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5557 |
|
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5558 |
hasClassesToLoad ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5559 |
loadedClasses := OrderedCollection new. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5560 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5561 |
self packageDirectory isNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5562 |
classNamesToLoad notEmpty ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5563 |
"required classes are missing. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5564 |
Autoloaded classes are considered as optional..." |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5565 |
self |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5566 |
error:(self name,'[error] cannot install because packageDirectory is unknown for missing classes: ', classNamesToLoad printString) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5567 |
mayProceed:true. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5568 |
^ false. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5569 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5570 |
(self name,'[info] cannot install autoloaded classes because packageDirectory is unknown') infoPrintCR. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5571 |
^ true. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5572 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5573 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5574 |
"we need the abbreviations, since sometimes there is no 1-to-1 mapping |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5575 |
of class name to file name" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5576 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5577 |
Smalltalk recursiveReadAllAbbreviationsFrom:self packageDirectory maxLevels:1. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5578 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5579 |
"install autoloaded classes first, |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5580 |
some others may depend on them" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5581 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5582 |
classNamesToAutoload withIndexDo:[:eachClassName :index| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5583 |
ActivityNotification |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5584 |
raiseRequestWith: ((100 / classNamesToAutoload size ) * index) rounded |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5585 |
errorString: 'Autoloading class ', eachClassName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5586 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5587 |
self loadClass: eachClassName asAutoloaded: true language: (classNamesToLangs at: eachClassName) . |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5588 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5589 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5590 |
classesWhichFailedToLoad := OrderedCollection new. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5591 |
classNamesToLoad notEmpty ifTrue:[ |
14021 | 5592 |
Verbose ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5593 |
Transcript showCR:(' %1: filing in missing classes (%2) individually...' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5594 |
bindWith:self name with:classNamesToLoad size). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5595 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5596 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5597 |
classNamesToLoad withIndexDo:[:eachClassName :index| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5598 |
|cls| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5599 |
ActivityNotification |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5600 |
raiseRequestWith: ((100 / classNamesToLoad size) * index) rounded |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5601 |
errorString: 'Loading class ', eachClassName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5602 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5603 |
Error handle:[:ex | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5604 |
"maybe, fileIn failed, because the load order is wrong. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5605 |
Work around this by installing the class as autoloaded and |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5606 |
loading it" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5607 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5608 |
classesWhichFailedToLoad add:eachClassName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5609 |
self loadClass: eachClassName asAutoloaded: true language: (classNamesToLangs at: eachClassName). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5610 |
] do:[ |
14021 | 5611 |
Verbose ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5612 |
Transcript showCR:(' %1: filing in %2...' bindWith:self name with:eachClassName). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5613 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5614 |
cls := self loadClass: eachClassName asAutoloaded: false language: (classNamesToLangs at: eachClassName). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5615 |
cls notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5616 |
loadedClasses add:cls |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5617 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5618 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5619 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5620 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5621 |
classesWhichFailedToLoad do:[:eachClassName | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5622 |
(Smalltalk at:eachClassName) autoload. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5623 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5624 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5625 |
loadedClasses do:[:eachLoadedClass | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5626 |
"do not initialize, if initialize method is inherited" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5627 |
(eachLoadedClass theMetaclass includesSelector:#initialize) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5628 |
eachLoadedClass initialize |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5629 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5630 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5631 |
^ true. |
10399
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5632 |
]. |
10401 | 5633 |
^ false. |
10399
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5634 |
|
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5635 |
"Modified: / 26-10-2006 / 12:30:01 / cg" |
12028 | 5636 |
"Modified: / 16-08-2009 / 13:31:40 / Jan Vrany <vranyj1@fel.cvut.cz>" |
13411 | 5637 |
"Created: / 19-06-2010 / 11:35:49 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
5638 |
"Modified: / 19-06-2010 / 15:06:20 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
5639 |
! |
|
5640 |
||
5641 |
loadClass: className asAutoloaded: asAutoloaded language: lang |
|
13592 | 5642 |
| packageDir classFile entry category numClassInstVars cls| |
5643 |
||
5644 |
"Handle smalltalk classes specially to provide backward compatibility" |
|
13411 | 5645 |
lang isSmalltalk ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5646 |
entry := self abbrevs at: className ifAbsent:[nil]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5647 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5648 |
asAutoloaded ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5649 |
category := entry isNil ifTrue:[#autoloaded] ifFalse:[entry category]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5650 |
numClassInstVars := entry isNil ifTrue:[0] ifFalse:[entry numClassInstVars]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5651 |
cls := Smalltalk |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5652 |
installAutoloadedClassNamed: className |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5653 |
category: category |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5654 |
package: self package |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5655 |
revision: nil |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5656 |
numClassInstVars:numClassInstVars. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5657 |
entry notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5658 |
cls setClassFilename:(entry fileName,'.st'). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5659 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5660 |
^ cls. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5661 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5662 |
^ Smalltalk |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5663 |
fileInClass:className |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5664 |
package:self package |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5665 |
initialize:false |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5666 |
lazy:false |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5667 |
silent:true |
13411 | 5668 |
]. |
5669 |
||
5670 |
"For non-smalltalk language do" |
|
5671 |
asAutoloaded ifTrue:[^self error:'Only Smalltalk classes may be autoloaded (yet)']. |
|
5672 |
||
5673 |
packageDir := self packageDirectory asFilename. |
|
5674 |
classFile := packageDir / ((Smalltalk fileNameForClass: className) , '.' , lang sourceFileSuffix). |
|
5675 |
classFile exists ifFalse:[^nil]. |
|
5676 |
lang fileIn: classFile. |
|
5677 |
^nil "FIXME: should return the class" |
|
5678 |
||
5679 |
"Created: / 19-06-2010 / 09:11:41 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
5680 |
"Modified: / 06-03-2011 / 18:29:08 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
13592 | 5681 |
"Modified: / 18-08-2011 / 14:22:15 / cg" |
10399
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5682 |
! |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5683 |
|
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5684 |
loadClassLibrary |
10430
fc34b59eca00
Don not try to load a class library already linked to the executable
Stefan Vogel <sv@exept.de>
parents:
10426
diff
changeset
|
5685 |
"try to load a binary class library |
fc34b59eca00
Don not try to load a class library already linked to the executable
Stefan Vogel <sv@exept.de>
parents:
10426
diff
changeset
|
5686 |
Return true if ok, false if not." |
fc34b59eca00
Don not try to load a class library already linked to the executable
Stefan Vogel <sv@exept.de>
parents:
10426
diff
changeset
|
5687 |
|
12295 | 5688 |
|libraryName| |
10430
fc34b59eca00
Don not try to load a class library already linked to the executable
Stefan Vogel <sv@exept.de>
parents:
10426
diff
changeset
|
5689 |
|
fc34b59eca00
Don not try to load a class library already linked to the executable
Stefan Vogel <sv@exept.de>
parents:
10426
diff
changeset
|
5690 |
libraryName := self libraryName. |
fc34b59eca00
Don not try to load a class library already linked to the executable
Stefan Vogel <sv@exept.de>
parents:
10426
diff
changeset
|
5691 |
|
fc34b59eca00
Don not try to load a class library already linked to the executable
Stefan Vogel <sv@exept.de>
parents:
10426
diff
changeset
|
5692 |
(Smalltalk isClassLibraryLoaded:libraryName) ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5693 |
"already loaded" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5694 |
^ true |
13419 | 5695 |
]. |
14021 | 5696 |
Verbose ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5697 |
Transcript showCR:(' %1: loading classLibrary...' bindWith:self name). |
13419 | 5698 |
]. |
12743 | 5699 |
self activityNotification:'Loading classLibrary'. |
5700 |
||
12295 | 5701 |
^ Smalltalk fileInClassLibrary:libraryName inPackage:self package. |
10399
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5702 |
! |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5703 |
|
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5704 |
loadExtensions |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5705 |
"load extension methods - do not load if they are already present" |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5706 |
|
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5707 |
self hasAllExtensionsLoaded ifFalse:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5708 |
self breakPoint:#cg. |
14021 | 5709 |
Verbose ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5710 |
Transcript showCR:(' %1: filing in extensions...' bindWith:self name). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5711 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5712 |
Smalltalk loadExtensionsForPackage:self package. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5713 |
^ true. |
10399
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5714 |
]. |
10401 | 5715 |
^ false. |
10399
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5716 |
|
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5717 |
"Created: / 17-08-2006 / 00:21:39 / cg" |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5718 |
! |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5719 |
|
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5720 |
loadPackages:aListOfPackages asAutoloaded:asAutoloaded |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5721 |
"load some packages (at least the projectDefinitions and their extensions). |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5722 |
If asAutoloaded == true, classes will be only installed as autoloaded." |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5723 |
|
13166
aa93e348e5d3
changed: #loadPackages:asAutoloaded:
Claus Gittinger <cg@exept.de>
parents:
13154
diff
changeset
|
5724 |
|packagesToLoad packagesBefore| |
aa93e348e5d3
changed: #loadPackages:asAutoloaded:
Claus Gittinger <cg@exept.de>
parents:
13154
diff
changeset
|
5725 |
|
13419 | 5726 |
packagesToLoad := aListOfPackages |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5727 |
reject:[:packageID | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5728 |
|cls| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5729 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5730 |
cls := ProjectDefinition definitionClassForPackage:packageID. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5731 |
cls notNil and:[cls projectIsLoaded] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5732 |
]. |
13166
aa93e348e5d3
changed: #loadPackages:asAutoloaded:
Claus Gittinger <cg@exept.de>
parents:
13154
diff
changeset
|
5733 |
packagesToLoad isEmpty ifTrue:[^ self]. |
12558 | 5734 |
|
5735 |
packagesBefore := PackagesBeingLoaded copy. |
|
5736 |
PackagesBeingLoaded isNil ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5737 |
PackagesBeingLoaded := Set new |
12558 | 5738 |
]. |
5739 |
[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5740 |
Class withoutUpdatingChangesDo:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5741 |
packagesToLoad do:[:aPackage | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5742 |
(PackagesBeingLoaded includes:aPackage) ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5743 |
PackagesBeingLoaded add:aPackage. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5744 |
Smalltalk loadPackage:aPackage asAutoloaded:asAutoloaded. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5745 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5746 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5747 |
]. |
12558 | 5748 |
] ensure:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5749 |
PackagesBeingLoaded := packagesBefore. |
10399
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5750 |
]. |
13166
aa93e348e5d3
changed: #loadPackages:asAutoloaded:
Claus Gittinger <cg@exept.de>
parents:
13154
diff
changeset
|
5751 |
|
13167 | 5752 |
"Modified: / 09-12-2010 / 12:36:17 / cg" |
10399
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5753 |
! |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5754 |
|
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5755 |
loadPreRequisitesAsAutoloaded:asAutoloaded |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5756 |
"load other packages (at least the projectDefinitions and their extensions)" |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5757 |
|
12743 | 5758 |
|prereq| |
5759 |
||
5760 |
prereq := self effectivePreRequisites. |
|
5761 |
prereq notEmptyOrNil ifTrue:[ |
|
14021 | 5762 |
Verbose ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5763 |
Transcript showCR:(' %1 loading prerequisites...' bindWith:self name). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5764 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5765 |
self loadPackages:prereq asAutoloaded:asAutoloaded |
12743 | 5766 |
]. |
10399
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5767 |
! |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5768 |
|
12596 | 5769 |
loadSubProjects |
5770 |
"load other packages (at least the projectDefinitions and their extensions)" |
|
5771 |
||
5772 |
self loadSubProjectsAsAutoloaded:false. |
|
5773 |
self subProjects do:[:p | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5774 |
|subDef| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5775 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5776 |
subDef := self definitionClassForPackage:p. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5777 |
subDef notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5778 |
subDef loadSubProjects |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5779 |
]. |
12596 | 5780 |
]. |
5781 |
! |
|
5782 |
||
10399
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5783 |
loadSubProjectsAsAutoloaded:asAutoloaded |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5784 |
"load other packages (at least the projectDefinitions and their extensions)" |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5785 |
|
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5786 |
self loadPackages:(self subProjects) asAutoloaded:asAutoloaded |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5787 |
|
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5788 |
"Modified: / 25-10-2006 / 17:51:58 / cg" |
10434
25f76184bf81
project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents:
10433
diff
changeset
|
5789 |
! |
25f76184bf81
project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents:
10433
diff
changeset
|
5790 |
|
13411 | 5791 |
old_loadAllClassesAsAutoloaded:asAutoloaded |
5792 |
"load (fileIn) classes that should be present - |
|
5793 |
install as autoloaded classes marked to be autoloaded. |
|
5794 |
If asAutoloaded == true, all classes will be installed as autoloaded, even if not marked. |
|
5795 |
||
5796 |
Answer true, if classes have been loaded" |
|
5797 |
||
5798 |
|classNamesToLoad classNamesToAutoload hasClassesToLoad loadedClasses platformName |
|
5799 |
classesWhichFailedToLoad| |
|
5800 |
||
5801 |
platformName := OperatingSystem platformName. |
|
5802 |
classNamesToLoad := OrderedCollection new. |
|
5803 |
classNamesToAutoload := OrderedCollection new. |
|
5804 |
||
5805 |
hasClassesToLoad := false. |
|
13419 | 5806 |
self classNamesAndAttributesDo:[:eachClassname :eachAttributes | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5807 |
|eachClassnameSym isAutoload cls| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5808 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5809 |
eachClassnameSym := eachClassname asSymbol. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5810 |
isAutoload := asAutoloaded or:[eachAttributes includes:#autoload]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5811 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5812 |
"no need to (re-)load an existing class, but install if should be loaded" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5813 |
cls := Smalltalk loadedClassNamed:eachClassnameSym. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5814 |
(cls isNil or:[cls isLoaded not and:[isAutoload not]]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5815 |
(eachAttributes isEmpty |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5816 |
or:[(eachAttributes size == 1 and:[isAutoload]) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5817 |
or:[eachAttributes includes:platformName]]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5818 |
hasClassesToLoad := true. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5819 |
isAutoload ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5820 |
classNamesToAutoload add:eachClassnameSym. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5821 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5822 |
classNamesToLoad add:eachClassnameSym. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5823 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5824 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5825 |
]. |
13411 | 5826 |
]. |
5827 |
||
5828 |
hasClassesToLoad ifTrue:[ |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5829 |
loadedClasses := OrderedCollection new. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5830 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5831 |
self packageDirectory isNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5832 |
self |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5833 |
error:(self name,'[error] cannot install because packageDirectory is unknown') |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5834 |
mayProceed:true. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5835 |
^ false. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5836 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5837 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5838 |
"we need the abbreviations, since sometimes there is no 1-to-1 mapping |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5839 |
of class name to file name" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5840 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5841 |
Smalltalk recursiveReadAllAbbreviationsFrom:self packageDirectory maxLevels:1. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5842 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5843 |
"install autoloaded classes first, |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5844 |
some others may depend on them" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5845 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5846 |
classNamesToAutoload withIndexDo:[:eachClassName :index| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5847 |
ActivityNotification |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5848 |
raiseRequestWith: ((100 / classNamesToAutoload size ) * index) rounded |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5849 |
errorString: 'Autoloading class ', eachClassName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5850 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5851 |
Smalltalk |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5852 |
installAutoloadedClassNamed:eachClassName |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5853 |
category:#autoloaded "FIXME" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5854 |
package:self package |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5855 |
revision:nil |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5856 |
numClassInstVars:0. "FIXME" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5857 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5858 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5859 |
classesWhichFailedToLoad := OrderedCollection new. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5860 |
classNamesToLoad notEmpty ifTrue:[ |
14021 | 5861 |
Verbose ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5862 |
Transcript showCR:(' %1: filing in missing classes (%2) individually...' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5863 |
bindWith:self name with:classNamesToLoad size). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5864 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5865 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5866 |
classNamesToLoad withIndexDo:[:eachClassName :index| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5867 |
|cls| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5868 |
ActivityNotification |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5869 |
raiseRequestWith: ((100 / classNamesToLoad size) * index) rounded |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5870 |
errorString: 'Loading class ', eachClassName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5871 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5872 |
Error handle:[:ex | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5873 |
"maybe, fileIn failed, because the load order is wrong. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5874 |
Work around this by installing the class as autoloaded and |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5875 |
loading it" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5876 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5877 |
classesWhichFailedToLoad add:eachClassName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5878 |
Smalltalk |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5879 |
installAutoloadedClassNamed:eachClassName |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5880 |
category:#autoloaded "FIXME" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5881 |
package:self package |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5882 |
revision:nil |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5883 |
numClassInstVars:0. "FIXME" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5884 |
] do:[ |
14021 | 5885 |
Verbose ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5886 |
Transcript showCR:(' %1: filing in %2...' bindWith:self name with:eachClassName). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5887 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5888 |
cls := Smalltalk |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5889 |
fileInClass:eachClassName |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5890 |
package:self package |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5891 |
initialize:false |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5892 |
lazy:false |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5893 |
silent:true. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5894 |
cls notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5895 |
loadedClasses add:cls |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5896 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5897 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5898 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5899 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5900 |
classesWhichFailedToLoad do:[:eachClassName | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5901 |
(Smalltalk at:eachClassName) autoload. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5902 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5903 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5904 |
loadedClasses do:[:eachLoadedClass | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5905 |
"do not initialize, if initialize method is inherited" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5906 |
(eachLoadedClass theMetaclass includesSelector:#initialize) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5907 |
eachLoadedClass initialize |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5908 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5909 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5910 |
^ true. |
13411 | 5911 |
]. |
5912 |
^ false. |
|
5913 |
||
5914 |
"Modified: / 26-10-2006 / 12:30:01 / cg" |
|
5915 |
"Modified: / 16-08-2009 / 13:31:40 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
5916 |
"Created: / 19-06-2010 / 11:36:06 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
5917 |
! |
|
5918 |
||
12294
c46be62dee24
when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents:
12293
diff
changeset
|
5919 |
safeForOverwrittenMethods |
c46be62dee24
when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents:
12293
diff
changeset
|
5920 |
^ safeForOverwrittenMethods |
c46be62dee24
when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents:
12293
diff
changeset
|
5921 |
! |
c46be62dee24
when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents:
12293
diff
changeset
|
5922 |
|
12624 | 5923 |
unloadAllClasses |
5924 |
Transcript showCR:'unloading not yet fully supported' |
|
5925 |
! |
|
5926 |
||
5927 |
unloadClassLibrary |
|
5928 |
Transcript showCR:'unloading not yet fully supported' |
|
5929 |
! |
|
5930 |
||
5931 |
unloadSubProjects |
|
5932 |
"unload other packages" |
|
5933 |
||
5934 |
self subProjects do:[:p | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5935 |
|subDef| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5936 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5937 |
subDef := self definitionClassForPackage:p. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5938 |
subDef notNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5939 |
subDef unloadSubProjects. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5940 |
subDef unloadPackage. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5941 |
]. |
12624 | 5942 |
]. |
5943 |
! |
|
5944 |
||
10434
25f76184bf81
project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents:
10433
diff
changeset
|
5945 |
update:anAspectSymbol with:argument from:changedObject |
25f76184bf81
project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents:
10433
diff
changeset
|
5946 |
"when any of my class methods is changed, we mark the project as unloaded. |
12926
620ef12f673c
comment/format in: #update:with:from:
Stefan Vogel <sv@exept.de>
parents:
12856
diff
changeset
|
5947 |
May be some more classes have to be loaded" |
10434
25f76184bf81
project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents:
10433
diff
changeset
|
5948 |
|
25f76184bf81
project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents:
10433
diff
changeset
|
5949 |
(changedObject == self class and:[anAspectSymbol == #methodDictionary]) ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5950 |
self projectIsLoaded:false. |
10434
25f76184bf81
project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents:
10433
diff
changeset
|
5951 |
] |
10399
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5952 |
! ! |
6c16947a05ca
Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents:
10397
diff
changeset
|
5953 |
|
11147
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
5954 |
!ProjectDefinition class methodsFor:'private-prerequisites'! |
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
5955 |
|
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
5956 |
addReferencesToClassesFromGlobalsIn:aSetOfClasses to:usedClassReasons |
12371 | 5957 |
"helper for searchForPreRequisites" |
5958 |
||
11147
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
5959 |
aSetOfClasses |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5960 |
do:[:aClass | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5961 |
self |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5962 |
addReferencesToClassesFromGlobalsInMethods: |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5963 |
(aClass theNonMetaclass methodDictionary values |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5964 |
select:[:m | m package = aClass package]) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5965 |
to:usedClassReasons. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5966 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5967 |
self |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5968 |
addReferencesToClassesFromGlobalsInMethods: |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5969 |
(aClass theMetaclass methodDictionary values |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5970 |
select:[:m | m package = aClass package]) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5971 |
to:usedClassReasons. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5972 |
]. |
11147
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
5973 |
|
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
5974 |
"Modified: / 10-10-2006 / 23:03:45 / cg" |
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
5975 |
! |
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
5976 |
|
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
5977 |
addReferencesToClassesFromGlobalsInMethods:someMethods to:usedClassReasons |
12371 | 5978 |
"helper for searchForPreRequisites" |
5979 |
||
11147
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
5980 |
someMethods do:[:method | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5981 |
|resources| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5982 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5983 |
resources := method resources. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5984 |
(resources isNil |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5985 |
or:[ ((resources includesKey:#'ignoreInPrerequisites') not |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5986 |
and:[(resources includesKey:#'example') not])]) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5987 |
ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5988 |
method usedGlobals |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5989 |
do:[:global | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5990 |
|globalsName usedClass| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5991 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5992 |
globalsName := global asSymbol. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5993 |
usedClass := Smalltalk at:globalsName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5994 |
(usedClass notNil and:[usedClass isClass and:[usedClass isNameSpace not]]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5995 |
usedClass name == globalsName ifTrue:[ "/ skip aliases |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5996 |
(usedClassReasons at:usedClass ifAbsentPut:[Set new]) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5997 |
add:(usedClass name, ' - referenced by ', method mclass name,'>>',method selector) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5998 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
5999 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6000 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6001 |
] |
11147
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6002 |
] |
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6003 |
|
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6004 |
"Created: / 10-10-2006 / 23:00:07 / cg" |
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6005 |
"Modified: / 30-05-2007 / 12:48:30 / cg" |
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6006 |
! |
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6007 |
|
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6008 |
searchForPreRequisites |
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6009 |
"answer a Dictionary where the keys are the prerequisite package for this package |
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6010 |
and the values are a Set of reasons, why each package is required" |
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6011 |
|
13635
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6012 |
^ self searchForPreRequisites:self package withSubProjects:true |
11147
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6013 |
|
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6014 |
" |
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6015 |
self searchForPreRequisites |
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6016 |
stx_libbasic3 searchForPreRequisites |
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6017 |
bosch_dapasx_Application searchForPreRequisites |
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6018 |
bosch_dapasx_pav_browser searchForPreRequisites |
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6019 |
" |
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6020 |
|
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6021 |
"Created: / 07-08-2006 / 20:42:39 / fm" |
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6022 |
"Modified: / 07-08-2006 / 21:56:25 / fm" |
13635
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6023 |
"Modified: / 06-09-2011 / 08:30:43 / cg" |
13411 | 6024 |
! |
6025 |
||
6026 |
searchForPreRequisites: packageId |
|
6027 |
"answer a Dictionary where the keys are the prerequisite package for this package |
|
6028 |
and the values are a Set of reasons, why each package is required" |
|
6029 |
||
13635
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6030 |
^ self searchForPreRequisites: packageId withSubProjects:false |
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6031 |
|
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6032 |
" |
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6033 |
self searchForPreRequisites |
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6034 |
self searchForPreRequisites:#'stx:libwidg3' |
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6035 |
bosch_dapasx_Application searchForPreRequisites |
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6036 |
bosch_dapasx_pav_browser searchForPreRequisites |
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6037 |
" |
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6038 |
|
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6039 |
"Modified: / 07-08-2006 / 21:56:25 / fm" |
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6040 |
"Created: / 17-11-2010 / 18:27:42 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6041 |
"Modified: / 06-09-2011 / 08:30:20 / cg" |
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6042 |
! |
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6043 |
|
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6044 |
searchForPreRequisites:packageId withSubProjects:withSubProjectsBoolean |
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6045 |
"answer a Dictionary where the keys are the prerequisite package for this package |
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6046 |
and the values are a Set of reasons, why each package is required" |
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6047 |
|
13411 | 6048 |
|requiredClasses requiredPackageReasons usedClassesWithReasons ignoredPackages| |
6049 |
||
6050 |
usedClassesWithReasons := Dictionary new. |
|
6051 |
||
6052 |
"my classes are required" |
|
6053 |
requiredClasses := (self searchForClassesWithProject: packageId) asSet. |
|
6054 |
||
13635
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6055 |
withSubProjectsBoolean ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6056 |
"my subproject's classes are required" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6057 |
self subProjects do:[:eachProjectName | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6058 |
requiredClasses addAll: (self searchForClassesWithProject:eachProjectName asSymbol) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6059 |
]. |
13635
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6060 |
]. |
13411 | 6061 |
|
6062 |
"all superclasses of my classes and my subProject's classes are required" |
|
13419 | 6063 |
requiredClasses do:[:cls | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6064 |
cls allSuperclassesDo:[:eachSuperclass | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6065 |
(usedClassesWithReasons at: eachSuperclass ifAbsentPut:[OrderedSet new]) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6066 |
add: (eachSuperclass name, ' - superclass of ', cls name). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6067 |
] |
13411 | 6068 |
]. |
6069 |
||
6070 |
"all classes referenced by my classes or my subproject's classes |
|
6071 |
are required. But: |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6072 |
only search for locals refered to by my methods (assuming that superclasses' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6073 |
prerequisites are specified in their package)." |
13411 | 6074 |
|
6075 |
self addReferencesToClassesFromGlobalsIn:requiredClasses to:usedClassesWithReasons. |
|
6076 |
self addReferencesToClassesFromGlobalsInMethods:(self searchForExtensionsWithProject:self package) to:usedClassesWithReasons. |
|
6077 |
||
13635
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6078 |
"all classes for which I define extensions are required" |
13637
d2ca7b303301
changed: #searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13636
diff
changeset
|
6079 |
self allExtensionClasses do:[:eachExtendedClass | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6080 |
(usedClassesWithReasons at:eachExtendedClass ifAbsentPut:[OrderedSet new]) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6081 |
add: (eachExtendedClass name, ' - extended'). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6082 |
eachExtendedClass allSuperclassesDo:[:eachSuperclass | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6083 |
(usedClassesWithReasons at: eachSuperclass ifAbsentPut:[OrderedSet new]) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6084 |
add: (eachSuperclass name, ' - superclass of extended ', eachExtendedClass name). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6085 |
] |
13635
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6086 |
]. |
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6087 |
|
13411 | 6088 |
"don't put classes from subProjects into the required list" |
6089 |
ignoredPackages := (self siblingsAreSubProjects |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6090 |
ifTrue:[ self searchForSiblingProjects ] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6091 |
ifFalse:[ self searchForSubProjects ]) asSet. |
13411 | 6092 |
|
6093 |
ignoredPackages add:self package. |
|
6094 |
ignoredPackages add:PackageId noProjectID. |
|
6095 |
||
6096 |
"now map classes to packages and collect the reasons" |
|
6097 |
requiredPackageReasons := Dictionary new. |
|
6098 |
usedClassesWithReasons keysAndValuesDo:[:usedClass :reasonsPerClass | |usedClassPackage| |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6099 |
usedClassPackage := usedClass package. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6100 |
(ignoredPackages includes:usedClassPackage) ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6101 |
(requiredPackageReasons at:usedClassPackage ifAbsentPut:[OrderedSet new]) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6102 |
addAll:reasonsPerClass. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6103 |
]. |
13411 | 6104 |
]. |
6105 |
||
6106 |
^ requiredPackageReasons |
|
6107 |
||
6108 |
" |
|
6109 |
self searchForPreRequisites |
|
6110 |
self searchForPreRequisites:#'stx:libwidg3' |
|
6111 |
bosch_dapasx_Application searchForPreRequisites |
|
6112 |
bosch_dapasx_pav_browser searchForPreRequisites |
|
6113 |
" |
|
6114 |
||
6115 |
"Modified: / 07-08-2006 / 21:56:25 / fm" |
|
6116 |
"Created: / 17-11-2010 / 18:27:42 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
13635
b07e00f94949
searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents:
13623
diff
changeset
|
6117 |
"Created: / 06-09-2011 / 08:29:37 / cg" |
11147
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6118 |
! ! |
ea616118c5b6
if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents:
11100
diff
changeset
|
6119 |
|
9585 | 6120 |
!ProjectDefinition class methodsFor:'queries'! |
6121 |
||
13419 | 6122 |
allClassNames |
12368 | 6123 |
^ self classNamesForWhich:[:nm :attr | true ]. |
6124 |
! |
|
6125 |
||
13559 | 6126 |
allClasses |
13950 | 6127 |
^ self allClassNames |
6128 |
collect:[:nm | |
|
6129 |
|cls| |
|
6130 |
||
6131 |
cls := Smalltalk classNamed:nm. |
|
6132 |
cls isNil ifTrue:[ |
|
6133 |
Transcript showCR:('%1: failed to autoload class %2' bindWith:self name with:nm) |
|
6134 |
]. |
|
6135 |
cls |
|
6136 |
] |
|
6137 |
thenSelect:[:cls | cls notNil ]. |
|
13559 | 6138 |
|
6139 |
"Created: / 06-08-2011 / 15:47:36 / cg" |
|
6140 |
! |
|
6141 |
||
13636 | 6142 |
allExtensionClasses |
6143 |
"answer the set of classes, which are extended by the package. |
|
6144 |
includes all superclasses of the extended classes" |
|
6145 |
||
6146 |
^ self extensionClassesWithSuperclasses:true |
|
6147 |
||
6148 |
" |
|
6149 |
stx_libboss allExtensionClasses |
|
6150 |
" |
|
6151 |
||
6152 |
"Created: / 06-09-2011 / 10:15:54 / cg" |
|
6153 |
! |
|
6154 |
||
13419 | 6155 |
autoloaded_classNames |
12368 | 6156 |
^ self classNamesForWhich:[:nm :attr | attr notEmptyOrNil and:[attr includes:#autoload]]. |
6157 |
||
6158 |
"Modified: / 07-08-2006 / 21:25:25 / fm" |
|
6159 |
"Created: / 30-08-2007 / 18:48:09 / cg" |
|
6160 |
! |
|
6161 |
||
13419 | 6162 |
classNames |
12368 | 6163 |
"answer an array containing all the class names of the project's classes" |
6164 |
||
6165 |
^ self classNamesAndAttributesAsSpecArray collect:[:entry | entry first]. |
|
6166 |
||
6167 |
" |
|
6168 |
stx_libhtml classNames |
|
6169 |
stx_libhtml classNamesAndAttributesAsSpecArray |
|
6170 |
" |
|
6171 |
! |
|
6172 |
||
13419 | 6173 |
classNamesForWhich:aBlock |
12368 | 6174 |
"a correponding method with real names is generated in my subclasses" |
6175 |
||
6176 |
|coll| |
|
6177 |
||
6178 |
coll := OrderedCollection new. |
|
6179 |
self classNamesAndAttributesDo:[:nm :attributes | |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6180 |
(aBlock value:nm value:attributes) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6181 |
coll add:nm. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6182 |
]. |
12368 | 6183 |
]. |
6184 |
^ coll |
|
6185 |
||
6186 |
"Created: / 07-08-2006 / 19:02:57 / fm" |
|
6187 |
"Modified: / 07-08-2006 / 21:25:25 / fm" |
|
6188 |
"Modified: / 17-08-2006 / 20:47:20 / cg" |
|
6189 |
! |
|
6190 |
||
6191 |
classes |
|
6192 |
"list my classes. |
|
6193 |
Project must be loaded - otherwise an error is reported here. |
|
6194 |
Use #classNames if you are only interested in the names" |
|
6195 |
||
13728 | 6196 |
^ self classNames collect:[:nm | Smalltalk at:nm ifAbsent:[self error:'Missing class: ',nm]] |
12368 | 6197 |
|
6198 |
" |
|
6199 |
stx_libbasic3 classNames |
|
6200 |
stx_libbasic3 classes |
|
6201 |
" |
|
13728 | 6202 |
|
6203 |
"Modified: / 27-09-2011 / 18:12:33 / cg" |
|
12368 | 6204 |
! |
6205 |
||
13419 | 6206 |
compiled_classNames |
12368 | 6207 |
^ self classNamesForWhich:[:nm :attr | attr isEmptyOrNil or:[(attr includes:#autoload) not]]. |
6208 |
||
6209 |
"Created: / 07-08-2006 / 19:02:57 / fm" |
|
6210 |
"Modified: / 07-08-2006 / 21:25:25 / fm" |
|
6211 |
"Modified: / 21-08-2006 / 18:48:31 / cg" |
|
6212 |
! |
|
6213 |
||
6214 |
compiled_classNamesForPlatform |
|
6215 |
"answer the classes to be compiled only for the current platformName" |
|
6216 |
||
6217 |
^ self compiled_classNamesForPlatform:OperatingSystem platformName |
|
6218 |
! |
|
6219 |
||
6220 |
compiled_classNamesForPlatform:platformName |
|
6221 |
"answer the classes to be compiled only for platformName |
|
6222 |
platformName is one of #unix, #win32 (OperatingSystem platformName)" |
|
6223 |
||
13419 | 6224 |
^ self |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6225 |
classNamesForWhich:[:nm :attr | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6226 |
(attr includes:#autoload) not and:[attr includes:platformName] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6227 |
]. |
12368 | 6228 |
|
6229 |
"Created: / 07-08-2006 / 19:02:57 / fm" |
|
6230 |
"Modified: / 07-08-2006 / 21:25:25 / fm" |
|
6231 |
"Modified: / 09-10-2006 / 13:30:08 / cg" |
|
6232 |
! |
|
6233 |
||
6234 |
compiled_classNames_common |
|
6235 |
"classes to be compiled for any platform" |
|
6236 |
||
13419 | 6237 |
^ self |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6238 |
classNamesForWhich:[:nm :attr | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6239 |
attr isEmptyOrNil |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6240 |
]. |
12368 | 6241 |
|
6242 |
"Created: / 18-08-2006 / 13:37:51 / cg" |
|
6243 |
! |
|
6244 |
||
6245 |
compiled_classNames_unix |
|
6246 |
"class, only to be compiled under unix" |
|
13419 | 6247 |
|
12368 | 6248 |
^ self compiled_classNamesForPlatform:#unix. |
6249 |
||
6250 |
"Created: / 18-08-2006 / 13:37:51 / cg" |
|
6251 |
! |
|
6252 |
||
6253 |
compiled_classNames_windows |
|
6254 |
"class, only to be compiled under windows" |
|
13419 | 6255 |
|
12368 | 6256 |
^ self compiled_classNamesForPlatform:#win32. |
6257 |
||
6258 |
"Created: / 18-08-2006 / 13:37:56 / cg" |
|
6259 |
! |
|
6260 |
||
13081 | 6261 |
extensionClasses |
6262 |
"answer the set of classes, which are extended by the package" |
|
6263 |
||
13636 | 6264 |
^ self extensionClassesWithSuperclasses:false |
6265 |
||
6266 |
" |
|
6267 |
stx_libboss extensionClasses |
|
6268 |
" |
|
6269 |
||
6270 |
"Modified: / 06-09-2011 / 10:21:44 / cg" |
|
6271 |
! |
|
6272 |
||
6273 |
extensionClassesWithSuperclasses:withSuperclassesBoolean |
|
6274 |
"answer the set of classes, which are extended by the package" |
|
6275 |
||
13081 | 6276 |
|classes| |
6277 |
||
6278 |
classes := IdentitySet new. |
|
6279 |
||
13419 | 6280 |
self extensionMethodNames pairWiseDo:[:className :selector | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6281 |
|mthdCls extendedClass| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6282 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6283 |
mthdCls := Smalltalk classNamed:className. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6284 |
(mthdCls notNil and:[mthdCls isLoaded]) ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6285 |
extendedClass := mthdCls theNonMetaclass. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6286 |
(classes includes:extendedClass) ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6287 |
withSuperclassesBoolean ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6288 |
extendedClass withAllSuperclassesDo:[:eachClass | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6289 |
classes add:eachClass. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6290 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6291 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6292 |
classes add:extendedClass. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6293 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6294 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6295 |
]. |
13081 | 6296 |
]. |
6297 |
^ classes. |
|
6298 |
||
6299 |
" |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6300 |
stx_libboss extensionClasses |
13636 | 6301 |
" |
6302 |
||
6303 |
"Created: / 06-09-2011 / 10:17:06 / cg" |
|
13081 | 6304 |
! |
6305 |
||
12368 | 6306 |
extensionMethods |
6307 |
"list my extension methods. |
|
6308 |
Project must be loaded - otherwise an error is reported here. |
|
6309 |
Use #extensionMethodsNames if you are only interested in the names" |
|
6310 |
||
13419 | 6311 |
^ self extensionMethodNames |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6312 |
pairWiseCollect:[:className :selector | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6313 |
(Smalltalk classNamed:className) compiledMethodAt:selector. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6314 |
]. |
12368 | 6315 |
|
6316 |
" |
|
6317 |
stx_libbasic2 extensionMethodNames |
|
6318 |
stx_libbasic2 extensionMethods |
|
6319 |
" |
|
6320 |
! |
|
6321 |
||
13081 | 6322 |
extensionPackages |
6323 |
"answer the set of packages, which are extended by this package" |
|
6324 |
||
13636 | 6325 |
^ self allExtensionClasses collect:[:eachClass| eachClass package] |
6326 |
||
6327 |
" |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6328 |
stx_libboss extensionPackages |
13636 | 6329 |
" |
6330 |
||
6331 |
"Modified: / 06-09-2011 / 10:20:47 / cg" |
|
13081 | 6332 |
! |
6333 |
||
10144 | 6334 |
hasAllClassesFullyLoaded |
6335 |
"return true, if all classes are present and loaded" |
|
6336 |
||
6337 |
^ self hasAllClassesLoaded:true |
|
6338 |
||
6339 |
"Created: / 25-10-2006 / 16:08:25 / cg" |
|
6340 |
! |
|
6341 |
||
9627 | 6342 |
hasAllClassesLoaded |
10205 | 6343 |
"return true, if all classes are present (although, some might be autoloaded)" |
10144 | 6344 |
|
6345 |
^ self hasAllClassesLoaded:false |
|
6346 |
||
6347 |
"Modified: / 25-10-2006 / 16:08:11 / cg" |
|
6348 |
! |
|
6349 |
||
6350 |
hasAllClassesLoaded:checkIfFullyLoaded |
|
10366
8990764f8911
#compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents:
10350
diff
changeset
|
6351 |
"check if all classes for this platform are present. |
12421
67898c88eceb
comment/format in: #hasAllClassesLoaded:
Claus Gittinger <cg@exept.de>
parents:
12416
diff
changeset
|
6352 |
If checkIfFullyLoaded is true, they must be fully loaded; that means: not autoloaded" |
10366
8990764f8911
#compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents:
10350
diff
changeset
|
6353 |
|
13419 | 6354 |
^ (self |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6355 |
hasClasses:(self classNamesForWhich:[:nm :attr | attr isEmptyOrNil or:[ attr includes:#autoload]]) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6356 |
loaded:checkIfFullyLoaded) |
10154 | 6357 |
and:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6358 |
self |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6359 |
hasClasses:(self compiled_classNamesForPlatform:OperatingSystem platformName) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6360 |
loaded:checkIfFullyLoaded ] |
10154 | 6361 |
|
6362 |
"Modified: / 07-11-2006 / 11:47:30 / cg" |
|
6363 |
! |
|
6364 |
||
6365 |
hasAllCompiledClassesFullyLoaded |
|
6366 |
"return true, if all compiled classes are present and loaded" |
|
6367 |
||
6368 |
^ self hasAllCompiledClassesLoaded:true |
|
6369 |
||
6370 |
"Created: / 07-11-2006 / 11:48:02 / cg" |
|
6371 |
! |
|
6372 |
||
6373 |
hasAllCompiledClassesLoaded:checkIfFullyLoaded |
|
10366
8990764f8911
#compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents:
10350
diff
changeset
|
6374 |
"check if all compiled classes for this platform are present. |
8990764f8911
#compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents:
10350
diff
changeset
|
6375 |
If checkIfFullyLoaded is true, they must be fully loaded, that is not autoloaded" |
8990764f8911
#compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents:
10350
diff
changeset
|
6376 |
|
13419 | 6377 |
^ (self |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6378 |
hasClasses:(self classNamesForWhich:[:nm :attr | attr isEmptyOrNil]) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6379 |
loaded:checkIfFullyLoaded) |
10154 | 6380 |
and:[ |
13419 | 6381 |
self |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6382 |
hasClasses:(self compiled_classNamesForPlatform:OperatingSystem platformName) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6383 |
loaded:checkIfFullyLoaded |
10366
8990764f8911
#compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents:
10350
diff
changeset
|
6384 |
] |
9585 | 6385 |
! |
6386 |
||
9627 | 6387 |
hasAllExtensionsLoaded |
10203
b210e7832fe1
Do not autoload when checking for extensions
Stefan Vogel <sv@exept.de>
parents:
10200
diff
changeset
|
6388 |
"answer true, if all extensions of this package have been loaded. |
b210e7832fe1
Do not autoload when checking for extensions
Stefan Vogel <sv@exept.de>
parents:
10200
diff
changeset
|
6389 |
This is a query - so no side effects please" |
b210e7832fe1
Do not autoload when checking for extensions
Stefan Vogel <sv@exept.de>
parents:
10200
diff
changeset
|
6390 |
|
9627 | 6391 |
self extensionMethodNames pairWiseDo:[:className :selector | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6392 |
|cls| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6393 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6394 |
cls := Smalltalk loadedClassNamed:className. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6395 |
cls isNil ifTrue:[ |
14021 | 6396 |
Verbose ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6397 |
Transcript showCR:(self name,' missing extension class "',className,'".'). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6398 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6399 |
^ false |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6400 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6401 |
"there is no possibility that we installed an extension method in an unloaded class" |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6402 |
(cls isLoaded not or:[(cls compiledMethodAt:selector) isNil]) ifTrue:[ |
14021 | 6403 |
Verbose ifTrue:[ |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6404 |
Transcript showCR:(self name,' missing extension method "',className,'>>',selector,'".'). |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6405 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6406 |
^ false |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6407 |
]. |
9627 | 6408 |
]. |
6409 |
^ true. |
|
6410 |
||
6411 |
"Created: / 17-08-2006 / 00:50:01 / cg" |
|
10140 | 6412 |
"Modified: / 25-10-2006 / 00:01:10 / cg" |
9850 | 6413 |
! |
6414 |
||
10369
14baf6dc8ba6
No diag message about "unloaded classes" when loading packages
Stefan Vogel <sv@exept.de>
parents:
10368
diff
changeset
|
6415 |
hasClasses:classNames loaded:checkIfFullyLoaded |
14baf6dc8ba6
No diag message about "unloaded classes" when loading packages
Stefan Vogel <sv@exept.de>
parents:
10368
diff
changeset
|
6416 |
"answer true, if all classes referenced by classNames have been loaded |
14baf6dc8ba6
No diag message about "unloaded classes" when loading packages
Stefan Vogel <sv@exept.de>
parents:
10368
diff
changeset
|
6417 |
into the image. If checkIfFullyLoaded, classes installed as autoloaded |
14baf6dc8ba6
No diag message about "unloaded classes" when loading packages
Stefan Vogel <sv@exept.de>
parents:
10368
diff
changeset
|
6418 |
are not considered" |
14baf6dc8ba6
No diag message about "unloaded classes" when loading packages
Stefan Vogel <sv@exept.de>
parents:
10368
diff
changeset
|
6419 |
|
14baf6dc8ba6
No diag message about "unloaded classes" when loading packages
Stefan Vogel <sv@exept.de>
parents:
10368
diff
changeset
|
6420 |
classNames do:[:eachClassName | |
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6421 |
|cls| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6422 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6423 |
cls := Smalltalk loadedClassNamed:eachClassName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6424 |
cls isNil ifTrue:[ |
14021 | 6425 |
Verbose ifTrue:[ |
6426 |
(self name, ' [info]: missing class: ', eachClassName) infoPrintCR. |
|
6427 |
]. |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6428 |
^ false |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6429 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6430 |
(checkIfFullyLoaded and:[cls isLoaded not]) ifTrue:[ |
14021 | 6431 |
Verbose ifTrue:[ |
6432 |
(self name,' [info]: unloaded class: ', eachClassName) infoPrintCR. |
|
6433 |
]. |
|
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6434 |
^ false. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6435 |
]. |
10369
14baf6dc8ba6
No diag message about "unloaded classes" when loading packages
Stefan Vogel <sv@exept.de>
parents:
10368
diff
changeset
|
6436 |
]. |
14baf6dc8ba6
No diag message about "unloaded classes" when loading packages
Stefan Vogel <sv@exept.de>
parents:
10368
diff
changeset
|
6437 |
|
14baf6dc8ba6
No diag message about "unloaded classes" when loading packages
Stefan Vogel <sv@exept.de>
parents:
10368
diff
changeset
|
6438 |
^ true |
10154 | 6439 |
! |
6440 |
||
9906
9efd21c9b1b6
hasExtensions is a bad name (conflicts with the other query)
Claus Gittinger <cg@exept.de>
parents:
9904
diff
changeset
|
6441 |
hasExtensionMethods |
9850 | 6442 |
^ self extensionMethodNames notEmpty |
6443 |
||
6444 |
"Created: / 14-09-2006 / 14:19:35 / cg" |
|
10005 | 6445 |
! |
6446 |
||
12369 | 6447 |
hasPostLoadAction |
6448 |
"/ true if postLoadAction has been redefined |
|
6449 |
^ (self class whichClassIncludesSelector:#postLoadAction) theNonMetaclass isAbstract not |
|
6450 |
! |
|
6451 |
||
6452 |
hasPostUnloadAction |
|
6453 |
"/ true if postUnloadAction has been redefined |
|
6454 |
^ (self class whichClassIncludesSelector:#postUnloadAction) theNonMetaclass isAbstract not |
|
6455 |
! |
|
6456 |
||
6457 |
hasPreLoadAction |
|
6458 |
"/ true if preLoadAction has been redefined |
|
6459 |
^ (self class whichClassIncludesSelector:#preLoadAction) theNonMetaclass isAbstract not |
|
6460 |
! |
|
6461 |
||
6462 |
hasPreUnloadAction |
|
6463 |
"/ true if preUnloadAction has been redefined |
|
6464 |
^ (self class whichClassIncludesSelector:#preUnloadAction) theNonMetaclass isAbstract not |
|
6465 |
! |
|
6466 |
||
13609 | 6467 |
isAbstract |
6468 |
^ self == ProjectDefinition |
|
6469 |
||
6470 |
"Modified (format): / 20-08-2011 / 22:47:46 / cg" |
|
6471 |
! |
|
6472 |
||
10140 | 6473 |
isFullyLoaded |
13419 | 6474 |
^ self hasAllCompiledClassesFullyLoaded |
13167 | 6475 |
and:[self hasAllClassesLoaded and:[self hasAllExtensionsLoaded]] |
10140 | 6476 |
|
6477 |
"Created: / 24-10-2006 / 23:52:23 / cg" |
|
13609 | 6478 |
"Modified: / 20-08-2011 / 22:47:16 / cg" |
12331 | 6479 |
! |
6480 |
||
6481 |
projectType |
|
6482 |
^ self subclassResponsibility |
|
9585 | 6483 |
! ! |
6484 |
||
10774 | 6485 |
!ProjectDefinition class methodsFor:'queries-privacy'! |
6486 |
||
6487 |
showClassDocumentationOf:aClass |
|
12198
f3f15cc6a32e
changed: #showClassDocumentationOf:
Claus Gittinger <cg@exept.de>
parents:
12192
diff
changeset
|
6488 |
"used by the HTMLDoc-generator to ask if a classes' protocol is to be documented |
f3f15cc6a32e
changed: #showClassDocumentationOf:
Claus Gittinger <cg@exept.de>
parents:
12192
diff
changeset
|
6489 |
or hidden. |
f3f15cc6a32e
changed: #showClassDocumentationOf:
Claus Gittinger <cg@exept.de>
parents:
12192
diff
changeset
|
6490 |
(used for expecco, to suppress documentation of workflow- and expecco classes |
f3f15cc6a32e
changed: #showClassDocumentationOf:
Claus Gittinger <cg@exept.de>
parents:
12192
diff
changeset
|
6491 |
in the expecco-class browser)" |
10774 | 6492 |
|
6493 |
^ true |
|
6494 |
||
6495 |
"Created: / 05-11-2007 / 16:44:16 / cg" |
|
6496 |
! ! |
|
6497 |
||
9726 | 6498 |
!ProjectDefinition class methodsFor:'sanity checks'! |
6499 |
||
6500 |
validateDescription |
|
13808 | 6501 |
"perform some consistency checks (set of classes in project same as those listed in description); |
6502 |
called before checking in build support files" |
|
6503 |
||
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6504 |
|emptyProjects nonProjects emptyOrNonProjects classesInImage |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6505 |
classesInDescription onlyInImage onlyInDescription missingPools| |
9956 | 6506 |
|
6507 |
emptyProjects := Set withAll:self subProjects. |
|
6508 |
Smalltalk allClassesDo:[:cls | |
|
13711
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6509 |
emptyProjects remove:(cls package) ifAbsent:[]. |
9956 | 6510 |
]. |
6511 |
nonProjects := self subProjects select:[:p | |
|
13711
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6512 |
(ProjectDefinition definitionClassForPackage: p) isNil |
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6513 |
]. |
9956 | 6514 |
|
6515 |
emptyOrNonProjects := Set withAll:emptyProjects. |
|
6516 |
emptyOrNonProjects addAll:nonProjects. |
|
6517 |
||
6518 |
emptyOrNonProjects notEmpty ifTrue:[ |
|
13711
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6519 |
(Dialog |
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6520 |
confirm:('The following projects are non-existent, empty or without description:\\ ' |
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6521 |
, ((emptyOrNonProjects |
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6522 |
asSortedCollection |
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6523 |
collect:[:p | p allBold]) |
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6524 |
asStringWith:'\ ') |
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6525 |
, '\\Continue ?') withCRs |
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6526 |
yesLabel:'OK' noLabel:'Cancel') |
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6527 |
ifFalse:[ |
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6528 |
AbortSignal raise |
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6529 |
]. |
9956 | 6530 |
]. |
6531 |
||
13723
5e72c5ef9936
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13711
diff
changeset
|
6532 |
classesInImage := Smalltalk allClasses select:[:cls | (cls package = self package) and:[cls isPrivate not]]. |
13728 | 6533 |
"/ classesInDescription := self classes asIdentitySet. |
6534 |
classesInDescription := IdentitySet new. |
|
6535 |
((self compiled_classNamesForPlatform:(OperatingSystem platformName)) |
|
6536 |
, (self compiled_classNames_common) |
|
6537 |
, (self autoloaded_classNames)) do:[:nm | |
|
6538 |
|cls| |
|
6539 |
||
6540 |
cls := Smalltalk at:nm asSymbol. |
|
6541 |
cls isNil ifTrue:[ |
|
6542 |
self error:'oops: missing class: ',nm. |
|
6543 |
]. |
|
6544 |
classesInDescription add:cls. |
|
6545 |
]. |
|
6546 |
||
13809
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6547 |
missingPools := Set new. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6548 |
classesInDescription do:[:eachClass | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6549 |
eachClass sharedPoolNames do:[:eachPoolName | |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6550 |
|pool| |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6551 |
|
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6552 |
pool := eachClass nameSpace classNamed:eachPoolName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6553 |
pool isNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6554 |
eachClass nameSpace ~~ Smalltalk ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6555 |
pool := Smalltalk classNamed:eachPoolName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6556 |
] |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6557 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6558 |
pool isNil ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6559 |
Transcript showCR:'missing pool: ',eachPoolName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6560 |
missingPools add:eachPoolName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6561 |
] ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6562 |
pool isSharedPool ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6563 |
Transcript showCR:'not a shared pool: ',eachPoolName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6564 |
missingPools add:eachPoolName. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6565 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6566 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6567 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6568 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6569 |
missingPools notEmpty ifTrue:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6570 |
(Dialog |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6571 |
confirm:('The following sharedpools are non-existent, or not pools:\\ ' |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6572 |
, ((missingPools |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6573 |
asSortedCollection |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6574 |
collect:[:p | p allBold]) |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6575 |
asStringWith:'\ ') |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6576 |
, '\\Continue ?') withCRs |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6577 |
yesLabel:'OK' noLabel:'Cancel') |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6578 |
ifFalse:[ |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6579 |
AbortSignal raise |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6580 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6581 |
]. |
da77d6869c9c
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13808
diff
changeset
|
6582 |
|
13694
ff3118874df3
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13692
diff
changeset
|
6583 |
classesInImage ~= classesInDescription ifTrue:[ |
13711
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6584 |
onlyInImage := (classesInImage reject:[:cls | classesInDescription includes:cls]). |
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6585 |
onlyInImage notEmpty ifTrue:[ |
13899
d769ad2935e6
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13875
diff
changeset
|
6586 |
Transcript show:self name; show:': only in image: '; showCR:onlyInImage |
13711
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6587 |
]. |
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6588 |
onlyInDescription := (classesInDescription reject:[:cls | classesInImage includes:cls]). |
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6589 |
onlyInDescription notEmpty ifTrue:[ |
13899
d769ad2935e6
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13875
diff
changeset
|
6590 |
Transcript show:self name; show:': only in description: '; showCR:onlyInDescription |
13711
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6591 |
]. |
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6592 |
(Dialog confirm:'The set of classes in the image is different from the listed classes in the project definition.\\Proceed?' withCRs) ifFalse:[ |
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6593 |
AbortSignal raiseRequest |
d3fe511856fc
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13702
diff
changeset
|
6594 |
] |
13694
ff3118874df3
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13692
diff
changeset
|
6595 |
]. |
ff3118874df3
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13692
diff
changeset
|
6596 |
|
ff3118874df3
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13692
diff
changeset
|
6597 |
" |
ff3118874df3
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13692
diff
changeset
|
6598 |
squeak_vmMaker validateDescription |
ff3118874df3
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13692
diff
changeset
|
6599 |
" |
ff3118874df3
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13692
diff
changeset
|
6600 |
|
13899
d769ad2935e6
changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents:
13875
diff
changeset
|
6601 |
"Modified: / 09-01-2012 / 11:02:59 / cg" |
9726 | 6602 |
! ! |
6603 |
||
9585 | 6604 |
!ProjectDefinition class methodsFor:'testing'! |
6605 |
||
9664 | 6606 |
isApplicationDefinition |
6607 |
^ false |
|
6608 |
||
6609 |
"Created: / 23-08-2006 / 15:17:32 / cg" |
|
9983 | 6610 |
"Modified: / 20-09-2006 / 14:59:56 / cg" |
6611 |
! |
|
6612 |
||
12309
f51aaafd2131
added: #isConsoleApplication
Claus Gittinger <cg@exept.de>
parents:
12305
diff
changeset
|
6613 |
isConsoleApplication |
f51aaafd2131
added: #isConsoleApplication
Claus Gittinger <cg@exept.de>
parents:
12305
diff
changeset
|
6614 |
^ false |
f51aaafd2131
added: #isConsoleApplication
Claus Gittinger <cg@exept.de>
parents:
12305
diff
changeset
|
6615 |
|
f51aaafd2131
added: #isConsoleApplication
Claus Gittinger <cg@exept.de>
parents:
12305
diff
changeset
|
6616 |
"Created: / 20-09-2006 / 14:59:49 / cg" |
f51aaafd2131
added: #isConsoleApplication
Claus Gittinger <cg@exept.de>
parents:
12305
diff
changeset
|
6617 |
! |
f51aaafd2131
added: #isConsoleApplication
Claus Gittinger <cg@exept.de>
parents:
12305
diff
changeset
|
6618 |
|
9983 | 6619 |
isGUIApplication |
6620 |
^ false |
|
6621 |
||
6622 |
"Created: / 20-09-2006 / 14:59:49 / cg" |
|
9664 | 6623 |
! |
6624 |
||
6625 |
isLibraryDefinition |
|
6626 |
^ false |
|
6627 |
||
6628 |
"Created: / 23-08-2006 / 15:17:46 / cg" |
|
9983 | 6629 |
"Modified: / 20-09-2006 / 15:00:00 / cg" |
9664 | 6630 |
! |
6631 |
||
9627 | 6632 |
isProjectDefinition |
9664 | 6633 |
"concrete i.e. not abstract" |
6634 |
||
13285 | 6635 |
^ self ~~ ProjectDefinition "/ skip myself - I am abstract |
9627 | 6636 |
|
6637 |
"Created: / 10-08-2006 / 16:24:02 / cg" |
|
13285 | 6638 |
"Modified: / 08-02-2011 / 10:03:49 / cg" |
9585 | 6639 |
! ! |
6640 |
||
13592 | 6641 |
!ProjectDefinition::AbbrevEntry methodsFor:'accessing'! |
6642 |
||
6643 |
category |
|
6644 |
^ category |
|
6645 |
! |
|
6646 |
||
6647 |
className |
|
6648 |
^ className |
|
6649 |
! |
|
6650 |
||
13695 | 6651 |
className:classNameArg fileName:fileNameArg category:categoryArg numClassInstVars:numClassInstVarsArg |
13592 | 6652 |
className := classNameArg. |
6653 |
fileName := fileNameArg. |
|
6654 |
category := categoryArg. |
|
6655 |
numClassInstVars := numClassInstVarsArg. |
|
6656 |
||
6657 |
"Created: / 18-08-2011 / 14:18:30 / cg" |
|
6658 |
! |
|
6659 |
||
6660 |
fileName |
|
6661 |
^ fileName |
|
6662 |
! |
|
6663 |
||
6664 |
numClassInstVars |
|
6665 |
^ numClassInstVars |
|
6666 |
||
6667 |
"Created: / 18-08-2011 / 14:18:37 / cg" |
|
6668 |
! ! |
|
6669 |
||
9569 | 6670 |
!ProjectDefinition class methodsFor:'documentation'! |
9536 | 6671 |
|
13610
ec7ea708ebd2
changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13609
diff
changeset
|
6672 |
version |
14021 | 6673 |
^ '$Header: /cvs/stx/stx/libbasic/ProjectDefinition.st,v 1.381 2012-02-23 11:50:27 stefan Exp $' |
13610
ec7ea708ebd2
changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13609
diff
changeset
|
6674 |
! |
ec7ea708ebd2
changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents:
13609
diff
changeset
|
6675 |
|
12086 | 6676 |
version_CVS |
14021 | 6677 |
^ '$Header: /cvs/stx/stx/libbasic/ProjectDefinition.st,v 1.381 2012-02-23 11:50:27 stefan Exp $' |
13411 | 6678 |
! |
6679 |
||
6680 |
version_SVN |
|
13485
60df70976373
changed: #classNamesByCategory
Claus Gittinger <cg@exept.de>
parents:
13419
diff
changeset
|
6681 |
^ '§ Id: ProjectDefinition.st 10645 2011-06-09 15:28:45Z vranyj1 §' |
9536 | 6682 |
! ! |
9714 | 6683 |
|
6684 |
ProjectDefinition initialize! |