Project.st
author Claus Gittinger <cg@exept.de>
Sun, 03 Oct 1999 18:55:37 +0200
changeset 4834 522f10359ce9
parent 4833 5652aec1b08a
child 4850 43b7eac07273
permissions -rw-r--r--
checkin from browser
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
89
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
     1
"
236
fa6d1f330010 *** empty log message ***
claus
parents: 235
diff changeset
     2
 COPYRIGHT (c) 1993 by Claus Gittinger
203
3d88fa870de0 *** empty log message ***
claus
parents: 150
diff changeset
     3
	      All Rights Reserved
89
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
     4
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
     5
 This software is furnished under a license and may be used
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
     6
 only in accordance with the terms of that license and with the
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
     7
 inclusion of the above copyright notice.   This software may not
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
     8
 be provided or otherwise made available to, or used by, any
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
     9
 other person.  No title to or ownership of the software is
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    10
 hereby transferred.
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    11
"
1
a27a279701f8 Initial revision
claus
parents:
diff changeset
    12
a27a279701f8 Initial revision
claus
parents:
diff changeset
    13
Object subclass:#Project
939
ffee570b0f09 added #setProject: (does not send change notifications)
Claus Gittinger <cg@exept.de>
parents: 848
diff changeset
    14
	instanceVariableNames:'name changeSet views directoryName properties packageName
4726
5c5e1c7f8933 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4721
diff changeset
    15
		repositoryDirectory repositoryModule overwrittenMethods
5c5e1c7f8933 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4721
diff changeset
    16
		subProjects prerequisites isLoaded'
4685
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
    17
	classVariableNames:'CurrentProject SystemProject NextSequential AllProjects
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
    18
		LoadedProjects'
939
ffee570b0f09 added #setProject: (does not send change notifications)
Claus Gittinger <cg@exept.de>
parents: 848
diff changeset
    19
	poolDictionaries:''
ffee570b0f09 added #setProject: (does not send change notifications)
Claus Gittinger <cg@exept.de>
parents: 848
diff changeset
    20
	category:'System-Support'
1
a27a279701f8 Initial revision
claus
parents:
diff changeset
    21
!
a27a279701f8 Initial revision
claus
parents:
diff changeset
    22
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
    23
Object subclass:#ClassInfo
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
    24
	instanceVariableNames:'conditionForInclusion className classFileName'
4668
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
    25
	classVariableNames:''
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
    26
	poolDictionaries:''
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
    27
	privateIn:Project
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
    28
!
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
    29
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
    30
Object subclass:#MethodInfo
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
    31
	instanceVariableNames:'conditionForInclusion methodName className fileName'
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
    32
	classVariableNames:''
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
    33
	poolDictionaries:''
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
    34
	privateIn:Project
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
    35
!
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
    36
1854
b44227fd2b3d use new Method>>who interface
Claus Gittinger <cg@exept.de>
parents: 1636
diff changeset
    37
!Project class methodsFor:'documentation'!
89
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    38
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    39
copyright
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    40
"
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    41
 COPYRIGHT (c) 1993 by Claus Gittinger
203
3d88fa870de0 *** empty log message ***
claus
parents: 150
diff changeset
    42
	      All Rights Reserved
89
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    43
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    44
 This software is furnished under a license and may be used
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    45
 only in accordance with the terms of that license and with the
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    46
 inclusion of the above copyright notice.   This software may not
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    47
 be provided or otherwise made available to, or used by, any
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    48
 other person.  No title to or ownership of the software is
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    49
 hereby transferred.
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    50
"
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    51
!
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    52
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    53
documentation
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    54
"
338
claus
parents: 336
diff changeset
    55
    this class is still under construction (especially the build features are unfinished).
235
d8e62525bfdf *** empty log message ***
claus
parents: 203
diff changeset
    56
    Currently, all it does is keep track of per-project views 
d8e62525bfdf *** empty log message ***
claus
parents: 203
diff changeset
    57
    (to hide or show them), define the directory when filing-out,
725
02759b2003a8 keep module & directory separately (as defaults when creating a container)
Claus Gittinger <cg@exept.de>
parents: 705
diff changeset
    58
    and define packageNames for new classes and methods.
02759b2003a8 keep module & directory separately (as defaults when creating a container)
Claus Gittinger <cg@exept.de>
parents: 705
diff changeset
    59
02759b2003a8 keep module & directory separately (as defaults when creating a container)
Claus Gittinger <cg@exept.de>
parents: 705
diff changeset
    60
    instance variables:
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    61
	name            <String>        the name of this project, as shown
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    62
					in a ProjectView
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    63
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    64
	changeSet       <ChangeSet>     changes done, while this was the active project
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    65
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    66
	views           <Collection>    views opened while this was the active project
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    67
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    68
	directoryName   <String>        directory name, where fileOuts are done
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    69
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    70
	properties 
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    71
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    72
	packageName     <String>        given to classes/methods which are created while
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    73
					this is the active project
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    74
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    75
	repositoryDirectory             (default) name of the repository, when a new source containers are
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    76
					created.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    77
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    78
	repositoryModule                (default) name of the module, when new source containers are
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    79
					created.
235
d8e62525bfdf *** empty log message ***
claus
parents: 203
diff changeset
    80
d8e62525bfdf *** empty log message ***
claus
parents: 203
diff changeset
    81
    Future: 
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    82
	- keep track of per-project changes
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    83
	- allow speficiation of the type of the project (application or library)
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    84
	- allow building of whatever the target (as defined by the type) is
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    85
	  (this will allow build of class libs and apps by clicking a button)
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    86
	- allow removal of project specific classes, methods etc.
1286
4270a0b4917d documentation
Claus Gittinger <cg@exept.de>
parents: 1115
diff changeset
    87
4270a0b4917d documentation
Claus Gittinger <cg@exept.de>
parents: 1115
diff changeset
    88
    [author:]
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
    89
	Claus Gittinger
89
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    90
"
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    91
! !
7be0b86ef80f *** empty log message ***
claus
parents: 87
diff changeset
    92
1854
b44227fd2b3d use new Method>>who interface
Claus Gittinger <cg@exept.de>
parents: 1636
diff changeset
    93
!Project class methodsFor:'initialization'!
236
fa6d1f330010 *** empty log message ***
claus
parents: 235
diff changeset
    94
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
    95
initKnownProjects
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
    96
    "this is a temporary experimental kludge -
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
    97
     once the ProjectBrowser is finished, this info is read from
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
    98
     '.prj' files ..."
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
    99
4668
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   100
    "/ collect project info while scanning all classes
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   101
    "/ and methods ...
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   102
4685
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   103
    |packages anyUnloaded|
4668
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   104
4747
b642ad29477a scan loaded modules for directory-ames
Claus Gittinger <cg@exept.de>
parents: 4743
diff changeset
   105
    packages := Dictionary new.
4668
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   106
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   107
    AllProjects isNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   108
	AllProjects := OrderedCollection new.
4668
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   109
    ] ifFalse:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   110
	AllProjects do:[:p | packages at:p package asSymbol put:p].
4668
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   111
    ].
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   112
    Smalltalk allClassesDo:[:aClass |
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   113
	|packageID prj classFilename pkgInfo revInfo 
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   114
	 repositoryPath dir module lib nm|
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   115
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   116
	aClass isMeta ifFalse:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   117
	    (aClass isNamespace not or:[aClass == Smalltalk]) ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   118
		packageID := aClass package asSymbol.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   119
		(packages includesKey:packageID) ifFalse:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   120
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   121
		    "/ a new one ...
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   122
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   123
		    prj := self new.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   124
		    prj package:packageID.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   125
		    prj directory:'???'.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   126
		    prj repositoryModule:'unknown'.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   127
		    prj repositoryDirectory:'unknown'.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   128
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   129
		    nm := 'unknown'.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   130
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   131
		    pkgInfo := aClass packageSourceCodeInfo.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   132
		    pkgInfo notNil ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   133
			module := pkgInfo at:#module ifAbsent:nil.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   134
			module notNil ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   135
			    prj repositoryModule:module    
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   136
			].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   137
			dir := pkgInfo at:#directory ifAbsent:nil.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   138
			dir notNil ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   139
			    prj repositoryDirectory:dir    
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   140
			].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   141
			lib := pkgInfo at:#library ifAbsent:nil.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   142
			lib notNil ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   143
			    prj type:#library.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   144
			].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   145
			prj isLoaded:true.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   146
		    ].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   147
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   148
		    nm := (module ? 'unknown')
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   149
			  , ':'
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   150
			  , (dir ? (lib ? 'unknown')).
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   151
			
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   152
		    prj name:nm.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   153
		    AllProjects add:prj.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   154
		    packages at:packageID put:prj.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   155
		].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   156
	    ].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   157
	].
4668
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   158
    ].
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   159
    Method allSubInstancesDo:[:aMethod |
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   160
	|packageID prj who mthdClass|
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   161
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   162
	packageID := aMethod package asSymbol.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   163
	(packages includesKey:packageID) ifFalse:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   164
	    who := aMethod who.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   165
	    who notNil ifTrue:[ "/ skip unbound methods ...
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   166
		"/ a new one ...
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   167
		prj := self new.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   168
	"/            prj name:libName.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   169
		prj package:packageID.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   170
		prj type:#library.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   171
		prj directory:'???'.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   172
		prj repositoryModule:'stx'.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   173
		prj repositoryDirectory:'???'.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   174
		prj isLoaded:true.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   175
		AllProjects add:prj.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   176
		packages at:packageID put:prj.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   177
	    ]
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   178
	]
4668
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   179
    ].
4747
b642ad29477a scan loaded modules for directory-ames
Claus Gittinger <cg@exept.de>
parents: 4743
diff changeset
   180
b642ad29477a scan loaded modules for directory-ames
Claus Gittinger <cg@exept.de>
parents: 4743
diff changeset
   181
    "/ walk over binary modules, to find out directory names ...
b642ad29477a scan loaded modules for directory-ames
Claus Gittinger <cg@exept.de>
parents: 4743
diff changeset
   182
b642ad29477a scan loaded modules for directory-ames
Claus Gittinger <cg@exept.de>
parents: 4743
diff changeset
   183
    ObjectFileLoader loadedObjectHandles do:[:h |
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   184
	|cls prj mDir|
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   185
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   186
	cls := h classes firstIfEmpty:nil.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   187
	cls notNil ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   188
	    prj := packages at:cls package ifAbsent:nil.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   189
	    prj notNil ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   190
		mDir := h pathName asFilename directory pathName.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   191
		prj directory = '???' ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   192
		    prj directory:mDir
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   193
		] ifFalse:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   194
		    prj directory ~= mDir ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   195
			('Project [warning]: conflicting project directories for ' , cls package) infoPrintCR.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   196
		    ]
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   197
		]
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   198
	    ]
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   199
	].
4747
b642ad29477a scan loaded modules for directory-ames
Claus Gittinger <cg@exept.de>
parents: 4743
diff changeset
   200
    ].
b642ad29477a scan loaded modules for directory-ames
Claus Gittinger <cg@exept.de>
parents: 4743
diff changeset
   201
4668
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   202
    self changed:#allProjects
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   203
4066
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   204
"/    |stx p|
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   205
"/
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   206
"/    stx := self new name:'stx'.
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   207
"/    stx packageName:'noPackage'.
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   208
"/    stx changeSet:nil.
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   209
"/    stx type:#smalltalk.
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   210
"/    stx comment:'The ST/X project itself'.
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   211
"/
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   212
"/    AllProjects add:stx.
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   213
"/
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   214
"/    #(
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   215
"/        ('libbasic'      #'stx:libbasic'            'Basic (non-GUI) classes. Required for all applications')
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   216
"/        ('libbasic2'     #'stx:libbasic2'           'More basic (non-GUI) classes. Required for most applications')
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   217
"/        ('libbasic3'     #'stx:libbasic3'           'More basic (non-GUI) classes. Required for development')
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   218
"/        ('libcomp'       #'stx:libcomp'             'The bytecode compiler. Required for all applications')
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   219
"/        ('libview'       #'stx:libview'             'Low level GUI classes. Required for all GUI applications')
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   220
"/        ('libview2'      #'stx:libview2'            'Additional low level GUI classes. Required for most GUI applications')
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   221
"/        ('libwidg'       #'stx:libwidg'             'Basic widgets. Required for all GUI applications')
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   222
"/        ('libwidg2'      #'stx:libwidg2'            'More widgets. Required for most GUI applications')
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   223
"/        ('libwidg3'      #'stx:libwidg3'            'More (fun) widgets. Seldom required')
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   224
"/        ('libtool'       #'stx:libtool'             'Development applications. Required for program development')
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   225
"/        ('libtool2'      #'stx:libtool2'            'More development applications. Required for GUI development')
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   226
"/        ('libui'         #'stx:libui'               'UI spec classes. Required for UIPainter applications')
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   227
"/        ('libhtml'       #'stx:libhtml'             'HTML related classes. Required for Web applications and the HTML browser')
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   228
"/        ('libodbc'       #'stx:libodbc'             'ODBC interface classes.')
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   229
"/        ('libopengl'     #'stx:libopengl'           'OpenGL interface classes.')
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   230
"/        ('persistency'   #'stx:goodies/persistency' 'Simple DB interface')
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   231
"/        ('goodies'       #'stx:goodies'             'Misc goodies - not really maintained')
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   232
"/    ) do:[:entry |
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   233
"/        |libName package comment|
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   234
"/
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   235
"/        libName := entry at:1.
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   236
"/        package := entry at:2.
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   237
"/        comment := entry at:3.
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   238
"/
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   239
"/        p := self new name:libName.
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   240
"/        p packageName:package.
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   241
"/        p type:#library.
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   242
"/        p comment:comment.
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   243
"/        stx addSubProject:p.
74e64b5cedce checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4013
diff changeset
   244
"/    ].
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   245
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   246
    "
4668
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   247
     AllProjects := nil.
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   248
     self initKnownProjects
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   249
    "
4069
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
   250
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
   251
    "Modified: / 23.3.1999 / 14:20:12 / cg"
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   252
!
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   253
236
fa6d1f330010 *** empty log message ***
claus
parents: 235
diff changeset
   254
initialize
338
claus
parents: 336
diff changeset
   255
    SystemProject isNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   256
	NextSequential := 1.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   257
	SystemProject := self new name:'default'.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   258
	SystemProject package:'private'.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   259
	SystemProject defaultNameSpace:Smalltalk.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   260
	SystemProject comment:'A default (dummy) project. 
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   261
Will be made the current project in case no real project is ever activated.'.
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   262
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   263
	"
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   264
	 the SystemProject does not keep a record if changes,
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   265
	 but instead depends on the changes file - recording anything there.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   266
	"
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   267
	SystemProject changeSet:nil.
338
claus
parents: 336
diff changeset
   268
    ].
claus
parents: 336
diff changeset
   269
claus
parents: 336
diff changeset
   270
    CurrentProject := SystemProject.
4685
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   271
    AllProjects := nil.
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   272
"/ now done lazy ...
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   273
"/    self initKnownProjects.
236
fa6d1f330010 *** empty log message ***
claus
parents: 235
diff changeset
   274
315
7683685383d6 *** empty log message ***
claus
parents: 236
diff changeset
   275
    "
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   276
     SystemProject := nil.
315
7683685383d6 *** empty log message ***
claus
parents: 236
diff changeset
   277
     Project initialize
7683685383d6 *** empty log message ***
claus
parents: 236
diff changeset
   278
    "
236
fa6d1f330010 *** empty log message ***
claus
parents: 235
diff changeset
   279
! !
fa6d1f330010 *** empty log message ***
claus
parents: 235
diff changeset
   280
1854
b44227fd2b3d use new Method>>who interface
Claus Gittinger <cg@exept.de>
parents: 1636
diff changeset
   281
!Project class methodsFor:'instance creation'!
236
fa6d1f330010 *** empty log message ***
claus
parents: 235
diff changeset
   282
fa6d1f330010 *** empty log message ***
claus
parents: 235
diff changeset
   283
new
fa6d1f330010 *** empty log message ***
claus
parents: 235
diff changeset
   284
    ^ self basicNew initialize
fa6d1f330010 *** empty log message ***
claus
parents: 235
diff changeset
   285
! !
fa6d1f330010 *** empty log message ***
claus
parents: 235
diff changeset
   286
1854
b44227fd2b3d use new Method>>who interface
Claus Gittinger <cg@exept.de>
parents: 1636
diff changeset
   287
!Project class methodsFor:'accessing'!
1
a27a279701f8 Initial revision
claus
parents:
diff changeset
   288
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
   289
addKnownProject:aProject
4685
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   290
    |allProjects|
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   291
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   292
    allProjects := self knownProjects.
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   293
    (allProjects detect:[:p | p package = aProject package] ifNone:nil) notNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   294
	self warn:'Project for ' , aProject package , ' is already present.'.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   295
	^ self.
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
   296
    ].
4685
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   297
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
   298
    AllProjects add:aProject.
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
   299
    self changed:#allProjects
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
   300
!
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
   301
4685
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   302
addLoadedProject:aProject
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   303
    aProject isLoaded:true.
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   304
    self addKnownProject:aProject.
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   305
!
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   306
1
a27a279701f8 Initial revision
claus
parents:
diff changeset
   307
current
10
claus
parents: 2
diff changeset
   308
    "return the currently active project"
claus
parents: 2
diff changeset
   309
1
a27a279701f8 Initial revision
claus
parents:
diff changeset
   310
    ^ CurrentProject
a27a279701f8 Initial revision
claus
parents:
diff changeset
   311
362
claus
parents: 356
diff changeset
   312
    "
claus
parents: 356
diff changeset
   313
     Project current
claus
parents: 356
diff changeset
   314
    "
1
a27a279701f8 Initial revision
claus
parents:
diff changeset
   315
!
a27a279701f8 Initial revision
claus
parents:
diff changeset
   316
a27a279701f8 Initial revision
claus
parents:
diff changeset
   317
current:aProject
10
claus
parents: 2
diff changeset
   318
    "set the currently active project"
claus
parents: 2
diff changeset
   319
315
7683685383d6 *** empty log message ***
claus
parents: 236
diff changeset
   320
    CurrentProject := aProject.
7683685383d6 *** empty log message ***
claus
parents: 236
diff changeset
   321
    self changed:#currentProject
334
claus
parents: 330
diff changeset
   322
!
claus
parents: 330
diff changeset
   323
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   324
currentPackageName
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   325
    CurrentProject notNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   326
	^ CurrentProject package
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   327
    ].
4112
5ee841c34b10 return nil (instead of 'no package') if no current package is defined.
Claus Gittinger <cg@exept.de>
parents: 4099
diff changeset
   328
    ^ nil
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   329
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   330
    "
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   331
     Project currentPackageName
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   332
    "
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   333
!
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   334
336
claus
parents: 334
diff changeset
   335
defaultProject
claus
parents: 334
diff changeset
   336
    "return the SystemDefault project"
claus
parents: 334
diff changeset
   337
claus
parents: 334
diff changeset
   338
    ^ SystemProject.
claus
parents: 334
diff changeset
   339
!
claus
parents: 334
diff changeset
   340
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   341
knownProjects
4685
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   342
    AllProjects isNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   343
	self initKnownProjects
4685
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   344
    ].
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   345
    ^ AllProjects ? #()
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   346
!
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   347
4685
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   348
loadedProjects
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   349
    ^ self knownProjects select:[:p | p isLoaded]
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   350
!
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   351
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   352
projectNamed:aProjectName
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   353
    "retrieve the named project; return nil if not known"
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   354
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   355
    ^ self knownProjects detect:[:p | p name = aProjectName] ifNone:nil.
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   356
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   357
    "
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   358
     Project projectNamed:'libbasic'
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   359
    "
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   360
!
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   361
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   362
projectWithId:aPackageId
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   363
    "retrieve the project with a particular id; return nil if not known"
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   364
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   365
    ^ self knownProjects detect:[:p | p package = aPackageId] ifNone:nil.
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   366
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   367
    "
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   368
     Project projectWithId:#'stx:libbasic'
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   369
    "
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   370
!
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   371
334
claus
parents: 330
diff changeset
   372
setDefaultProject
claus
parents: 330
diff changeset
   373
    "set the currently active project to be the SystemDEfault project"
claus
parents: 330
diff changeset
   374
claus
parents: 330
diff changeset
   375
    self current:SystemProject.
939
ffee570b0f09 added #setProject: (does not send change notifications)
Claus Gittinger <cg@exept.de>
parents: 848
diff changeset
   376
!
ffee570b0f09 added #setProject: (does not send change notifications)
Claus Gittinger <cg@exept.de>
parents: 848
diff changeset
   377
ffee570b0f09 added #setProject: (does not send change notifications)
Claus Gittinger <cg@exept.de>
parents: 848
diff changeset
   378
setProject:aProjectOrNil
ffee570b0f09 added #setProject: (does not send change notifications)
Claus Gittinger <cg@exept.de>
parents: 848
diff changeset
   379
    "set the currently active project without updating others"
ffee570b0f09 added #setProject: (does not send change notifications)
Claus Gittinger <cg@exept.de>
parents: 848
diff changeset
   380
ffee570b0f09 added #setProject: (does not send change notifications)
Claus Gittinger <cg@exept.de>
parents: 848
diff changeset
   381
    CurrentProject := aProjectOrNil.
ffee570b0f09 added #setProject: (does not send change notifications)
Claus Gittinger <cg@exept.de>
parents: 848
diff changeset
   382
ffee570b0f09 added #setProject: (does not send change notifications)
Claus Gittinger <cg@exept.de>
parents: 848
diff changeset
   383
    "Created: 7.2.1996 / 14:00:45 / cg"
ffee570b0f09 added #setProject: (does not send change notifications)
Claus Gittinger <cg@exept.de>
parents: 848
diff changeset
   384
    "Modified: 7.2.1996 / 14:01:16 / cg"
1
a27a279701f8 Initial revision
claus
parents:
diff changeset
   385
! !
a27a279701f8 Initial revision
claus
parents:
diff changeset
   386
1854
b44227fd2b3d use new Method>>who interface
Claus Gittinger <cg@exept.de>
parents: 1636
diff changeset
   387
!Project class methodsFor:'changes management'!
149
a3b1bf2938c6 changeSet interface changed
claus
parents: 97
diff changeset
   388
664
42ea897fbebe project changeSet fixes
Claus Gittinger <cg@exept.de>
parents: 654
diff changeset
   389
addClassDefinitionChangeFor:aClass
1115
16ebfd63db43 commentary
Claus Gittinger <cg@exept.de>
parents: 939
diff changeset
   390
    "add a class-def-change for aClass to the current project"
16ebfd63db43 commentary
Claus Gittinger <cg@exept.de>
parents: 939
diff changeset
   391
664
42ea897fbebe project changeSet fixes
Claus Gittinger <cg@exept.de>
parents: 654
diff changeset
   392
    |p c|
42ea897fbebe project changeSet fixes
Claus Gittinger <cg@exept.de>
parents: 654
diff changeset
   393
42ea897fbebe project changeSet fixes
Claus Gittinger <cg@exept.de>
parents: 654
diff changeset
   394
    p := CurrentProject.
42ea897fbebe project changeSet fixes
Claus Gittinger <cg@exept.de>
parents: 654
diff changeset
   395
    (p notNil 
42ea897fbebe project changeSet fixes
Claus Gittinger <cg@exept.de>
parents: 654
diff changeset
   396
    and:[(c := p changeSet) notNil]) ifTrue:[
666
6d4175de8c55 fixed primitiveDefinitions changes
Claus Gittinger <cg@exept.de>
parents: 664
diff changeset
   397
	c addClassDefinitionChangeFor:aClass 
664
42ea897fbebe project changeSet fixes
Claus Gittinger <cg@exept.de>
parents: 654
diff changeset
   398
    ]
42ea897fbebe project changeSet fixes
Claus Gittinger <cg@exept.de>
parents: 654
diff changeset
   399
42ea897fbebe project changeSet fixes
Claus Gittinger <cg@exept.de>
parents: 654
diff changeset
   400
    "Created: 3.12.1995 / 13:44:58 / cg"
42ea897fbebe project changeSet fixes
Claus Gittinger <cg@exept.de>
parents: 654
diff changeset
   401
    "Modified: 3.12.1995 / 13:58:04 / cg"
42ea897fbebe project changeSet fixes
Claus Gittinger <cg@exept.de>
parents: 654
diff changeset
   402
!
42ea897fbebe project changeSet fixes
Claus Gittinger <cg@exept.de>
parents: 654
diff changeset
   403
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   404
addMethodCategoryChange:aMethod category:newCategory in:aClass
1115
16ebfd63db43 commentary
Claus Gittinger <cg@exept.de>
parents: 939
diff changeset
   405
    "add a method-category-change for aMethod in aClass to the current project"
16ebfd63db43 commentary
Claus Gittinger <cg@exept.de>
parents: 939
diff changeset
   406
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   407
    |p c|
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   408
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   409
    p := CurrentProject.
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   410
    (p notNil 
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   411
    and:[(c := p changeSet) notNil]) ifTrue:[
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   412
	c addMethodCategoryChange:aMethod category:newCategory in:aClass 
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   413
    ]
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   414
!
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   415
149
a3b1bf2938c6 changeSet interface changed
claus
parents: 97
diff changeset
   416
addMethodChange:aMethod in:aClass
1115
16ebfd63db43 commentary
Claus Gittinger <cg@exept.de>
parents: 939
diff changeset
   417
    "add a method change in aClass to the current project"
149
a3b1bf2938c6 changeSet interface changed
claus
parents: 97
diff changeset
   418
235
d8e62525bfdf *** empty log message ***
claus
parents: 203
diff changeset
   419
    |p c|
149
a3b1bf2938c6 changeSet interface changed
claus
parents: 97
diff changeset
   420
a3b1bf2938c6 changeSet interface changed
claus
parents: 97
diff changeset
   421
    p := CurrentProject.
a3b1bf2938c6 changeSet interface changed
claus
parents: 97
diff changeset
   422
    (p notNil 
235
d8e62525bfdf *** empty log message ***
claus
parents: 203
diff changeset
   423
    and:[(c := p changeSet) notNil]) ifTrue:[
d8e62525bfdf *** empty log message ***
claus
parents: 203
diff changeset
   424
	c addMethodChange:aMethod in:aClass 
203
3d88fa870de0 *** empty log message ***
claus
parents: 150
diff changeset
   425
    ]
3d88fa870de0 *** empty log message ***
claus
parents: 150
diff changeset
   426
!
3d88fa870de0 *** empty log message ***
claus
parents: 150
diff changeset
   427
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   428
addMethodPrivacyChange:aMethod in:aClass
1115
16ebfd63db43 commentary
Claus Gittinger <cg@exept.de>
parents: 939
diff changeset
   429
    "add a privacy change for aMethod in aClass to the current project"
16ebfd63db43 commentary
Claus Gittinger <cg@exept.de>
parents: 939
diff changeset
   430
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   431
    |p c|
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   432
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   433
    p := CurrentProject.
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   434
    (p notNil 
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   435
    and:[(c := p changeSet) notNil]) ifTrue:[
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   436
	c addMethodPrivacyChange:aMethod in:aClass 
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   437
    ]
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   438
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   439
    "Modified: 27.8.1995 / 22:48:17 / claus"
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   440
!
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   441
705
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   442
addPrimitiveDefinitionsChangeFor:aClass
1115
16ebfd63db43 commentary
Claus Gittinger <cg@exept.de>
parents: 939
diff changeset
   443
    "add a primitiveDef change for aClass to the current project"
16ebfd63db43 commentary
Claus Gittinger <cg@exept.de>
parents: 939
diff changeset
   444
705
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   445
    |p c|
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   446
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   447
    p := CurrentProject.
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   448
    (p notNil 
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   449
    and:[(c := p changeSet) notNil]) ifTrue:[
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   450
	c addPrimitiveDefinitionsChangeFor:aClass 
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   451
    ]
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   452
!
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   453
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   454
addPrimitiveFunctionsChangeFor:aClass
1115
16ebfd63db43 commentary
Claus Gittinger <cg@exept.de>
parents: 939
diff changeset
   455
    "add a primitiveFuncs change for aClass to the current project"
16ebfd63db43 commentary
Claus Gittinger <cg@exept.de>
parents: 939
diff changeset
   456
705
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   457
    |p c|
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   458
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   459
    p := CurrentProject.
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   460
    (p notNil 
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   461
    and:[(c := p changeSet) notNil]) ifTrue:[
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   462
	c addPrimitiveFunctionsChangeFor:aClass 
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   463
    ]
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   464
!
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   465
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   466
addPrimitiveVariablesChangeFor:aClass
1115
16ebfd63db43 commentary
Claus Gittinger <cg@exept.de>
parents: 939
diff changeset
   467
    "add a primitiveVars change for aClass to the current project"
16ebfd63db43 commentary
Claus Gittinger <cg@exept.de>
parents: 939
diff changeset
   468
705
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   469
    |p c|
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   470
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   471
    p := CurrentProject.
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   472
    (p notNil 
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   473
    and:[(c := p changeSet) notNil]) ifTrue:[
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   474
	c addPrimitiveVariablesChangeFor:aClass 
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   475
    ]
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   476
!
2126aba57d34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 666
diff changeset
   477
3288
373af30a15ca add removeSelectorChange to current projects changeSet
Claus Gittinger <cg@exept.de>
parents: 2962
diff changeset
   478
addRemoveSelectorChange:aSelector in:aClass
373af30a15ca add removeSelectorChange to current projects changeSet
Claus Gittinger <cg@exept.de>
parents: 2962
diff changeset
   479
    "add a method-remove change in aClass to the current project"
373af30a15ca add removeSelectorChange to current projects changeSet
Claus Gittinger <cg@exept.de>
parents: 2962
diff changeset
   480
373af30a15ca add removeSelectorChange to current projects changeSet
Claus Gittinger <cg@exept.de>
parents: 2962
diff changeset
   481
    |p c|
373af30a15ca add removeSelectorChange to current projects changeSet
Claus Gittinger <cg@exept.de>
parents: 2962
diff changeset
   482
373af30a15ca add removeSelectorChange to current projects changeSet
Claus Gittinger <cg@exept.de>
parents: 2962
diff changeset
   483
    p := CurrentProject.
373af30a15ca add removeSelectorChange to current projects changeSet
Claus Gittinger <cg@exept.de>
parents: 2962
diff changeset
   484
    (p notNil 
373af30a15ca add removeSelectorChange to current projects changeSet
Claus Gittinger <cg@exept.de>
parents: 2962
diff changeset
   485
    and:[(c := p changeSet) notNil]) ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   486
	c addRemoveSelectorChange:aSelector in:aClass 
3288
373af30a15ca add removeSelectorChange to current projects changeSet
Claus Gittinger <cg@exept.de>
parents: 2962
diff changeset
   487
    ]
373af30a15ca add removeSelectorChange to current projects changeSet
Claus Gittinger <cg@exept.de>
parents: 2962
diff changeset
   488
373af30a15ca add removeSelectorChange to current projects changeSet
Claus Gittinger <cg@exept.de>
parents: 2962
diff changeset
   489
    "Created: / 16.2.1998 / 12:45:10 / cg"
373af30a15ca add removeSelectorChange to current projects changeSet
Claus Gittinger <cg@exept.de>
parents: 2962
diff changeset
   490
!
373af30a15ca add removeSelectorChange to current projects changeSet
Claus Gittinger <cg@exept.de>
parents: 2962
diff changeset
   491
149
a3b1bf2938c6 changeSet interface changed
claus
parents: 97
diff changeset
   492
currentProjectDirectory
a3b1bf2938c6 changeSet interface changed
claus
parents: 97
diff changeset
   493
    "return the name of the directory to use for fileOut.
235
d8e62525bfdf *** empty log message ***
claus
parents: 203
diff changeset
   494
     The returned name already includes a file-separator at the end, 
d8e62525bfdf *** empty log message ***
claus
parents: 203
diff changeset
   495
     so the filename can be concatenated to it."
149
a3b1bf2938c6 changeSet interface changed
claus
parents: 97
diff changeset
   496
a3b1bf2938c6 changeSet interface changed
claus
parents: 97
diff changeset
   497
    |p dirName|
a3b1bf2938c6 changeSet interface changed
claus
parents: 97
diff changeset
   498
a3b1bf2938c6 changeSet interface changed
claus
parents: 97
diff changeset
   499
    p := CurrentProject.
a3b1bf2938c6 changeSet interface changed
claus
parents: 97
diff changeset
   500
    p notNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   501
	dirName := p directory  
149
a3b1bf2938c6 changeSet interface changed
claus
parents: 97
diff changeset
   502
    ] ifFalse:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   503
	dirName := Filename currentDirectory name
149
a3b1bf2938c6 changeSet interface changed
claus
parents: 97
diff changeset
   504
    ].
2962
038a8f143e49 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2956
diff changeset
   505
    ^ dirName
2907
1666bf27f351 VMS changes
Claus Gittinger <cg@exept.de>
parents: 2664
diff changeset
   506
1666bf27f351 VMS changes
Claus Gittinger <cg@exept.de>
parents: 2664
diff changeset
   507
    "Modified: 7.9.1997 / 23:52:25 / cg"
2334
7502902385ff only remember overwritten methods if the current project
Claus Gittinger <cg@exept.de>
parents: 2276
diff changeset
   508
!
7502902385ff only remember overwritten methods if the current project
Claus Gittinger <cg@exept.de>
parents: 2276
diff changeset
   509
7502902385ff only remember overwritten methods if the current project
Claus Gittinger <cg@exept.de>
parents: 2276
diff changeset
   510
rememberOverwrittenMethod:newMethod from:oldMethod
7502902385ff only remember overwritten methods if the current project
Claus Gittinger <cg@exept.de>
parents: 2276
diff changeset
   511
    "remember a method (from another package) being overwritten.
7502902385ff only remember overwritten methods if the current project
Claus Gittinger <cg@exept.de>
parents: 2276
diff changeset
   512
     This is only remembered, if the current project is not the
7502902385ff only remember overwritten methods if the current project
Claus Gittinger <cg@exept.de>
parents: 2276
diff changeset
   513
     system project (to avoid filling this remembered-table)"
7502902385ff only remember overwritten methods if the current project
Claus Gittinger <cg@exept.de>
parents: 2276
diff changeset
   514
2558
07e7d6fef46d removed unused var
Claus Gittinger <cg@exept.de>
parents: 2334
diff changeset
   515
    |p|
2334
7502902385ff only remember overwritten methods if the current project
Claus Gittinger <cg@exept.de>
parents: 2276
diff changeset
   516
7502902385ff only remember overwritten methods if the current project
Claus Gittinger <cg@exept.de>
parents: 2276
diff changeset
   517
    p := CurrentProject.
7502902385ff only remember overwritten methods if the current project
Claus Gittinger <cg@exept.de>
parents: 2276
diff changeset
   518
    (p notNil 
7502902385ff only remember overwritten methods if the current project
Claus Gittinger <cg@exept.de>
parents: 2276
diff changeset
   519
    and:[p ~~ SystemProject]) ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   520
	p rememberOverwrittenMethod:newMethod from:oldMethod
2334
7502902385ff only remember overwritten methods if the current project
Claus Gittinger <cg@exept.de>
parents: 2276
diff changeset
   521
    ] ifFalse:[
3332
8014b817988b remove the 'does not remember ...' message.
Claus Gittinger <cg@exept.de>
parents: 3288
diff changeset
   522
"/        'Project [info]: DefaultProject does not remember overwritten methods' infoPrintCR
2334
7502902385ff only remember overwritten methods if the current project
Claus Gittinger <cg@exept.de>
parents: 2276
diff changeset
   523
    ]
7502902385ff only remember overwritten methods if the current project
Claus Gittinger <cg@exept.de>
parents: 2276
diff changeset
   524
3332
8014b817988b remove the 'does not remember ...' message.
Claus Gittinger <cg@exept.de>
parents: 3288
diff changeset
   525
    "Modified: / 7.3.1998 / 13:38:39 / cg"
13
62303f84ff5f *** empty log message ***
claus
parents: 10
diff changeset
   526
! !
62303f84ff5f *** empty log message ***
claus
parents: 10
diff changeset
   527
1
a27a279701f8 Initial revision
claus
parents:
diff changeset
   528
!Project methodsFor:'accessing'!
a27a279701f8 Initial revision
claus
parents:
diff changeset
   529
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   530
addSubProject:aProject
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
   531
    "add a subproject - obsolete; we use prerequisites now"
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
   532
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   533
    subProjects isNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   534
	subProjects := OrderedCollection new.
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   535
    ].
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   536
    subProjects add:aProject
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   537
!
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   538
1
a27a279701f8 Initial revision
claus
parents:
diff changeset
   539
changeSet
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   540
    "return the set of changes made in this project"
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   541
1
a27a279701f8 Initial revision
claus
parents:
diff changeset
   542
    ^ changeSet
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   543
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   544
    "Modified: 27.1.1997 / 11:58:36 / cg"
1
a27a279701f8 Initial revision
claus
parents:
diff changeset
   545
!
a27a279701f8 Initial revision
claus
parents:
diff changeset
   546
236
fa6d1f330010 *** empty log message ***
claus
parents: 235
diff changeset
   547
changeSet:aChangeSet
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   548
    "set the set of changes made in this project - dangerous, you may loose
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   549
     the actual changeSet."
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   550
236
fa6d1f330010 *** empty log message ***
claus
parents: 235
diff changeset
   551
    changeSet := aChangeSet
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   552
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   553
    "Modified: 27.1.1997 / 11:59:02 / cg"
73
a6640cc96199 *** empty log message ***
claus
parents: 13
diff changeset
   554
!
a6640cc96199 *** empty log message ***
claus
parents: 13
diff changeset
   555
2028
85ef24870d8a hold the default nameSpace
Claus Gittinger <cg@exept.de>
parents: 1854
diff changeset
   556
defaultNameSpace
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   557
    "return the defaultNameSpace of this project.
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   558
     New classes will (if not specified by a directive) be installed
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   559
     in this nameSpace. Useful, when filing in ST-80 code, to avoid
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   560
     overwriting of standard classes."
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   561
4726
5c5e1c7f8933 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4721
diff changeset
   562
    ^ (self propertyAt:#defaultNameSpace) ? Smalltalk
2028
85ef24870d8a hold the default nameSpace
Claus Gittinger <cg@exept.de>
parents: 1854
diff changeset
   563
85ef24870d8a hold the default nameSpace
Claus Gittinger <cg@exept.de>
parents: 1854
diff changeset
   564
!
85ef24870d8a hold the default nameSpace
Claus Gittinger <cg@exept.de>
parents: 1854
diff changeset
   565
85ef24870d8a hold the default nameSpace
Claus Gittinger <cg@exept.de>
parents: 1854
diff changeset
   566
defaultNameSpace:aNamespace
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   567
    "set the defaultNameSpace of this project.
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   568
     New classes will (if not specified by a directive) be installed
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   569
     in this nameSpace. Useful, when filing in ST-80 code, to avoid
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   570
     overwriting of standard classes."
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   571
4726
5c5e1c7f8933 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4721
diff changeset
   572
    |prevDefault|
5c5e1c7f8933 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4721
diff changeset
   573
5c5e1c7f8933 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4721
diff changeset
   574
    prevDefault := self defaultNameSpace.
5c5e1c7f8933 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4721
diff changeset
   575
    aNamespace ~~ prevDefault ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   576
	self propertyAt:#defaultNameSpace put:aNamespace.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   577
	self changed:#defaultNameSpace.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   578
	self == CurrentProject ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   579
	    Project changed:#defaultNameSpace 
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   580
	]
2032
e39ca6532e1a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2028
diff changeset
   581
    ]
2028
85ef24870d8a hold the default nameSpace
Claus Gittinger <cg@exept.de>
parents: 1854
diff changeset
   582
85ef24870d8a hold the default nameSpace
Claus Gittinger <cg@exept.de>
parents: 1854
diff changeset
   583
    "Created: 2.1.1997 / 19:54:37 / cg"
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   584
    "Modified: 27.1.1997 / 12:00:01 / cg"
2028
85ef24870d8a hold the default nameSpace
Claus Gittinger <cg@exept.de>
parents: 1854
diff changeset
   585
!
85ef24870d8a hold the default nameSpace
Claus Gittinger <cg@exept.de>
parents: 1854
diff changeset
   586
315
7683685383d6 *** empty log message ***
claus
parents: 236
diff changeset
   587
directory
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   588
    "return the projects directory.
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   589
     If not specified, a fileOut will be done into that directory"
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   590
315
7683685383d6 *** empty log message ***
claus
parents: 236
diff changeset
   591
    directoryName isNil ifTrue:[^ '.'].
7683685383d6 *** empty log message ***
claus
parents: 236
diff changeset
   592
    ^ directoryName
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   593
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   594
    "Modified: 27.1.1997 / 12:00:41 / cg"
315
7683685383d6 *** empty log message ***
claus
parents: 236
diff changeset
   595
!
7683685383d6 *** empty log message ***
claus
parents: 236
diff changeset
   596
7683685383d6 *** empty log message ***
claus
parents: 236
diff changeset
   597
directory:aDirectoryName
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   598
    "set the projects directory.
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   599
     If not specified, a fileOut will be done into that directory"
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   600
315
7683685383d6 *** empty log message ***
claus
parents: 236
diff changeset
   601
    directoryName := aDirectoryName.
4070
682f720cd0f6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4069
diff changeset
   602
    self changed:#directory.
315
7683685383d6 *** empty log message ***
claus
parents: 236
diff changeset
   603
    self == CurrentProject ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   604
	Project changed:#directory 
315
7683685383d6 *** empty log message ***
claus
parents: 236
diff changeset
   605
    ]
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   606
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   607
    "Modified: 27.1.1997 / 12:00:47 / cg"
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   608
!
356
claus
parents: 338
diff changeset
   609
4685
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   610
isLoaded:aBoolean
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   611
    isLoaded := aBoolean
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   612
!
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   613
4789
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
   614
libraryName
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
   615
    "return the projects library name.
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
   616
     This is the name of a classLibrary, created from this project"
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
   617
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
   618
    |nm|
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
   619
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
   620
    nm := self name.
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
   621
    ^ nm copyFrom:(nm lastIndexOfAny:':/')+1
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
   622
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
   623
"/    ^ (self name copyReplaceAll:$/ with:$_) replaceAll:$: with:$_
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
   624
!
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
   625
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   626
name
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   627
    "return the projects name.
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   628
     This is for the user only - shown in the projectViews label"
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   629
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   630
    ^ name
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   631
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   632
    "Modified: 27.1.1997 / 12:01:16 / cg"
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   633
!
356
claus
parents: 338
diff changeset
   634
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   635
name:aString
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   636
    "set the projects name.
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   637
     This is for the user only - shown in the projectViews label"
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   638
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   639
    name := aString.
4070
682f720cd0f6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4069
diff changeset
   640
    self changed:#name.
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   641
    self == CurrentProject ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   642
	Project changed:#name
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   643
    ]
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   644
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   645
    "Modified: 27.1.1997 / 12:01:09 / cg"
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   646
!
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   647
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   648
overwrittenMethods
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   649
    "return the set of methods which were overwritten in this project.
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   650
     This information allows uninstalling, by switching back to the
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   651
     original methods."
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   652
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   653
    ^ overwrittenMethods
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   654
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   655
    "Created: 27.1.1997 / 11:57:21 / cg"
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   656
    "Modified: 27.1.1997 / 12:09:14 / cg"
356
claus
parents: 338
diff changeset
   657
!
claus
parents: 338
diff changeset
   658
4668
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   659
package
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   660
    "return the projects package identifier.
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   661
     This identifier marks all methods and new classes which were created
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   662
     in this project."
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   663
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   664
    ^ packageName
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   665
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   666
    "Modified: 27.1.1997 / 12:10:00 / cg"
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   667
!
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
   668
4685
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   669
package:aPackageId
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   670
    "set the projects package identifier.
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   671
     This identifier marks all methods and new classes which were created
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   672
     in this project."
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   673
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   674
    packageName := aPackageId
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   675
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   676
    "Modified: 27.1.1997 / 12:10:00 / cg"
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   677
!
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
   678
4727
ec580e5f9b22 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4726
diff changeset
   679
packageName:aPackageId
ec580e5f9b22 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4726
diff changeset
   680
    "set the projects package identifier.
ec580e5f9b22 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4726
diff changeset
   681
     This identifier marks all methods and new classes which were created
ec580e5f9b22 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4726
diff changeset
   682
     in this project."
ec580e5f9b22 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4726
diff changeset
   683
ec580e5f9b22 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4726
diff changeset
   684
    self package:aPackageId
ec580e5f9b22 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4726
diff changeset
   685
ec580e5f9b22 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4726
diff changeset
   686
    "Modified: 27.1.1997 / 12:10:00 / cg"
ec580e5f9b22 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4726
diff changeset
   687
!
ec580e5f9b22 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4726
diff changeset
   688
4099
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
   689
prerequisiteClasses
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
   690
    "return the prerequisiteClasses of the project"
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
   691
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
   692
    ^ (self propertyAt:#prerequisiteClasses) ? #()
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
   693
!
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
   694
4124
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   695
prerequisiteClasses:aCollectionOfClassesOrClassNames
4099
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
   696
    "set the prerequisiteClasses of the project"
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
   697
4124
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   698
    ^ self propertyAt:#prerequisiteClasses put:aCollectionOfClassesOrClassNames
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   699
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   700
    "Modified: / 26.4.1999 / 23:33:44 / cg"
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   701
!
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   702
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   703
prerequisitePackages
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   704
    "return the prerequisitePackages of the project"
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   705
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   706
    ^ self prerequisites
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   707
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   708
    "Created: / 26.4.1999 / 23:33:22 / cg"
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   709
!
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   710
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   711
prerequisitePackages:aCollectionOfPackagesOrPackageNames
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   712
    "set the prerequisitePackages of the project"
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   713
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   714
    ^ self prerequisites:aCollectionOfPackagesOrPackageNames
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   715
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   716
    "Modified: / 26.4.1999 / 23:34:40 / cg"
4099
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
   717
!
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
   718
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   719
prerequisites
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
   720
    "return the prerequisites of the project"
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
   721
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   722
    ^ prerequisites ? #()
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   723
!
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   724
3973
7065a27b136b checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3972
diff changeset
   725
prerequisites:aCollectionOfProjects
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
   726
    "set the prerequisites of the project"
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
   727
3973
7065a27b136b checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3972
diff changeset
   728
    prerequisites := aCollectionOfProjects
7065a27b136b checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3972
diff changeset
   729
!
7065a27b136b checkin from browser
Claus Gittinger <cg@exept.de>
parents: 3972
diff changeset
   730
654
1e039f69fdee added repository
Claus Gittinger <cg@exept.de>
parents: 630
diff changeset
   731
repositoryDirectory
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   732
    "return the projects default repository location.
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   733
     This is offered initially, when classes are checked into the
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   734
     source repository initially"
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   735
725
02759b2003a8 keep module & directory separately (as defaults when creating a container)
Claus Gittinger <cg@exept.de>
parents: 705
diff changeset
   736
    ^ repositoryDirectory
654
1e039f69fdee added repository
Claus Gittinger <cg@exept.de>
parents: 630
diff changeset
   737
1e039f69fdee added repository
Claus Gittinger <cg@exept.de>
parents: 630
diff changeset
   738
    "Created: 25.11.1995 / 18:04:51 / cg"
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   739
    "Modified: 27.1.1997 / 12:13:35 / cg"
654
1e039f69fdee added repository
Claus Gittinger <cg@exept.de>
parents: 630
diff changeset
   740
!
1e039f69fdee added repository
Claus Gittinger <cg@exept.de>
parents: 630
diff changeset
   741
1e039f69fdee added repository
Claus Gittinger <cg@exept.de>
parents: 630
diff changeset
   742
repositoryDirectory:aRelativePathName
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   743
    "set the projects default repository location.
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   744
     This will be offered initially, when classes are checked into the
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   745
     source repository initially"
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   746
725
02759b2003a8 keep module & directory separately (as defaults when creating a container)
Claus Gittinger <cg@exept.de>
parents: 705
diff changeset
   747
    repositoryDirectory := aRelativePathName
654
1e039f69fdee added repository
Claus Gittinger <cg@exept.de>
parents: 630
diff changeset
   748
1e039f69fdee added repository
Claus Gittinger <cg@exept.de>
parents: 630
diff changeset
   749
    "Created: 25.11.1995 / 18:05:06 / cg"
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   750
    "Modified: 27.1.1997 / 12:13:28 / cg"
725
02759b2003a8 keep module & directory separately (as defaults when creating a container)
Claus Gittinger <cg@exept.de>
parents: 705
diff changeset
   751
!
02759b2003a8 keep module & directory separately (as defaults when creating a container)
Claus Gittinger <cg@exept.de>
parents: 705
diff changeset
   752
02759b2003a8 keep module & directory separately (as defaults when creating a container)
Claus Gittinger <cg@exept.de>
parents: 705
diff changeset
   753
repositoryModule
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   754
    "return the projects default repository module name.
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   755
     This is offered initially, when classes are checked into the
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   756
     source repository initially"
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   757
725
02759b2003a8 keep module & directory separately (as defaults when creating a container)
Claus Gittinger <cg@exept.de>
parents: 705
diff changeset
   758
    ^ repositoryModule
02759b2003a8 keep module & directory separately (as defaults when creating a container)
Claus Gittinger <cg@exept.de>
parents: 705
diff changeset
   759
02759b2003a8 keep module & directory separately (as defaults when creating a container)
Claus Gittinger <cg@exept.de>
parents: 705
diff changeset
   760
    "Created: 25.11.1995 / 18:04:51 / cg"
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   761
    "Modified: 27.1.1997 / 12:13:50 / cg"
725
02759b2003a8 keep module & directory separately (as defaults when creating a container)
Claus Gittinger <cg@exept.de>
parents: 705
diff changeset
   762
!
02759b2003a8 keep module & directory separately (as defaults when creating a container)
Claus Gittinger <cg@exept.de>
parents: 705
diff changeset
   763
02759b2003a8 keep module & directory separately (as defaults when creating a container)
Claus Gittinger <cg@exept.de>
parents: 705
diff changeset
   764
repositoryModule:aString
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   765
    "set the projects default repository module name.
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   766
     This is offered initially, when classes are checked into the
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   767
     source repository initially"
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   768
725
02759b2003a8 keep module & directory separately (as defaults when creating a container)
Claus Gittinger <cg@exept.de>
parents: 705
diff changeset
   769
    repositoryModule := aString
02759b2003a8 keep module & directory separately (as defaults when creating a container)
Claus Gittinger <cg@exept.de>
parents: 705
diff changeset
   770
02759b2003a8 keep module & directory separately (as defaults when creating a container)
Claus Gittinger <cg@exept.de>
parents: 705
diff changeset
   771
    "Created: 25.11.1995 / 18:05:06 / cg"
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   772
    "Modified: 27.1.1997 / 12:13:57 / cg"
654
1e039f69fdee added repository
Claus Gittinger <cg@exept.de>
parents: 630
diff changeset
   773
!
1e039f69fdee added repository
Claus Gittinger <cg@exept.de>
parents: 630
diff changeset
   774
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   775
subProjects
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
   776
    "return the subprojects - obsolete; we use prerequisites now"
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
   777
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   778
    ^ subProjects ? #()
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   779
!
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   780
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   781
views
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   782
    "return a collection of views which were opened in this project"
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   783
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   784
    ^ views asArray
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   785
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   786
    "Modified: 27.1.1997 / 12:14:18 / cg"
338
claus
parents: 336
diff changeset
   787
!
claus
parents: 336
diff changeset
   788
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   789
views:aSetOfViews
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   790
    "set the collection of views which were opened in this project"
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   791
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
   792
    views := WeakIdentitySet withAll:aSetOfViews
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   793
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   794
    "Modified: 27.1.1997 / 12:14:26 / cg"
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   795
! !
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   796
4079
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   797
!Project methodsFor:'administration'!
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   798
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   799
removeClassesFromSystem
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   800
    "remove the all of my classes & patches from the system"
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   801
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   802
    self classInfo do:[:clsInfo |
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   803
	|clsName cls|
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   804
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   805
	clsName := clsInfo className.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   806
	clsName isSymbol ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   807
	    cls := Smalltalk at:clsName.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   808
	    cls notNil ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   809
		cls removeFromSystem.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   810
	    ].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   811
	] ifFalse:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   812
	    self halt
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   813
	].
4079
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   814
    ].
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   815
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   816
!
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   817
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   818
removeFromSystem
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   819
    "remove the project and all of its classes & patches from the
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   820
     system"
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   821
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   822
    self removeClassesFromSystem.
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   823
    AllProjects remove:self ifAbsent:nil.
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   824
! !
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   825
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   826
!Project methodsFor:'changes'!
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   827
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   828
rememberOverwrittenMethod:newMethod from:oldMethod
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   829
    "this is sent whenever a method is installed, which overwrites
2334
7502902385ff only remember overwritten methods if the current project
Claus Gittinger <cg@exept.de>
parents: 2276
diff changeset
   830
     an existing method from a different package.
7502902385ff only remember overwritten methods if the current project
Claus Gittinger <cg@exept.de>
parents: 2276
diff changeset
   831
     Allows previous methods to be reconstructed."
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   832
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   833
    overwrittenMethods isNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   834
	overwrittenMethods := IdentityDictionary new.
2276
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   835
    ].
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   836
    overwrittenMethods at:newMethod put:oldMethod
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   837
4efec5219eef remember overwritten methods
Claus Gittinger <cg@exept.de>
parents: 2164
diff changeset
   838
    "Created: 27.1.1997 / 11:52:01 / cg"
2334
7502902385ff only remember overwritten methods if the current project
Claus Gittinger <cg@exept.de>
parents: 2276
diff changeset
   839
    "Modified: 30.1.1997 / 21:10:51 / cg"
10
claus
parents: 2
diff changeset
   840
! !
claus
parents: 2
diff changeset
   841
236
fa6d1f330010 *** empty log message ***
claus
parents: 235
diff changeset
   842
!Project methodsFor:'initialization'!
fa6d1f330010 *** empty log message ***
claus
parents: 235
diff changeset
   843
fa6d1f330010 *** empty log message ***
claus
parents: 235
diff changeset
   844
initialize
338
claus
parents: 336
diff changeset
   845
    |numString|
claus
parents: 336
diff changeset
   846
330
claus
parents: 318
diff changeset
   847
    views := WeakIdentitySet new.
338
claus
parents: 336
diff changeset
   848
    numString := NextSequential printString.
315
7683685383d6 *** empty log message ***
claus
parents: 236
diff changeset
   849
    NextSequential := NextSequential + 1.
338
claus
parents: 336
diff changeset
   850
claus
parents: 336
diff changeset
   851
    name := 'new Project-' , numString.
claus
parents: 336
diff changeset
   852
    packageName := 'private-' , numString.
2034
1c96469c3df8 preinit the defaultNamespace of new projects (to Smalltalk)
Claus Gittinger <cg@exept.de>
parents: 2032
diff changeset
   853
848
76a83f34c26a moved ExtBytes & ExtFunc from libbasic2
Claus Gittinger <cg@exept.de>
parents: 725
diff changeset
   854
    "/
76a83f34c26a moved ExtBytes & ExtFunc from libbasic2
Claus Gittinger <cg@exept.de>
parents: 725
diff changeset
   855
    "/ for tiny-configurations, allow ChangeSet to be absent
76a83f34c26a moved ExtBytes & ExtFunc from libbasic2
Claus Gittinger <cg@exept.de>
parents: 725
diff changeset
   856
    "/
76a83f34c26a moved ExtBytes & ExtFunc from libbasic2
Claus Gittinger <cg@exept.de>
parents: 725
diff changeset
   857
    ChangeSet notNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   858
	changeSet := ChangeSet new.
848
76a83f34c26a moved ExtBytes & ExtFunc from libbasic2
Claus Gittinger <cg@exept.de>
parents: 725
diff changeset
   859
    ].
654
1e039f69fdee added repository
Claus Gittinger <cg@exept.de>
parents: 630
diff changeset
   860
    self directory:'.'.
725
02759b2003a8 keep module & directory separately (as defaults when creating a container)
Claus Gittinger <cg@exept.de>
parents: 705
diff changeset
   861
    self repositoryModule:(OperatingSystem getLoginName).
654
1e039f69fdee added repository
Claus Gittinger <cg@exept.de>
parents: 630
diff changeset
   862
    self repositoryDirectory:'private'
1e039f69fdee added repository
Claus Gittinger <cg@exept.de>
parents: 630
diff changeset
   863
1e039f69fdee added repository
Claus Gittinger <cg@exept.de>
parents: 630
diff changeset
   864
    "Created: 25.11.1995 / 18:05:44 / cg"
2034
1c96469c3df8 preinit the defaultNamespace of new projects (to Smalltalk)
Claus Gittinger <cg@exept.de>
parents: 2032
diff changeset
   865
    "Modified: 3.1.1997 / 13:24:10 / cg"
236
fa6d1f330010 *** empty log message ***
claus
parents: 235
diff changeset
   866
! !
fa6d1f330010 *** empty log message ***
claus
parents: 235
diff changeset
   867
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   868
!Project methodsFor:'load & save'!
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   869
4805
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   870
conditionForAutoloadIsTrue:cond
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   871
    "check condition ..."
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   872
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   873
    ^ cond == #autoload 
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   874
!
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   875
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   876
conditionForInclusionIsTrue:cond
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   877
    "check condition ..."
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   878
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   879
    cond == #always ifTrue:[^ true].
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   880
    cond == #autoload ifTrue:[^ true].
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   881
    cond == #never ifTrue:[^ false].
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   882
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   883
    cond == #unix ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   884
	^ OperatingSystem isUNIXlike
4805
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   885
    ].
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   886
    cond == #win32 ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   887
	^ OperatingSystem isMSWINDOWSlike
4805
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   888
    ].
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   889
    cond == #vms ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   890
	^ OperatingSystem isVMSlike
4805
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   891
    ].
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   892
    cond == #macos ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   893
	^ OperatingSystem isMAClike
4805
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   894
    ].
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   895
    self halt:'bad condition'
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   896
!
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   897
4079
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   898
loadClassesFromProjectDirectory
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   899
    "load my classes into the system.
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   900
     The classes are loaded from the directory as defined by my
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   901
     directory insTvar"
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   902
4805
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   903
    |myDirectory firstTrip|
4079
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   904
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   905
    myDirectory := self directory asFilename.
4805
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   906
    firstTrip := true.
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   907
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   908
    "/ read twice; if the load order was not correct,
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   909
    "/ this will fix things (i.e. nil superclasses ...)
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   910
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
   911
    2 timesRepeat:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   912
	self classInfo do:[:clsInfo |
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   913
	    |clsName clsFileNameString cls clsFilename 
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   914
	     cond include asAutoload|
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   915
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   916
	    clsName := clsInfo className.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   917
	    clsFileNameString := clsInfo classFileName.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   918
	    clsFileNameString isNil ifTrue:[clsFileNameString := clsName , '.st'].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   919
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   920
	    clsName isSymbol ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   921
		clsFilename := myDirectory construct:clsFileNameString.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   922
		cls := Smalltalk at:clsName.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   923
		(cls isNil or:[firstTrip]) ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   924
		    "/ ok - really not yet loaded.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   925
		    Transcript showCR:'loading ' , clsFilename pathName , ' ...'.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   926
		] ifFalse:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   927
		    Transcript showCR:'reloading ' , clsFilename pathName , ' ...'.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   928
		].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   929
		"/ check condition ...
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   930
		cond := clsInfo conditionForInclusion.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   931
		(self conditionForInclusionIsTrue:cond) ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   932
		    (self conditionForAutoloadIsTrue:cond) ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   933
			Smalltalk
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   934
			    installAutoloadedClassNamed:clsName
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   935
			    category:'autoloaded'
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   936
			    package:self package    
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   937
			    revision:nil
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   938
		    ] ifFalse:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   939
			Smalltalk fileIn:clsFilename
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   940
		    ]
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   941
		]
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   942
	    ] ifFalse:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   943
		self halt
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   944
	    ].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   945
	].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   946
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
   947
	firstTrip := false.
4079
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   948
    ].
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   949
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   950
!
84ad7326cc62 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4078
diff changeset
   951
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   952
loadFromProjectFile:aFilename
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
   953
    "fill all of my attributes from a projects file (.prj-file)"
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
   954
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
   955
    |f l pack targetConditions s sourcesSubDir files module methodsFile|
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   956
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   957
    f := aFilename asFilename.
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
   958
    directoryName := f directory pathName.
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
   959
    self directory:(f directory pathName).
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
   960
    pack := ResourcePack fromFile:f baseName directory:directoryName.
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
   961
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
   962
    "/ convert the resourcePack ...
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
   963
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
   964
    packageName := pack at:'package' ifAbsent:packageName.
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
   965
    name := pack at:'name' ifAbsent:name.
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
   966
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
   967
    self type:(pack at:'type' ifAbsent:#application) asSymbol.
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
   968
4124
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   969
    module := pack at:'repository.module' ifAbsent:nil.
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   970
    module notNil ifTrue:[
4833
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
   971
        repositoryModule := module.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
   972
        repositoryDirectory := pack at:'repository.directory' ifAbsent:''.
4124
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
   973
    ].
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
   974
4099
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
   975
    prerequisites := pack at:'prerequisites' ifAbsent:#().
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
   976
    self prerequisiteClasses:(pack at:'prerequisiteClasses' ifAbsent:#()).
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
   977
4074
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
   978
    s := pack at:'nameSpace' ifAbsent:nil.
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
   979
    s notNil ifTrue:[
4833
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
   980
        self defaultNameSpace:(Namespace name:s asSymbol).
4074
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
   981
    ].
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
   982
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
   983
    subProjects := pack at:'subProjects' ifAbsent:subProjects.
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
   984
    (s := pack at:'comment' ifAbsent:nil) notNil ifTrue:[
4833
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
   985
        self comment:s
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
   986
    ].
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
   987
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
   988
    "/ first, all of the conditions ...
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
   989
    targetConditions := Dictionary new.
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
   990
    pack keysAndValuesDo:[:key :val |
4833
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
   991
        |conditionKey|
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
   992
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
   993
        (key startsWith:'target.condition.') ifTrue:[
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
   994
            conditionKey := key copyFrom:'target.condition.' size + 1.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
   995
            targetConditions at:conditionKey put:val.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
   996
        ]
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
   997
    ].
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
   998
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
   999
    properties isNil ifTrue:[
4833
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1000
        properties := IdentityDictionary new
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  1001
    ].
4124
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1002
    properties at:#'targetconditions' put:targetConditions.
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1003
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1004
    sourcesSubDir := pack at:'sources' ifAbsent:nil.
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1005
    sourcesSubDir notNil ifTrue:[
4833
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1006
        properties at:#'sourcesDirectory' put:sourcesSubDir.
4124
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1007
    ].
4833
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1008
"/    methodsFile := pack at:'methodsFile' ifAbsent:nil.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1009
"/    methodsFile size > 0 ifTrue:[
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1010
"/        properties at:#'methodsFile' put:methodsFile.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1011
"/    ].
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1012
    properties declare:#methodsFile from:pack.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1013
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1014
"/    files := pack at:'files' ifAbsent:nil.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1015
"/    files notNil ifTrue:[
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1016
"/        properties at:#'files' put:files.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1017
"/    ].
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1018
    properties declare:#files from:pack.
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  1019
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  1020
    "/ fetch class info
4805
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
  1021
    "/
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
  1022
    "/ each entry consist of:
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
  1023
    "/    full-name-of-class
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
  1024
    "/    condition (optional)  - #unix / #win32 / #vms / #macos / #always / #never / #autoload
a7e6d2cb9b29 care for conditions when generatong loadAll / Make.proto files.
Claus Gittinger <cg@exept.de>
parents: 4796
diff changeset
  1025
    "/    fileName (optional)
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  1026
    (pack at:'classes' default:#()) do:[:info |
4833
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1027
        |condKey className optionalFileName|
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1028
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1029
        condKey := #always.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1030
        info isSymbol ifTrue:[
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1031
            className := info.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1032
        ] ifFalse:[
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1033
            className := info at:1.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1034
            info size > 1 ifTrue:[
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1035
                condKey := info at:2.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1036
                info size > 2 ifTrue:[
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1037
                    optionalFileName := info at:3.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1038
                ]
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1039
            ].
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1040
        ].
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1041
        self 
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1042
            addClass:className 
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1043
            conditionForInclusion:condKey 
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1044
            classFileName:optionalFileName
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  1045
    ].
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1046
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  1047
    "/ fetch methods info
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  1048
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  1049
    (pack at:'methods' default:#()) do:[:info |
4833
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1050
        |condKey className methodName optionalFileName|
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1051
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1052
        condKey := #always.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1053
        className := info at:1.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1054
        methodName := info at:2.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1055
        info size > 2 ifTrue:[
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1056
            optionalFileName := info at:3.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1057
            info size > 3 ifTrue:[
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1058
                condKey := info at:4.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1059
            ]
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1060
        ].
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1061
        self 
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1062
            addMethod:methodName inClass:className 
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1063
            conditionForInclusion:condKey 
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1064
            fileName:optionalFileName
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  1065
    ].
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  1066
4069
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
  1067
    self wasLoadedFromFile:true.
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
  1068
4099
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
  1069
    "/ all remaining properties
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
  1070
    pack keysAndValuesDo:[:key :val |
4833
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1071
        (key startsWith:'property.') ifTrue:[
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1072
            self propertyAt:(key copyFrom:'property.' size+1) asSymbol put:val.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1073
        ]
4099
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
  1074
    ].
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
  1075
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1076
    "
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1077
     Project current saveAsProjectFile.
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1078
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1079
     Project new loadFromProjectFile:'default.prj'
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1080
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  1081
     Project new loadFromProjectFile:'../../libbasic/libbasic.prj'
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1082
    "
4069
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
  1083
4124
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1084
    "Modified: / 26.4.1999 / 23:21:33 / cg"
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1085
!
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1086
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1087
saveAsProjectFile
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1088
    "store all of my attributes into a projects file (.prj-file)
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1089
     (in the project-directory and named as <projectName>.prj)"
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1090
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1091
    |dir fn nm s|
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1092
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1093
    dir := self directory asFilename.
4790
38030fd8b681 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4789
diff changeset
  1094
    nm := self libraryName.
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1095
    fn := dir construct:nm.
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1096
    fn := fn withSuffix:'prj'.
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1097
4124
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1098
    fn exists ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  1099
	fn copyTo:(fn pathName , '.bak')
4124
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1100
    ].
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1101
    s := fn writeStream.
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1102
    self saveAsProjectFileOn:s.
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1103
    s close.
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1104
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1105
    "
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1106
     Project current saveAsProjectFile
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1107
    "
4124
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1108
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1109
    "Modified: / 26.4.1999 / 22:53:38 / cg"
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1110
!
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1111
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1112
saveAsProjectFileOn:aStream
4074
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1113
    "save the project info in a format which is both usable for reload
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1114
     and somehow readable for humans.
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1115
     Actually, the format is the same as used for resources (i.e. key - value pairs)
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1116
     and the code below could be much simpler - if there where no humans to read it ..."
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1117
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1118
    |s coll first maxLen t defNS methodsFile classes|
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1119
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1120
    s := aStream.
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1121
4099
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
  1122
    s nextPutLine:'; $Header' , '$'; nextPutLine:';'.
4074
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1123
    s nextPutLine:'; Project saved ' , Smalltalk timeStamp; nextPutLine:';'.
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1124
    s nextPutAll:'; Be careful when editing - do not corrupt the files syntax.
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1125
; Lines starting with a semicolon are comment lines.
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1126
; Lines ending with a backslash are concatenated with the following line.
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1127
; Entries are key-value pairs, separated by whitespace;
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1128
; the value is a smalltalk literal expression.
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1129
'.
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1130
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1131
    s nextPutAll:'
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1132
;
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1133
; general:
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1134
;
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1135
'.
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  1136
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  1137
    s nextPutAll:'comment'. 
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  1138
    s tab. s nextPutLine:(self comment storeString).
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  1139
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  1140
    s nextPutAll:'name'. 
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1141
    s tab. s nextPutLine:(name storeString).
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  1142
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  1143
    s nextPutAll:'type'. 
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1144
    s tab. s nextPutLine:(self type storeString).
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  1145
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  1146
    s nextPutAll:'package'. 
4726
5c5e1c7f8933 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4721
diff changeset
  1147
    s tab. s nextPutLine:(self package storeString).
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1148
4726
5c5e1c7f8933 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4721
diff changeset
  1149
    defNS := self defaultNameSpace.
5c5e1c7f8933 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4721
diff changeset
  1150
    (defNS ~~ Smalltalk) ifTrue:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1151
        s nextPutAll:'nameSpace'. 
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1152
        s tab. s nextPutLine:(defNS name storeString).
4074
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1153
    ].
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1154
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1155
    s nextPutAll:'
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1156
;
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1157
; repository:
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1158
;
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1159
'.
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  1160
    s nextPutAll:'repository.module'. 
4099
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
  1161
    s tab. s nextPutLine:(repositoryModule ? 'private') storeString.
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  1162
    s nextPutAll:'repository.directory'. 
4726
5c5e1c7f8933 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4721
diff changeset
  1163
    s tab. s nextPutLine:(repositoryDirectory ? self package) storeString.
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  1164
    s cr.
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  1165
4124
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1166
    (t := properties at:#'sourcesDirectory' ifAbsent:nil) notNil ifTrue:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1167
        s nextPutAll:'sources'. 
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1168
        s tab. s nextPutLine:(t storeString).
4124
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1169
    ].
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1170
4074
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1171
    first := true.
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  1172
    properties keysAndValuesDo:[:key :val |
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1173
        (#(
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1174
            comment
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1175
            wasLoadedFromFile
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1176
            targetconditions
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1177
            classes
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1178
            classInfo
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1179
            methodInfo
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1180
            prerequisiteClasses
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1181
            files
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1182
            sourcesDirectory
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1183
            methodsFile
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1184
            type
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1185
            defaultNameSpace
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1186
        ) includes:key) ifFalse:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1187
            first ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1188
                first := false.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1189
                s nextPutAll:'
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1190
;
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1191
; properties:
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1192
;
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1193
'.
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1194
            ].    
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1195
            s nextPutAll:'property.'; nextPutAll:key. 
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1196
            s tab. 
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1197
            key == #defaultNameSpace ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1198
                s nextPutLine:val name storeString.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1199
            ] ifFalse:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1200
                s nextPutLine:val storeString.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1201
            ]
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1202
        ]
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  1203
    ].
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1204
        
4074
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1205
"/    coll := self subProjects.
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1206
"/    coll size > 0 ifTrue:[
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1207
"/        s nextPutLine:'[subprojects]'. 
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1208
"/        coll do:[:aSubProject |
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1209
"/            s tab. s nextPutLine:(aSubProject name soreString).
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1210
"/        ].
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1211
"/    ].
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1212
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1213
    s nextPutAll:'
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1214
;
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1215
; required packages:
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1216
;
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1217
'.
4074
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1218
    s nextPutAll:'prerequisites'; tab.
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1219
    coll := self prerequisites.
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1220
    coll size = 0 ifTrue:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1221
        s nextPutLine:'#()'. 
4074
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1222
    ] ifFalse:[    
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1223
        s nextPutLine:'#( \'. 
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1224
        coll do:[:aProjectOrProjectNameList |
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1225
            |pName pPath|
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1226
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1227
            aProjectOrProjectNameList isString ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1228
                pName := aProjectOrProjectNameList.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1229
            ] ifFalse:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1230
                aProjectOrProjectNameList isArray ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1231
                    pName := aProjectOrProjectNameList at:1.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1232
                    pPath := aProjectOrProjectNameList at:2.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1233
                ] ifFalse:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1234
                    pName := aProjectOrProjectNameList name.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1235
                    pPath := aProjectOrProjectNameList repositoryPath.    
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1236
                ]
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1237
            ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1238
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1239
            pPath isNil ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1240
                s tab. s nextPutAll:(pName storeString); nextPutLine:' \'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1241
            ] ifFalse:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1242
                s tab. s nextPutAll:'( '.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1243
                s nextPutAll:(pName storeString); space;
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1244
                  nextPutAll:(pPath storeString); nextPutLine:') \'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1245
            ]
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1246
        ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1247
        s nextPutLine:')'.
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1248
    ].
4124
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1249
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1250
    s nextPutAll:'
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1251
;
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1252
; required classes:
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1253
;
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1254
'.
4099
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
  1255
    s nextPutAll:'prerequisiteClasses'; tab.
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
  1256
    coll := self prerequisiteClasses.
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1257
    coll size = 0 ifTrue:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1258
        s nextPutLine:'#()'. 
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1259
    ] ifFalse:[    
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1260
        s nextPutLine:'#( \'. 
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1261
        coll do:[:aClassOrSymbol | |className|
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1262
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1263
            (className := aClassOrSymbol) isSymbol ifFalse:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1264
                className := aClassOrSymbol name
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1265
            ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1266
            s tab. s nextPutAll:(className storeString); nextPutLine:' \'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1267
        ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1268
        s nextPutLine:')'.
4099
f6984fc5cb6c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4097
diff changeset
  1269
    ].
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1270
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1271
    s nextPutAll:'
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1272
;
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1273
; classes:
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1274
; (for each class, one line of the form: ( #''className'' [condition [fileName]] )
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1275
; (where fileName and condition are optional)
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1276
;
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1277
'.
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1278
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1279
    s nextPutAll:'classes'; tab.
4074
4db3db1fe7ff checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4073
diff changeset
  1280
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1281
    classes := self classesInOrderFor:'save ''prj''-file.'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1282
    classes isNil ifTrue:[^ self].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1283
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1284
    classes size = 0 ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1285
        s nextPutLine:'#()'. 
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1286
    ] ifFalse:[    
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1287
        s nextPutLine:'#( \'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1288
        "/ find the longest className (for layout only)
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1289
        
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1290
        maxLen := classes inject:0 into:[:maxSoFar :aClass |
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1291
                                        |clsName|
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1292
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1293
                                        clsName := aClass name.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1294
                                        maxSoFar max:clsName storeString size
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1295
                                     ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1296
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1297
        classes do:[:aClass |
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1298
            |clsInfo clsName fileName cond|
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1299
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1300
            clsInfo := self classInfoFor:aClass.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1301
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1302
            clsName := aClass name.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1303
            fileName := clsInfo classFileName.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1304
            fileName = (clsName , '.st') ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1305
                fileName := nil
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1306
            ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1307
            cond := (clsInfo conditionForInclusion) ? #always.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1308
            s tab. s nextPutAll:'( '; 
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1309
                     nextPutAll:(clsName storeString paddedTo:maxLen).
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1310
            (cond ~~ #always or:[fileName notNil]) ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1311
                s tab; nextPutAll:cond storeString.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1312
            ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1313
            fileName notNil ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1314
                s tab; nextPutAll:fileName storeString.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1315
            ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1316
            s nextPutLine:') \'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1317
        ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1318
        s nextPutLine:')'.
4124
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1319
    ].
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1320
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1321
    s nextPutAll:'
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1322
;
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1323
; methods (patches & extensions):
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1324
; (for each method, one line of the form: ( #''className'' #''methodName'' )
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1325
; (for metaclasses, #''name class'' is used)
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1326
;
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1327
'.
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1328
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1329
    s nextPutAll:'methods'; tab.
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1330
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1331
    coll := self methodInfo.
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1332
    coll size = 0 ifTrue:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1333
        s nextPutLine:'#()'. 
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1334
    ] ifFalse:[    
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1335
        s nextPutLine:'#( \'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1336
        "/ find the longest className (for layout only)
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1337
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1338
        maxLen := coll inject:0 into:[:maxSoFar :aMethodInfo |
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1339
                                        |clsName|
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1340
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1341
                                        clsName := aMethodInfo className.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1342
                                        maxSoFar max:clsName storeString size
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1343
                                     ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1344
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1345
        coll do:[:aMethodInfo |
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1346
            |clsName mthdName fileName cond|
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1347
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1348
            clsName := aMethodInfo className.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1349
            mthdName := aMethodInfo methodName.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1350
            s tab. s nextPutAll:'( '; 
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1351
                     nextPutAll:(clsName storeString paddedTo:maxLen); 
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1352
                     tab; nextPutAll:mthdName storeString.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1353
            s nextPutLine:') \'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1354
        ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1355
        s nextPutLine:')'.
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1356
    ].
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1357
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1358
    methodsFile := properties at:#methodsFile ifAbsent:nil.
4792
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  1359
    methodsFile size > 0 ifTrue:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1360
        s cr; nextPutLine:';'; nextPutLine:'; methods above are stored in:'; nextPutLine:';'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1361
        s nextPutLine:';'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1362
        s nextPutAll:'methodsFile'; tab; nextPutLine:'''' , methodsFile , ''''.
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1363
    ].
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1364
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1365
    s nextPutAll:'
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1366
;
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1367
; files (for deployment):
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1368
;
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1369
'.
4314
b973832ffe15 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4124
diff changeset
  1370
4124
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1371
    s nextPutAll:'files'; tab.
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1372
    coll := properties at:#'files' ifAbsent:#().
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1373
    coll size = 0 ifTrue:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1374
        s nextPutLine:'#()'. 
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  1375
    ] ifFalse:[    
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1376
        s nextPutLine:'#( \'. 
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1377
        coll do:[:aFileEntry |
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1378
            s tab. s nextPutAll:(aFileEntry storeString); nextPutLine:' \'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1379
        ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1380
        s nextPutLine:')'.
4124
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1381
    ].
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1382
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1383
    "
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1384
     Project current saveOn:Transcript
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1385
    "
4124
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1386
06bfbaba171a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4119
diff changeset
  1387
    "Modified: / 26.4.1999 / 23:24:12 / cg"
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1388
! !
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  1389
2
claus
parents: 1
diff changeset
  1390
!Project methodsFor:'maintenance'!
claus
parents: 1
diff changeset
  1391
13
62303f84ff5f *** empty log message ***
claus
parents: 10
diff changeset
  1392
buildProject
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1393
    "invoke 'make' in the project directory"
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1394
13
62303f84ff5f *** empty log message ***
claus
parents: 10
diff changeset
  1395
    OperatingSystem executeCommand:('cd ' , self directory , ' ; make')
62303f84ff5f *** empty log message ***
claus
parents: 10
diff changeset
  1396
!
62303f84ff5f *** empty log message ***
claus
parents: 10
diff changeset
  1397
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1398
classesInOrderFor:whatMsg
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1399
    |classes numBad firstBad msg|
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1400
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1401
    classes := self classes.
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1402
    numBad := 0.
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1403
    firstBad := nil.
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1404
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1405
    classes := classes collect:[:clsOrSymbol |  |cls|
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1406
                                        clsOrSymbol isSymbol ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1407
                                            cls := Smalltalk at:clsOrSymbol.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1408
                                            cls isNil ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1409
                                                numBad := numBad + 1.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1410
                                                firstBad := firstBad ? clsOrSymbol.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1411
                                            ] ifFalse:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1412
                                                cls isLoaded ifFalse:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1413
                                                    cls autoLoad.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1414
                                                    cls isLoaded ifFalse:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1415
                                                        cls := nil
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1416
                                                    ]
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1417
                                                ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1418
                                            ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1419
                                            cls.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1420
                                        ] ifFalse:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1421
                                            clsOrSymbol
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1422
                                        ]
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1423
                              ].
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1424
    numBad ~~ 0 ifTrue:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1425
        msg := 'Cannot ' , whatMsg.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1426
        msg := msg , 'Reason: Class ''' , firstBad asText allBold
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1427
                   , ''' is not loaded.'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1428
        numBad ~~ 1 ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1429
            msg := msg , '\(' , (numBad-1) printString , ' more unloaded classes were found)'
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1430
        ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1431
        self warn:msg withCRs.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1432
        ^ nil.
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1433
    ].
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1434
4785
4ced52c817e6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4779
diff changeset
  1435
    "/ to not list private classes
4ced52c817e6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4779
diff changeset
  1436
    classes := classes select:[:cls | cls owningClass isNil].
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1437
    classes := classes copy topologicalSort:[:a :b | b isSubclassOf:a].
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1438
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1439
    ^ classes
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1440
!
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1441
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1442
createLoadAllFile
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1443
    "creates a 'loadAll' file, which will load all classes
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1444
     of the project - this loadAll file is supposed to be located
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1445
     in the projects source directory."
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1446
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1447
    |d f out in topName classes classInfo    
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1448
     methodsFile prerequisitePackages|
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1449
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1450
    classes := self classesInOrderFor:'generate ''loadAll''-file.'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1451
    classes isNil ifTrue:[^ self].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1452
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1453
    Transcript showCR:'creating loadAll file'.
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1454
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1455
    d := directoryName asFilename.
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1456
    f := d construct:'loadAll'.
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1457
    f exists ifTrue:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1458
        f renameTo:(d construct:'loadAll.bak')
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1459
    ].
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1460
    out := f writeStream.
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1461
    out isNil ifTrue:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1462
        self warn:'cannot create loadAll'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1463
        (d construct:'loadAll.bak') renameTo:f.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1464
        ^ self
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1465
    ].
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1466
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  1467
    out nextPutLine:'"/
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  1468
"/ $' , 'Header' , '$'.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  1469
    out nextPutLine:'"/
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  1470
"/ loadAll-file to fileIn code for: ' , self package.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  1471
    
4776
9e7ef3a357a4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4773
diff changeset
  1472
    out nextPutAll:'"/
9e7ef3a357a4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4773
diff changeset
  1473
"/ Automatically generated from project definition.
4786
2375c3d2bffc checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4785
diff changeset
  1474
"/ DO NOT MODIFY THIS fILE;
4789
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  1475
"/ modify the .prj file instead, and regenerate this file
4786
2375c3d2bffc checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4785
diff changeset
  1476
"/ with the ProjectBrowser tool.
4776
9e7ef3a357a4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4773
diff changeset
  1477
"/
9e7ef3a357a4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4773
diff changeset
  1478
9e7ef3a357a4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4773
diff changeset
  1479
"/
9e7ef3a357a4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4773
diff changeset
  1480
"/ Prerequisites:
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  1481
"/'.
4796
eee167a75fcd checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4792
diff changeset
  1482
    prerequisitePackages := self prerequisitePackages 
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1483
                                collect:[:entry |
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1484
                                    |pName|
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1485
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1486
                                    entry isString ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1487
                                        pName := entry
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1488
                                    ] ifFalse:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1489
                                        entry isArray ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1490
                                            pName := entry at:1
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1491
                                        ] ifFalse:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1492
                                            pName := entry name
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1493
                                        ]
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1494
                                    ]
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1495
                                ].
4796
eee167a75fcd checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4792
diff changeset
  1496
eee167a75fcd checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4792
diff changeset
  1497
    prerequisitePackages size == 0 ifTrue:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1498
        out nextPutLine:''.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1499
        out nextPutLine:'"/ Smalltalk loadPackage:''module:directory''.'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1500
        out nextPutLine:'"/ Smalltalk loadPackage:''....''.'.
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  1501
    ] ifFalse:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1502
        out cr.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1503
        prerequisitePackages do:[:packName |
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1504
            out nextPutLine:'Smalltalk loadPackage:''' , packName , '''.'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1505
        ]
4796
eee167a75fcd checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4792
diff changeset
  1506
    ].
eee167a75fcd checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4792
diff changeset
  1507
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  1508
    out nextPutAll:'!!
4776
9e7ef3a357a4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4773
diff changeset
  1509
9e7ef3a357a4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4773
diff changeset
  1510
"{ package:''' , self package , ''' }"!!
9e7ef3a357a4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4773
diff changeset
  1511
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1512
|files|
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1513
4785
4ced52c817e6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4779
diff changeset
  1514
''loading package ' , self package , ' ...'' infoPrintCR.
4776
9e7ef3a357a4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4773
diff changeset
  1515
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1516
files := #(
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  1517
.
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1518
'.
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1519
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1520
    classes do:[:cls |
4833
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1521
        |clsInfo cond fileName|
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1522
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1523
        clsInfo := self classInfoFor:cls.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1524
        cond := clsInfo conditionForInclusion.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1525
        (cond == #always or:[cond == #autoload]) ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1526
            out nextPutAll:'  '''.
4833
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1527
            fileName := clsInfo classFileName.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1528
            fileName isNil ifTrue:[
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1529
                fileName := cls nameWithoutNameSpacePrefix
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1530
            ].
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1531
            (fileName endsWith:'.st') ifFalse:[
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1532
                fileName := fileName , '.st'
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1533
            ].
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1534
            fileName printOn:out.
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1535
            out nextPutAll:'.st'''.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1536
            out cr.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1537
        ]
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1538
    ].
4792
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  1539
    (methodsFile := self propertyAt:#methodsFile) size > 0 ifTrue:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1540
         out 
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1541
            nextPutAll:'  ''';
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1542
            nextPutAll:methodsFile;
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1543
            nextPutAll:'''';
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1544
            cr.
4785
4ced52c817e6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4779
diff changeset
  1545
    ].
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1546
4776
9e7ef3a357a4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4773
diff changeset
  1547
    out nextPutAll:') asOrderedCollection.
9e7ef3a357a4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4773
diff changeset
  1548
4789
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  1549
(Smalltalk loadClassLibraryIfAbsent:''' , self libraryName , ''') ifTrue:[
4776
9e7ef3a357a4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4773
diff changeset
  1550
    |handle loaded|
9e7ef3a357a4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4773
diff changeset
  1551
4785
4ced52c817e6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4779
diff changeset
  1552
    handle := ObjectFileLoader loadedObjectHandles 
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1553
                    detect:[:h | h package = ''' , self package , '''] ifNone:nil.
4776
9e7ef3a357a4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4773
diff changeset
  1554
    handle ifNotNil:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1555
        loaded := Set new:(handle classes size).
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1556
        handle classes do:[:c| c isMeta ifFalse:[loaded add:c classFilename]].
4785
4ced52c817e6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4779
diff changeset
  1557
'.
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  1558
    
4792
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  1559
    methodsFile size > 0 ifTrue:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1560
        out nextPutLine:('        loaded add:''' , methodsFile , '''.').
4785
4ced52c817e6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4779
diff changeset
  1561
    ].
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  1562
    out nextPutAll:'        files := files asOrderedCollection select:[:f| (loaded includes:f) not].
4776
9e7ef3a357a4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4773
diff changeset
  1563
    ].
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  1564
].
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1565
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1566
files do:[:s |
4785
4ced52c817e6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4779
diff changeset
  1567
    ''.'' infoPrint.
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1568
    Smalltalk fileIn:s.
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1569
].
4785
4ced52c817e6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4779
diff changeset
  1570
'' '' infoPrintCR.
4ced52c817e6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4779
diff changeset
  1571
'' done (' , self package , ').'' infoPrintCR.
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  1572
.'.
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1573
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1574
    out close
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1575
!
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  1576
2
claus
parents: 1
diff changeset
  1577
createMakefile
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  1578
    "creates an initial Makefile from a Make.proto file.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  1579
     Requires the stmkmf script"
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  1580
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  1581
    |d top|
2
claus
parents: 1
diff changeset
  1582
4821
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1583
    OperatingSystem isUNIXlike ifTrue:[
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1584
        Transcript showCR:'creating Makefile'.
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1585
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1586
        d := directoryName asFilename pathName.
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1587
        top := (d , '/' , (self findTopFrom:directoryName)) asFilename pathName.
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1588
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1589
        (OperatingSystem 
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1590
            executeCommand:('sh ' , top , '/rules/stmkmf')
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1591
            inDirectory:d) ifFalse:[
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1592
            self warn:'Could not execute stmkmf - no Makefile built.'
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1593
        ].
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1594
    ] ifFalse:[
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1595
        OperatingSystem isMSWINDOWSlike ifTrue:[
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1596
            self createNTMakefile
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1597
        ] ifFalse:[
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1598
            OperatingSystem isVMSlike ifTrue:[
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1599
                self createVMSMakefile
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1600
            ] ifFalse:[
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1601
                OperatingSystem isMAClike ifTrue:[
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1602
                    self createMacMakefile
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1603
                ] ifFalse:[
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1604
                    self warn:'Cannot create Makefile'
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1605
                ]
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1606
            ]
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1607
        ]
13
62303f84ff5f *** empty log message ***
claus
parents: 10
diff changeset
  1608
    ].
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  1609
4821
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  1610
    "Modified: / 26.9.1999 / 16:18:29 / cg"
2
claus
parents: 1
diff changeset
  1611
!
claus
parents: 1
diff changeset
  1612
4822
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1613
createNTMakefile
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1614
    "creates an nt.mak file"
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1615
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1616
    |d f s type appName libName startUpClass startUpSelector
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1617
     topName classes methodsFile|
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1618
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1619
    classes := self classesInOrderFor:'generate ''nt.mak''-file.'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  1620
    classes isNil ifTrue:[^ self].
4822
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1621
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1622
    topName := self findTopFrom:directoryName.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1623
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1624
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1625
    Transcript showCR:'creating bmake.bat'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1626
    d := directoryName asFilename.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1627
    f := d construct:'bmake.bat'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1628
    s := f writeStream.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1629
    s isNil ifTrue:[
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1630
        self warn:'cannot create bmake.bat'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1631
        ^ self
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1632
    ].
4824
1dad345e6e14 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4823
diff changeset
  1633
    s nextPutLine:'if not exist object\nul mkdir objbc'. 
4822
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1634
    s nextPutLine:'make.exe -N -f nt.mak %1 %'. 
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1635
    s close.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1636
4823
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1637
4822
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1638
    Transcript showCR:'creating bc.def'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1639
    d := directoryName asFilename.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1640
    f := d construct:'bc.def'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1641
    s := f writeStream.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1642
    s isNil ifTrue:[
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1643
        self warn:'cannot create bc.def'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1644
        ^ self
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1645
    ].
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1646
    s nextPutLine:'LIBRARY         ' , self libraryName.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1647
    s nextPutLine:'DESCRIPTION     ''AddOn library for ST/X''
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1648
CODE            PRELOAD MOVEABLE DISCARDABLE
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1649
SEGMENTS
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1650
    INITCODE PRELOAD SHARED DISCARDABLE
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1651
EXPORTS
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1652
    __' , self libraryName , '_Init     @1'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1653
    s close.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1654
4823
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1655
4822
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1656
    Transcript showCR:'creating nt.def'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1657
    d := directoryName asFilename.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1658
    f := d construct:'nt.def'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1659
    s := f writeStream.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1660
    s isNil ifTrue:[
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1661
        self warn:'cannot create nt.def'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1662
        ^ self
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1663
    ].
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1664
    s nextPutLine:'LIBRARY         ' , self libraryName.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1665
    s nextPutLine:'DESCRIPTION     ''AddOn library for ST/X''
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1666
CODE            EXECUTE READ SHARED
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1667
DATA            READ WRITE
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1668
SECTIONS
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1669
    INITCODE READ EXECUTE SHARED
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1670
    INITDATA READ WRITE
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1671
EXPORTS
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1672
    _' , self libraryName , '_Init'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1673
    s close.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1674
4823
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1675
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1676
    Transcript showCR:'creating libInit.cc'.
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1677
    d := directoryName asFilename.
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1678
    f := d construct:'libInit.cc'.
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1679
    s := f writeStream.
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1680
    s isNil ifTrue:[
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1681
        self warn:'cannot create libInit.cc'.
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1682
        ^ self
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1683
    ].
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1684
    s nextPutAll:'/*
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1685
 * DO NOT EDIT 
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1686
 * automatically generated from project.prj
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1687
 */
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1688
#define __INDIRECTVMINITCALLS__
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1689
#include <stc.h>
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1690
#define INIT_TEXT_SECT /* as nothing */
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1691
#ifdef WIN32
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1692
# pragma codeseg INITCODE "INITCODE"
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1693
#else /* not WIN32 */
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1694
# if defined(__GNUC__)
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1695
#  if (__GNUC__  == 2 && __GNUC_MINOR__ >= 7) || __GNUC__ > 2
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1696
#   undef INIT_TEXT_SECT
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1697
#   define INIT_TEXT_SECT __attribute__((section(".stxitext")))
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1698
#  endif
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1699
# endif /* not GNUC */
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1700
#endif /* not WIN32 */
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1701
#ifdef INIT_TEXT_SECT
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1702
extern void _' , self libraryName , '_Init() INIT_TEXT_SECT;
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1703
#endif
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1704
void _' , self libraryName , '_Init(pass, __pRT__, snd)
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1705
OBJ snd; struct __vmData__ *__pRT__; {
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1706
__BEGIN_PACKAGE2__("' , self libraryName , '", _' , self libraryName , '_Init, "' , self package , '");
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1707
'.
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1708
    classes notNil ifTrue:[
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1709
        classes do:[:aClass |
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1710
            |abbrev|
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1711
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1712
            abbrev := Smalltalk fileNameForClass:aClass name.
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1713
            s nextPutAll:'_'; nextPutAll:abbrev; nextPutLine:'_Init(pass,__pRT__,snd);'.
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1714
        ].
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1715
    ].
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1716
    s nextPutAll:'__END_PACKAGE__();
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1717
}
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1718
'.
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1719
    s close.
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1720
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1721
4822
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1722
    Transcript showCR:'creating nt.mak'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1723
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1724
    d := directoryName asFilename.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1725
    f := d construct:'nt.mak'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1726
    f exists ifTrue:[
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1727
        f renameTo:(d construct:'nt.mak.bak')
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1728
    ].
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1729
    s := f writeStream.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1730
    s isNil ifTrue:[
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1731
        self warn:'cannot create nt.mak'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1732
        ^ self
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1733
    ].
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1734
    s nextPutAll:'# $' , 'Header'. 
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1735
    s nextPutLine:'$'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1736
    s nextPutAll:'#
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1737
# -- nt.mak created from project at ' . 
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1738
    s nextPutAll:Smalltalk timeStamp. 
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1739
    s nextPutAll:'
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1740
#
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1741
# Warning: YOU SHOULD NOT MODIFY THIS FILE - MODIFY THE .prj FILE INSTEAD
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1742
# and let the ProjectBrowser recreate this file.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1743
# once you modify this file, do not recreate nt.mak again 
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1744
# - otherwise, your changes are lost.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1745
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1746
# module and directory-in-module;
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1747
# these should correspond to the directory hierarchy
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1748
# location (otherwise, ST/X will have a hard time to
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1749
# find out the packages location from its packageID)
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1750
MODULE=' , self repositoryModule ? 'unknown' , '
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1751
MODULE_DIR=' , self repositoryDirectory ? 'unknown' , '
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1752
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1753
# default installation directory:
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1754
# (overwrite with ''make INSTALLTOP_DIR=... install'')
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1755
# the INSTALLBASE is imported from configurations... and usually
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1756
# defaults to something like /opt/smalltalk.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1757
# (overwrite with ''make INSTALLBASE=... install'')
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1758
INSTALLTOP_DIR=$(INSTALLBASE)/packages/$(MODULE)/$(MODULE_DIR)
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1759
INSTALLLIB_DIR=$(INSTALLTOP_DIR)
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1760
INSTALLBIN_DIR=$(INSTALLTOP_DIR)
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1761
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1762
#
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1763
# position (of this package) in directory hierarchy:
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1764
# (must point to ST/X top directory, for tools and includes)
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1765
TOP=' , topName ,'
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1766
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1767
!!INCLUDE "$(TOP)\rules\stdHdrNT"
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1768
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1769
# subdirectories where targets are to be made:
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1770
SUBDIRS=
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1771
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1772
# subdirectories where Makefiles are to be made:
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1773
# (only define if different from SUBDIRS)
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1774
# ALLSUBDIRS=
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1775
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1776
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1777
# the name of your classLibrary:
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1778
# ********** REQUIRED: CHECK the next line ***
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1779
LIBNAME=' , self libraryName , '
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1780
4823
7308f4a53be6 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4822
diff changeset
  1781
LIB_BASE   =0x05000000
4822
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1782
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1783
# the next define suppresses installation of 
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1784
# the classes as autoloaded (i.e. not added to abbrev.stc). 
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1785
SUPPRESS_LOCAL_ABBREVS=1
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1786
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1787
# the package is stored as an ID in classes and methods
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1788
# to identify code belonging to this project.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1789
# It also specifies the position in the source repository
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1790
# and directory tree, when packages are loaded by packageID.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1791
# ********** REQUIRED: CHECK the next line ***
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1792
PACKAGE=$(MODULE):$(MODULE_DIR)
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1793
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1794
# Argument(s) to the stc compiler.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1795
#  -H.         : create header files locally
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1796
#                (if removed, they will be created as common
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1797
#  -Pxxx       : defines the package
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1798
#  -Zxxx       : a prefix for variables within the classLib
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1799
#  -Dxxx       : defines passed to to CC for inline C-code
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1800
#  -Ixxx       : include path passed to CC for inline C-code
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1801
#  +optspace   : optimized for space
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1802
#  +optspace2  : optimized more for space
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1803
#  +optspace3  : optimized even more for space
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1804
#  +optinline  : generate inline code for some ST constructs
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1805
#  +inlineNew  : additionally inline new
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1806
#  +inlineMath : additionally inline some floatPnt math stuff
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1807
#
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1808
# ********** OPTIONAL: MODIFY the next line(s) ***
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1809
# STCLOCALOPTIMIZATIONS=+optinline +inlineNew
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1810
# STCLOCALOPTIMIZATIONS=+optspace3
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1811
STCLOCALOPTIMIZATIONS=+optspace3
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1812
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1813
# Argument(s) to the stc compiler.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1814
#  -warn            : no warnings
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1815
#  -warnNonStandard : no warnings about ST/X extensions
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1816
#  -warnEOLComments : no warnings about EOL comment extension
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1817
#  -warnPrivacy     : no warnings about privateClass extension
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1818
#
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1819
# ********** OPTIONAL: MODIFY the next line(s) ***
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1820
# STCWARNINGS=-warn
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1821
# STCWARNINGS=-warnNonStandard
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1822
# STCWARNINGS=-warnEOLComments
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1823
STCWARNINGS='.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1824
        (self propertyAt:#'make.stc.warnEOLComments') == false ifTrue:[
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1825
            s nextPutAll:'-warnEOLComments '.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1826
        ].
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1827
        (self propertyAt:#'make.stc.warnNonStandard') == false ifTrue:[
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1828
            s nextPutAll:'-warnNonStandard '.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1829
        ].
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1830
        s nextPutAll:((self propertyAt:#'make.stc.WARNINGOPTIONS') ? '') , '
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1831
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1832
# if your embedded C code requires any system includes, 
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1833
# add the path(es) here:, 
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1834
# ********** OPTIONAL: MODIFY the next lines ***
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1835
# LOCALINCLUDES=-Ifoo -Ibar
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1836
LOCALINCLUDES=' , ((self propertyAt:#'make.stc.LOCALINCLUDES') ? '') , '
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1837
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1838
# if you need any additional defines for embedded C code, 
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1839
# add them here:, 
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1840
# ********** OPTIONAL: MODIFY the next lines ***
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1841
# LOCALDEFINES=-Dfoo -Dbar -DDEBUG
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1842
LOCALDEFINES=' , ((self propertyAt:#'make.stc.LOCALDEFINES') ? '') , '
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1843
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1844
STCLOCALOPT=-I. $(STCLOCALOPTIMIZATIONS) $(STCWARNINGS) $(LOCALINCLUDES) $(LOCALDEFINES) -H. ''-P$(PACKAGE)'' ''-varPrefix=$(LIBNAME)'' $(COMMONSYMFLAG) $(INITCODESEPFLAG)
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1845
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1846
# ********** OPTIONAL: MODIFY the next line ***
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1847
# additional C-libraries that should be pre-linked with the class-objects
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1848
LD_OBJ_LIBS=' , ((self propertyAt:#'make.LD_OBJ_LIBS') ? '') , '
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1849
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1850
# ********** OPTIONAL: MODIFY the next line ***
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1851
# additional C targets or libraries should be added below
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1852
LOCAL_EXTRA_TARGETS=' , ((self propertyAt:#'make.LOCAL_EXTRA_TARGETS') ? '') , '
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1853
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1854
#ALL:: preMake $(LIBDIR)\$(LIBNAME).lib $(BINDIR)\$(LIBNAME).dll postMake
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1855
ALL:: $(LIBDIR)\$(LIBNAME).lib $(BINDIR)\$(LIBNAME).dll
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1856
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1857
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1858
'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1859
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1860
"/    type := #library.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1861
"/    appName := 'app'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1862
"/    libName := 'lib'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1863
"/    startUpClass := 'Smalltalk'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1864
"/    startUpSelector := 'start'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1865
"/
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1866
"/    properties notNil ifTrue:[
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1867
"/        type := properties at:#projectType ifAbsent:type.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1868
"/        appName := properties at:#applicationName ifAbsent:appName.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1869
"/        startUpClass := properties at:#startupClass ifAbsent:startUpClass.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1870
"/        startUpSelector := properties at:#startupSelector ifAbsent:startUpSelector.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1871
"/    ].
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1872
"/
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1873
"/    s nextPutAll:'#
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1874
"/# define the name of the library to create
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1875
"/#
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1876
"/'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1877
"/    s nextPutAll:'LIBNAME=lib' , appName; cr; cr.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1878
"/
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1879
"/    s nextPutAll:'#
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1880
"/# the target rule:
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1881
"/#
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1882
"/all::   abbrev.stc objs genClassList $(OBJTARGET)
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1883
"/
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1884
"/'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1885
"/
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1886
"/    type == #executable ifTrue:[
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1887
"/        s nextPutAll:'PROGS = ' , appName; cr.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1888
"/        s nextPutAll:('STARTUP_CLASS=' , startUpClass); cr.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1889
"/        s nextPutAll:'STARTUP_SELECTOR="' , startUpSelector; nextPutAll:'"'; cr.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1890
"/    ].
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1891
"/
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1892
"/    s nextPutAll:'#
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1893
"/# define the object files that are to be created
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1894
"/#
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1895
"/'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1896
    s nextPutAll:'OBJS='.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1897
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1898
    classes do:[:aClass |
4833
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1899
        |fileName clsInfo cond include|
4822
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1900
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1901
        clsInfo := self classInfoFor:aClass.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1902
        include := true.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1903
        clsInfo notNil ifTrue:[
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1904
            cond := clsInfo conditionForInclusion.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1905
            (self conditionForInclusionIsTrue:cond) ifFalse:[
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1906
                include := false.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1907
            ] ifTrue:[
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1908
                (self conditionForAutoloadIsTrue:cond) ifTrue:[
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1909
                    include := false
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1910
                ]
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1911
            ].
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1912
        ].
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1913
        include ifTrue:[
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1914
            s nextPutAll:' \'. s cr.
4833
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1915
            fileName := clsInfo classFileName.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1916
            fileName isNil ifTrue:[
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1917
                fileName := Smalltalk fileNameForClass:aClass name.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1918
            ].
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1919
            fileName := fileName asFilename withoutSuffix name.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1920
            s nextPutAll:'  $(OUTDIR)'; nextPutAll:fileName; nextPutAll:'.$(O)'.
4822
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1921
        ]
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1922
    ].
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1923
    (methodsFile := self propertyAt:#methodsFile) size > 0 ifTrue:[
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1924
         s nextPutAll:' \'. s cr.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1925
         s nextPutAll:'  $(OUTDIR)'; 
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1926
           nextPutAll:(methodsFile asFilename withoutSuffix baseName);
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1927
           nextPutAll:'.$(O)'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1928
    ].
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1929
    s cr.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1930
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1931
    s nextPutAll:'
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1932
# add more install actions here
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1933
install:
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1934
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1935
# add more install actions for aux-files (resources) here
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1936
installAux:
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1937
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1938
# add more preMake actions here
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1939
preMake:
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1940
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1941
# add more postMake actions here
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1942
postMake: cleanjunk
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1943
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1944
#clean::
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1945
#' , Character tab , '-del $(OUTDIR)*.obj
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1946
#' , Character tab , '-del *.sc
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1947
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1948
#clobber::
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1949
#' , Character tab , '-del $(OUTDIR)*.obj
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1950
#' , Character tab , '-del *.sc
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1951
#' , Character tab , '-del *.dll
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1952
#' , Character tab , '-del *.lib
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1953
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1954
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1955
!!INCLUDE $(TOP)\rules\stdRulNT
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1956
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1957
# BEGINMAKEDEPEND --- do not remove this line; make depend needs it
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1958
'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1959
    classes notNil ifTrue:[
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1960
        classes do:[:aClass |
4833
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1961
            |fileName clsInfo|
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1962
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1963
            clsInfo := self classInfoFor:aClass.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1964
            fileName := clsInfo classFileName.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1965
            fileName isNil ifTrue:[
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1966
                fileName := Smalltalk fileNameForClass:aClass name.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1967
            ].
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1968
            fileName := fileName asFilename withoutSuffix name.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1969
            s nextPutAll:'$(OUTDIR)'; nextPutAll:fileName; nextPutAll:'.$(O): '.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  1970
            s nextPutAll:fileName; nextPutAll:'.st '.
4822
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1971
"/            aClass allSuperclassesDo:[:superClass|
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1972
"/                s nextPutAll:(Smalltalk fileNameForClass:superClass name) , '.$(H) '.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1973
"/            ].
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1974
            s nextPutAll:'$(STCHDR)';  cr.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1975
        ].
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1976
    ].
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1977
    s nextPutAll:'# ENDMAKEDEPEND --- do not remove this line'.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1978
    s cr; cr.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1979
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1980
    type == #executable ifTrue:[
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1981
        s nextPutAll:'ALL:: $(PROGS)'; cr.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1982
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1983
        s nextPutAll:appName.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1984
        s nextPutAll:':: main.$(O) classList.$(O) $(OBJS)'; cr.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1985
        s tab;      nextPutAll:'$(LD) $(ST_LDFLAG) $(LDFLAGS) -o ';
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1986
                    nextPutAll:appName;
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1987
                    nextPutAll:' \'; cr.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1988
        s tab; tab; nextPutAll:'$(CRT0) main.$(O) classList.$(O) $(OBJS) $(EXTRA_OBJ) $(LIBOBJS) \'; cr.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1989
        s tab; tab; nextPutAll:'$(LIBRUNDIR)/hidata.o $(LIBRUN) \'; cr.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1990
        s tab; tab; nextPutAll:'$(MATHLIB) $(EXTRALIBS) -lXext $(SYSLIBS) $(OTHERLIBS) $(CRTN)'; cr.
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1991
    ].
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1992
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1993
    s close
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1994
4824
1dad345e6e14 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4823
diff changeset
  1995
    "Modified: / 27.9.1999 / 00:23:16 / cg"
4822
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1996
!
5f37058e56c8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4821
diff changeset
  1997
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  1998
createProjectFiles
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  1999
    "actually, creates all files to do a make in the project directory"
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2000
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2001
    directoryName asFilename exists ifFalse:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2002
	(self confirm:'create new projectDirectory: ' , directoryName) 
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2003
	    ifFalse:[^ self].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2004
	OperatingSystem recursiveCreateDirectory:directoryName.
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2005
    ].
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2006
    self createMakefile.
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2007
    self createSourcefiles.
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2008
    self createProtoMakefile.
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2009
    (self propertyAt:#deliverLoadAllFile) == true ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2010
	self createLoadAllFile
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2011
    ].
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2012
!
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2013
2
claus
parents: 1
diff changeset
  2014
createProtoMakefile
claus
parents: 1
diff changeset
  2015
    "creates a Make.proto file"
claus
parents: 1
diff changeset
  2016
362
claus
parents: 356
diff changeset
  2017
    |d f s type appName libName startUpClass startUpSelector
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2018
     topName classes methodsFile|
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2019
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2020
    classes := self classesInOrderFor:'generate ''Make.proto''-file.'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2021
    classes isNil ifTrue:[^ self].
2
claus
parents: 1
diff changeset
  2022
362
claus
parents: 356
diff changeset
  2023
    topName := self findTopFrom:directoryName.
2
claus
parents: 1
diff changeset
  2024
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2025
1420
be5f8e9574cc showCr: -> showCR:
Claus Gittinger <cg@exept.de>
parents: 1332
diff changeset
  2026
    Transcript showCR:'creating Make.proto'.
13
62303f84ff5f *** empty log message ***
claus
parents: 10
diff changeset
  2027
356
claus
parents: 338
diff changeset
  2028
    d := directoryName asFilename.
2
claus
parents: 1
diff changeset
  2029
    f := d construct:'Make.proto'.
claus
parents: 1
diff changeset
  2030
    f exists ifTrue:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2031
        f renameTo:(d construct:'Make.proto.bak')
2
claus
parents: 1
diff changeset
  2032
    ].
claus
parents: 1
diff changeset
  2033
    s := f writeStream.
13
62303f84ff5f *** empty log message ***
claus
parents: 10
diff changeset
  2034
    s isNil ifTrue:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2035
        self warn:'cannot create prototype Makefile'.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2036
        ^ self
13
62303f84ff5f *** empty log message ***
claus
parents: 10
diff changeset
  2037
    ].
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2038
    s nextPutAll:'# $' , 'Header'. 
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2039
    s nextPutLine:'$'.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2040
    s nextPutAll:'#
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2041
# -- Make.proto created from project at ' . 
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2042
    s nextPutAll:Smalltalk timeStamp. 
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2043
    s nextPutAll:'
2
claus
parents: 1
diff changeset
  2044
#
4786
2375c3d2bffc checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4785
diff changeset
  2045
# Warning: YOU SHOULD NOT MODIFY THIS FILE - MODIFY THE .prj FILE INSTEAD
2375c3d2bffc checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4785
diff changeset
  2046
# and let the ProjectBrowser recreate this file.
2375c3d2bffc checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4785
diff changeset
  2047
# once you modify this file, do not rerun
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2048
# stmkmp or recreate the Make.proto again - otherwise, your changes are lost.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2049
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2050
# module and directory-in-module;
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2051
# these should correspond to the directory hierarchy
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2052
# location (otherwise, ST/X will have a hard time to
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2053
# find out the packages location from its packageID)
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2054
MODULE=' , self repositoryModule ? 'unknown' , '
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2055
MODULE_DIR=' , self repositoryDirectory ? 'unknown' , '
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2056
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2057
# default installation directory:
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2058
# (overwrite with ''make INSTALLTOP_DIR=... install'')
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2059
# the INSTALLBASE is imported from configurations... and usually
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2060
# defaults to something like /opt/smalltalk.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2061
# (overwrite with ''make INSTALLBASE=... install'')
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2062
INSTALLTOP_DIR=$(INSTALLBASE)/packages/$(MODULE)/$(MODULE_DIR)
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2063
INSTALLLIB_DIR=$(INSTALLTOP_DIR)
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2064
INSTALLBIN_DIR=$(INSTALLTOP_DIR)
362
claus
parents: 356
diff changeset
  2065
claus
parents: 356
diff changeset
  2066
#
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2067
# position (of this package) in directory hierarchy:
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2068
# (must point to ST/X top directory, for tools and includes)
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2069
TOP=' , topName ,'
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2070
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2071
# subdirectories where targets are to be made:
362
claus
parents: 356
diff changeset
  2072
SUBDIRS=
claus
parents: 356
diff changeset
  2073
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2074
# subdirectories where Makefiles are to be made:
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2075
# (only define if different from SUBDIRS)
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2076
# ALLSUBDIRS=
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2077
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2078
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2079
# the name of your classLibrary:
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2080
# ********** REQUIRED: CHECK the next line ***
4789
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2081
LIBNAME=' , self libraryName , '
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2082
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2083
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2084
# the next define suppresses installation of 
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2085
# the classes as autoloaded (i.e. not added to abbrev.stc). 
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2086
SUPPRESS_LOCAL_ABBREVS=1
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2087
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2088
# the package is stored as an ID in classes and methods
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2089
# to identify code belonging to this project.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2090
# It also specifies the position in the source repository
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2091
# and directory tree, when packages are loaded by packageID.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2092
# ********** REQUIRED: CHECK the next line ***
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2093
PACKAGE=$(MODULE):$(MODULE_DIR)
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2094
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2095
# Argument(s) to the stc compiler.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2096
#  -H.         : create header files locally
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2097
#                (if removed, they will be created as common
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2098
#  -Pxxx       : defines the package
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2099
#  -Zxxx       : a prefix for variables within the classLib
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2100
#  -Dxxx       : defines passed to to CC for inline C-code
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2101
#  -Ixxx       : include path passed to CC for inline C-code
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2102
#  +optspace   : optimized for space
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2103
#  +optspace2  : optimized more for space
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2104
#  +optspace3  : optimized even more for space
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2105
#  +optinline  : generate inline code for some ST constructs
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2106
#  +inlineNew  : additionally inline new
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2107
#  +inlineMath : additionally inline some floatPnt math stuff
362
claus
parents: 356
diff changeset
  2108
#
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2109
# ********** OPTIONAL: MODIFY the next line(s) ***
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2110
# STCLOCALOPTIMIZATIONS=+optinline +inlineNew
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2111
# STCLOCALOPTIMIZATIONS=+optspace3
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2112
STCLOCALOPTIMIZATIONS=+optspace3
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2113
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2114
# Argument(s) to the stc compiler.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2115
#  -warn            : no warnings
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2116
#  -warnNonStandard : no warnings about ST/X extensions
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2117
#  -warnEOLComments : no warnings about EOL comment extension
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2118
#  -warnPrivacy     : no warnings about privateClass extension
362
claus
parents: 356
diff changeset
  2119
#
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2120
# ********** OPTIONAL: MODIFY the next line(s) ***
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2121
# STCWARNINGS=-warn
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2122
# STCWARNINGS=-warnNonStandard
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2123
# STCWARNINGS=-warnEOLComments
4796
eee167a75fcd checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4792
diff changeset
  2124
STCWARNINGS='.
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2125
        (self propertyAt:#'make.stc.warnEOLComments') == false ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2126
            s nextPutAll:'-warnEOLComments '.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2127
        ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2128
        (self propertyAt:#'make.stc.warnNonStandard') == false ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2129
            s nextPutAll:'-warnNonStandard '.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2130
        ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2131
        s nextPutAll:((self propertyAt:#'make.stc.WARNINGOPTIONS') ? '') , '
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2132
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2133
# if your embedded C code requires any system includes, 
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2134
# add the path(es) here:, 
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2135
# ********** OPTIONAL: MODIFY the next lines ***
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2136
# LOCALINCLUDES=-Ifoo -Ibar
4796
eee167a75fcd checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4792
diff changeset
  2137
LOCALINCLUDES=' , ((self propertyAt:#'make.stc.LOCALINCLUDES') ? '') , '
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2138
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2139
# if you need any additional defines for embedded C code, 
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2140
# add them here:, 
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2141
# ********** OPTIONAL: MODIFY the next lines ***
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2142
# LOCALDEFINES=-Dfoo -Dbar -DDEBUG
4796
eee167a75fcd checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4792
diff changeset
  2143
LOCALDEFINES=' , ((self propertyAt:#'make.stc.LOCALDEFINES') ? '') , '
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2144
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2145
STCLOCALOPT=-I. $(STCLOCALOPTIMIZATIONS) $(STCWARNINGS) $(LOCALINCLUDES) $(LOCALDEFINES) -H. ''-P$(PACKAGE)'' ''-Z$(LIBNAME)'' $(COMMONSYMFLAG) $(INITCODESEPFLAG)
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2146
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2147
# ********** OPTIONAL: MODIFY the next line ***
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2148
# additional C-libraries that should be pre-linked with the class-objects
4796
eee167a75fcd checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4792
diff changeset
  2149
LD_OBJ_LIBS=' , ((self propertyAt:#'make.LD_OBJ_LIBS') ? '') , '
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2150
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2151
# ********** OPTIONAL: MODIFY the next line ***
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2152
# additional C targets or libraries should be added below
4796
eee167a75fcd checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4792
diff changeset
  2153
LOCAL_EXTRA_TARGETS=' , ((self propertyAt:#'make.LOCAL_EXTRA_TARGETS') ? '') , '
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2154
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2155
all:: preMake classLibRule postMake
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2156
2
claus
parents: 1
diff changeset
  2157
claus
parents: 1
diff changeset
  2158
'.
claus
parents: 1
diff changeset
  2159
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2160
"/    type := #library.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2161
"/    appName := 'app'.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2162
"/    libName := 'lib'.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2163
"/    startUpClass := 'Smalltalk'.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2164
"/    startUpSelector := 'start'.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2165
"/
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2166
"/    properties notNil ifTrue:[
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2167
"/        type := properties at:#projectType ifAbsent:type.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2168
"/        appName := properties at:#applicationName ifAbsent:appName.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2169
"/        startUpClass := properties at:#startupClass ifAbsent:startUpClass.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2170
"/        startUpSelector := properties at:#startupSelector ifAbsent:startUpSelector.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2171
"/    ].
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2172
"/
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2173
"/    s nextPutAll:'#
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2174
"/# define the name of the library to create
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2175
"/#
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2176
"/'.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2177
"/    s nextPutAll:'LIBNAME=lib' , appName; cr; cr.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2178
"/
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2179
"/    s nextPutAll:'#
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2180
"/# the target rule:
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2181
"/#
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2182
"/all::   abbrev.stc objs genClassList $(OBJTARGET)
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2183
"/
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2184
"/'.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2185
"/
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2186
"/    type == #executable ifTrue:[
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2187
"/        s nextPutAll:'PROGS = ' , appName; cr.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2188
"/        s nextPutAll:('STARTUP_CLASS=' , startUpClass); cr.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2189
"/        s nextPutAll:'STARTUP_SELECTOR="' , startUpSelector; nextPutAll:'"'; cr.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2190
"/    ].
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2191
"/
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2192
"/    s nextPutAll:'#
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2193
"/# define the object files that are to be created
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2194
"/#
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2195
"/'.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2196
    s nextPutAll:'OBJS='.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2197
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2198
    classes do:[:aClass |
4833
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  2199
        |clsInfo cond include fileName|
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2200
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2201
        clsInfo := self classInfoFor:aClass.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2202
        include := true.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2203
        clsInfo notNil ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2204
            cond := clsInfo conditionForInclusion.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2205
            (self conditionForInclusionIsTrue:cond) ifFalse:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2206
                include := false.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2207
            ] ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2208
                (self conditionForAutoloadIsTrue:cond) ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2209
                    include := false
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2210
                ]
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2211
            ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2212
        ].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2213
        include ifTrue:[
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2214
            s nextPutAll:' \'. s cr.
4833
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  2215
            fileName := clsInfo classFileName.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  2216
            fileName isNil ifTrue:[
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  2217
                fileName := Smalltalk fileNameForClass:aClass name.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  2218
            ].
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  2219
            fileName := fileName asFilename withoutSuffix name.
5652aec1b08a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4832
diff changeset
  2220
            s nextPutAll:'  '; nextPutAll:fileName; nextPutAll:'.$(O)'.
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2221
        ]
2
claus
parents: 1
diff changeset
  2222
    ].
4792
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  2223
    (methodsFile := self propertyAt:#methodsFile) size > 0 ifTrue:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2224
         s nextPutAll:' \'. s cr.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2225
         s nextPutAll:'  '; 
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2226
           nextPutAll:(methodsFile asFilename withoutSuffix baseName);
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2227
           nextPutAll:'.$(O)'.
4785
4ced52c817e6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4779
diff changeset
  2228
    ].
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2229
    s cr.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2230
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2231
    s nextPutAll:'
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2232
# add more install actions here
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2233
install::
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2234
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2235
# add more install actions for aux-files (resources) here
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2236
installAux::
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2237
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2238
# add more preMake actions here
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2239
preMake::
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2240
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2241
# add more postMake actions here
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2242
postMake:: cleanjunk
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2243
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2244
cleanjunk::
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2245
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2246
clean::
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2247
' , Character tab , '-rm -f *.o *.H
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2248
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2249
clobber::
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2250
' , Character tab , '-rm -f *.so *.dll
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2251
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2252
$(INSTALLBASE)::
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2253
' , Character tab , '@test -d $@ || mkdir $@
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2254
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2255
$(INSTALLBASE)/packages:: $(INSTALLBASE)
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2256
' , Character tab , '@test -d $@ || mkdir $@
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2257
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2258
$(INSTALLBASE)/packages/$(MODULE):: $(INSTALLBASE)/packages
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2259
' , Character tab , '@test -d $@ || mkdir $@
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2260
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2261
$(INSTALLBASE)/packages/$(MODULE)/osi:: $(INSTALLBASE)/packages/$(MODULE)
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2262
' , Character tab , '@test -d $@ || mkdir $@
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2263
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2264
$(INSTALLBASE)/packages/$(MODULE)/osi/asn1:: $(INSTALLBASE)/packages/$(MODULE)/osi
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2265
' , Character tab , '@test -d $@ || mkdir $@
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2266
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2267
$(INSTALLBASE)/packages/$(MODULE)/$(MODULE_DIR):: $(INSTALLBASE)/packages/$(MODULE)
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2268
' , Character tab , '@test -d $@ || mkdir $@
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2269
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2270
# BEGINMAKEDEPEND --- do not remove this line; make depend needs it
362
claus
parents: 356
diff changeset
  2271
'.
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2272
"/    classes notNil ifTrue:[
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2273
"/        classes do:[:aClass |
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2274
"/            |abbrev|
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2275
"/
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2276
"/            abbrev := Smalltalk fileNameForClass:aClass name.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2277
"/            s nextPutAll:abbrev; nextPutAll:'.$(O): '.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2278
"/            s nextPutAll:abbrev; nextPutAll:'.st '.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2279
"/            aClass allSuperclassesDo:[:superClass|
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2280
"/                s nextPutAll:(Smalltalk fileNameForClass:superClass name) , '.$(H) '.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2281
"/            ].
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2282
"/            s nextPutAll:'$(STCHDR)';  cr.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2283
"/        ].
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2284
"/    ].
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2285
    s nextPutAll:'# ENDMAKEDEPEND --- do not remove this line'.
362
claus
parents: 356
diff changeset
  2286
    s cr; cr.
2
claus
parents: 1
diff changeset
  2287
claus
parents: 1
diff changeset
  2288
    type == #executable ifTrue:[
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2289
        s nextPutAll:'all:: $(PROGS)'; cr.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2290
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2291
        s nextPutAll:appName.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2292
        s nextPutAll:':: main.o classList.o $(OBJS)'; cr.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2293
        s tab;      nextPutAll:'$(LD) $(ST_LDFLAG) $(LDFLAGS) -o ';
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2294
                    nextPutAll:appName;
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2295
                    nextPutAll:' \'; cr.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2296
        s tab; tab; nextPutAll:'$(CRT0) main.$(O) classList.$(O) $(OBJS) $(EXTRA_OBJ) $(LIBOBJS) \'; cr.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2297
        s tab; tab; nextPutAll:'$(LIBRUNDIR)/hidata.o $(LIBRUN) \'; cr.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  2298
        s tab; tab; nextPutAll:'$(MATHLIB) $(EXTRALIBS) -lXext $(SYSLIBS) $(OTHERLIBS) $(CRTN)'; cr.
2
claus
parents: 1
diff changeset
  2299
    ].
claus
parents: 1
diff changeset
  2300
claus
parents: 1
diff changeset
  2301
    s close
1420
be5f8e9574cc showCr: -> showCR:
Claus Gittinger <cg@exept.de>
parents: 1332
diff changeset
  2302
4069
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
  2303
    "Modified: / 23.3.1999 / 14:20:09 / cg"
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2304
!
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2305
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2306
createSourcefiles
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2307
    "creates all Smalltalk-source files in the project directory"
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2308
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2309
    |classes methods methodClasses dir stream|
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2310
2956
952a09bdeed1 Use Filename instead of obsolete FileDirectory
Stefan Vogel <sv@exept.de>
parents: 2907
diff changeset
  2311
    dir := self directory asFilename.
1420
be5f8e9574cc showCr: -> showCR:
Claus Gittinger <cg@exept.de>
parents: 1332
diff changeset
  2312
    Transcript showCR:'creating sources in ' , dir pathName , ' ...'; endEntry.
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2313
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2314
    classes := self classes.
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2315
    classes isNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2316
	self warn:'no classes in current project'
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2317
    ].
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2318
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2319
    classes notNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2320
	classes do:[:aClass |
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2321
	    aClass isLoaded ifFalse:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2322
		aClass autoload.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2323
	    ].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2324
	].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2325
	"/ to not list private classes
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2326
	classes := classes select:[:cls | cls owningClass isNil].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2327
	classes := classes topologicalSort:[:a :b | a isSubclassOf:b].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2328
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2329
	classes do:[:aClass |
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2330
	    Transcript show:' ... '; showCR:aClass name, '.st'; endEntry.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2331
	    aClass fileOutIn:dir
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2332
	]
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2333
    ].
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2334
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2335
    methods := self individualMethods.
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2336
    methods notNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2337
	methods := methods asIdentitySet.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2338
	"
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2339
	 get classes ...
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2340
	"
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2341
	methodClasses := IdentitySet new.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2342
	methods do:[:m | 
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2343
			|mCls|
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2344
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2345
			mCls := m containingClass.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2346
			mCls isMeta ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2347
			    mCls := mCls soleInstance.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2348
			].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2349
			methodClasses add:mCls].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2350
	"
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2351
	 fileOut by class
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2352
	"
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2353
	methodClasses do:[:cls |
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2354
	    stream := (self directory asFilename construct:(cls name , '.chg')) writeStream.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2355
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2356
	    Transcript show:' ... '; showCR:cls name, '.chg'; endEntry.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2357
	    methods do:[:m |
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2358
		|mCls|
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2359
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2360
		mCls := m containingClass.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2361
		(mCls == cls or:[mCls == cls class]) ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2362
		    mCls fileOutMethod:m on:stream.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2363
		].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2364
		stream cr.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2365
	    ].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2366
	    stream close.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2367
	].
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2368
    ].
1420
be5f8e9574cc showCr: -> showCR:
Claus Gittinger <cg@exept.de>
parents: 1332
diff changeset
  2369
1854
b44227fd2b3d use new Method>>who interface
Claus Gittinger <cg@exept.de>
parents: 1636
diff changeset
  2370
    "Modified: 1.11.1996 / 16:37:15 / cg"
2956
952a09bdeed1 Use Filename instead of obsolete FileDirectory
Stefan Vogel <sv@exept.de>
parents: 2907
diff changeset
  2371
    "Modified: 18.9.1997 / 18:50:34 / stefan"
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2372
!
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2373
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2374
findTopFrom:directoryName
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2375
    "returns the relative path from directoryName to the TOP
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2376
     directory."
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2377
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2378
    |topName relParent foundTop|
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2379
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2380
    "/ find TOP
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2381
    relParent := '..'.
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2382
    foundTop := false.
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2383
    [foundTop] whileFalse:[
4820
481593067423 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4819
diff changeset
  2384
        topName := directoryName asFilename construct:relParent.
481593067423 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4819
diff changeset
  2385
        ((topName construct:'stx') construct:'configurations') exists ifTrue:[
481593067423 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4819
diff changeset
  2386
            ((topName construct:'stx') construct:'include') exists ifTrue:[
4821
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  2387
                ^ relParent asFilename constructString:'stx'.
4820
481593067423 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4819
diff changeset
  2388
            ]
481593067423 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4819
diff changeset
  2389
        ].
481593067423 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4819
diff changeset
  2390
        (topName construct:'configurations') exists ifTrue:[
481593067423 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4819
diff changeset
  2391
            (topName construct:'include') exists ifTrue:[
4821
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  2392
                ^ relParent name
4820
481593067423 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4819
diff changeset
  2393
            ]
481593067423 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4819
diff changeset
  2394
        ].
481593067423 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4819
diff changeset
  2395
        relParent := relParent asFilename constructString:'..'.
481593067423 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4819
diff changeset
  2396
481593067423 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4819
diff changeset
  2397
        topName isRootDirectory ifTrue:[
481593067423 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4819
diff changeset
  2398
            self warn:'could not find TOP; assume absolute path to TOP'.
481593067423 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4819
diff changeset
  2399
            ^ nil.
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2400
"/            topName := '/usr/local/lib/smalltalk'.
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2401
"/            foundTop := true.
4820
481593067423 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4819
diff changeset
  2402
        ]
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2403
    ].
4779
767b94dabb98 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4776
diff changeset
  2404
    ^ topName pathName
4820
481593067423 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4819
diff changeset
  2405
4821
c73b170cb6e0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4820
diff changeset
  2406
    "Modified: / 26.9.1999 / 16:15:14 / cg"
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2407
! !
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2408
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2409
!Project methodsFor:'printing & storing'!
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2410
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2411
displayString
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2412
    ^ super displayString , '(''' , (name ? '<unnamed>') , ''')'
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2413
! !
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2414
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2415
!Project methodsFor:'properties'!
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2416
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2417
addClass:classOrClassName classFileName:fileName
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2418
    "add a class to the project"
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2419
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2420
    self
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2421
	addClass:classOrClassName 
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2422
	conditionForInclusion:#always 
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2423
	classFileName:fileName
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2424
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2425
!
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2426
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2427
addClass:classOrClassName conditionForInclusion:conditionBlock classFileName:fileName
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2428
    "add a class to the project"
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2429
4789
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2430
    |i clsName|
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2431
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2432
    (clsName := classOrClassName) isBehavior ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2433
	clsName := classOrClassName name
4789
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2434
    ].
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2435
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2436
    i := ClassInfo new.
4789
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2437
    i className:clsName.
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2438
    i classFileName:fileName.
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2439
    i conditionForInclusion:conditionBlock.
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2440
    self addClassInfo:i
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2441
!
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2442
4089
abcd3430bb9c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4080
diff changeset
  2443
addClassInfo:newInfo
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2444
    "add a class info to the project"
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2445
4315
047c3c925f2f checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4314
diff changeset
  2446
    |infoCollection index nm prefix|
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2447
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2448
    (infoCollection := self classInfo) isNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2449
	self classInfo:(infoCollection := OrderedCollection new).
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2450
    ].
4315
047c3c925f2f checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4314
diff changeset
  2451
047c3c925f2f checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4314
diff changeset
  2452
    index := infoCollection findFirst:[:i | |nm1 nm2|
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2453
					nm1 := i className.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2454
					nm2 := newInfo className.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2455
					nm1 = nm2
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2456
				      ].
4089
abcd3430bb9c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4080
diff changeset
  2457
    index ~~ 0 ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2458
	infoCollection at:index put:newInfo
4089
abcd3430bb9c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4080
diff changeset
  2459
    ] ifFalse:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2460
	infoCollection add:newInfo
4089
abcd3430bb9c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4080
diff changeset
  2461
    ]
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2462
!
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2463
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2464
addMethod:methodName inClass:classOrClassName conditionForInclusion:condition fileName:optionalFileName
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2465
    "add a method to the project"
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2466
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2467
    |i|
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2468
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2469
    i := MethodInfo new.
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2470
    i className:classOrClassName.
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2471
    i methodName:methodName.
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2472
    i fileName:optionalFileName.
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2473
    i conditionForInclusion:condition.
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2474
    self addMethodInfo:i
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2475
!
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2476
4668
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
  2477
addMethod:methodOrSelector inClass:aClassOrClassName fileName:fileName
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
  2478
    "add an individual method to the project"
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
  2479
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
  2480
    |i|
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
  2481
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
  2482
    i := MethodInfo new.
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
  2483
    i methodName:methodOrSelector.
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
  2484
    i className:aClassOrClassName.
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
  2485
    i fileName:fileName.
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
  2486
    self addMethodInfo:i
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
  2487
!
a4e061d91251 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4522
diff changeset
  2488
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2489
addMethodInfo:newInfo
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2490
    "add a method info to the project"
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2491
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2492
    |infoCollection index nm prefix|
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2493
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2494
    (infoCollection := self methodInfo) isNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2495
	self methodInfo:(infoCollection := OrderedCollection new).
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2496
    ].
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2497
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2498
    index := infoCollection findFirst:[:i | |cnm1 cnm2|
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2499
					cnm1 := i className.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2500
					cnm2 := newInfo className.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2501
					(cnm1 includes:$:) ifFalse:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2502
					    cnm1 := self defaultNameSpace name , '::' , cnm1
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2503
					].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2504
					(cnm2 includes:$:) ifFalse:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2505
					    cnm2 := self defaultNameSpace name , '::' , cnm2
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2506
					].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2507
					cnm1 = cnm2 and:[i methodName = newInfo methodName]
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2508
				      ].
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2509
    "/ strip off nameSpace prefix, if its the same as
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2510
    "/ the default ...
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2511
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2512
    nm := newInfo className.
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2513
    prefix := self defaultNameSpace name , '::'.
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2514
    (nm startsWith:prefix) ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2515
	nm := nm copyFrom:(prefix size + 1).
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2516
	newInfo className:nm asSymbol.
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2517
    ].
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2518
    index ~~ 0 ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2519
	infoCollection at:index put:newInfo
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2520
    ] ifFalse:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2521
	infoCollection add:newInfo
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2522
    ]
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2523
!
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2524
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2525
classInfo:aClassInfoCollection
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2526
    "set the class info of the project"
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2527
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  2528
    self propertyAt:#classInfo put:aClassInfoCollection
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2529
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2530
!
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2531
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2532
comment
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2533
    "return the comment of the project"
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2534
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2535
    properties isNil ifTrue:[^ ''].
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2536
    ^ properties at:#comment ifAbsent:''
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2537
!
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2538
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2539
comment:aString
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2540
    "set the projects comment"
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2541
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  2542
    self propertyAt:#comment put:aString
4070
682f720cd0f6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4069
diff changeset
  2543
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2544
!
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2545
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2546
documentationURL
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2547
    "return the documentation-URL of the project"
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2548
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2549
    properties isNil ifTrue:[^ nil].
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2550
    ^ properties at:#documentationURL ifAbsent:nil
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2551
!
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2552
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2553
documentationURL:anURLString
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2554
    "set the projects documentation-URL"
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2555
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  2556
    self propertyAt:#documentationURL put:anURLString
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  2557
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2558
!
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2559
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2560
methodInfo:aMethodInfoCollection
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2561
    "set the method info of the project"
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2562
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2563
    self propertyAt:#methodInfo put:aMethodInfoCollection
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2564
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2565
!
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2566
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2567
properties
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2568
    "return the property dictionary"
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2569
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2570
    ^ properties
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2571
!
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2572
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2573
properties:p
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2574
    "set the property dictionary"
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2575
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2576
    properties := p
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2577
!
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2578
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  2579
propertyAt:aKey
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2580
    "return a property; the key is a symbol"
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2581
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  2582
    properties isNil ifTrue:[^ nil].
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  2583
    ^ properties at:aKey ifAbsent:nil.
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  2584
!
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  2585
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  2586
propertyAt:aKey put:aValue
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2587
    "set a property; the key is a symbol"
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2588
4077
cc1f4c165ace checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4074
diff changeset
  2589
    |oldValue|
cc1f4c165ace checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4074
diff changeset
  2590
cc1f4c165ace checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4074
diff changeset
  2591
    oldValue := self propertyAt:aKey.
cc1f4c165ace checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4074
diff changeset
  2592
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  2593
    properties isNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2594
	properties := IdentityDictionary new
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  2595
    ].
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  2596
    properties at:aKey put:aValue.
4077
cc1f4c165ace checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4074
diff changeset
  2597
cc1f4c165ace checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4074
diff changeset
  2598
    oldValue ~~ aValue ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2599
	self changed:aKey.
4077
cc1f4c165ace checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4074
diff changeset
  2600
    ].
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  2601
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  2602
    "Created: / 23.3.1999 / 14:21:11 / cg"
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  2603
!
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  2604
4792
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  2605
removeClass:classOrClassName
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  2606
    "remove a class from the project"
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  2607
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  2608
    |infoCollection index className|
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  2609
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  2610
    (infoCollection := self classInfo) isNil ifTrue:[^ self].
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  2611
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  2612
    (className := classOrClassName) isBehavior ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2613
	className := classOrClassName name
4792
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  2614
    ].
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  2615
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  2616
    index := infoCollection findFirst:[:i | i className = className.].
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  2617
    index ~~ 0 ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2618
	infoCollection removeIndex:index
4792
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  2619
    ]
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  2620
!
8e50b8218546 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4791
diff changeset
  2621
4834
522f10359ce9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4833
diff changeset
  2622
removeMethod:method
522f10359ce9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4833
diff changeset
  2623
    "remove a method from the project"
522f10359ce9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4833
diff changeset
  2624
522f10359ce9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4833
diff changeset
  2625
    |infoCollection index className selector|
522f10359ce9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4833
diff changeset
  2626
522f10359ce9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4833
diff changeset
  2627
    (infoCollection := self methodInfo) isNil ifTrue:[^ self].
522f10359ce9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4833
diff changeset
  2628
    className := method who methodClass name.
522f10359ce9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4833
diff changeset
  2629
    selector := method who methodSelector.
522f10359ce9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4833
diff changeset
  2630
522f10359ce9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4833
diff changeset
  2631
    index := infoCollection findFirst:[:i | i className = className.].
522f10359ce9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4833
diff changeset
  2632
    index ~~ 0 ifTrue:[
522f10359ce9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4833
diff changeset
  2633
        infoCollection removeIndex:index
522f10359ce9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4833
diff changeset
  2634
    ]
522f10359ce9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4833
diff changeset
  2635
!
522f10359ce9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4833
diff changeset
  2636
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2637
type
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2638
    "return the type of project (one of #application, #library, #smalltalk)"
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2639
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2640
    properties isNil ifTrue:[^ #application].
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2641
    ^ properties at:#type ifAbsent:#application
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2642
!
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2643
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2644
type:aSymbol
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2645
    "set the projects type (one of #application, #library, #smalltalk)"
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2646
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  2647
    |sym|
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  2648
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  2649
    (sym := aSymbol) == #classLibrary ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2650
	sym := #library
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  2651
    ].
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  2652
    (#(application library extension smalltalk) includes:sym) ifFalse:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2653
	self warn:'invalid project type'.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2654
	^ self
3972
efc25c2863e9 more attributes; some preparations for the ProjectBrowser.
Claus Gittinger <cg@exept.de>
parents: 3332
diff changeset
  2655
    ].
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  2656
    self propertyAt:#type put:sym
4069
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
  2657
!
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
  2658
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
  2659
wasLoadedFromFile
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
  2660
    "return true, if the project was loaded from a file"
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
  2661
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
  2662
    properties isNil ifTrue:[^ nil].
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
  2663
    ^ properties at:#wasLoadedFromFile ifAbsent:false
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
  2664
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
  2665
    "Modified: / 23.3.1999 / 13:59:32 / cg"
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
  2666
    "Created: / 23.3.1999 / 14:21:06 / cg"
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
  2667
!
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
  2668
7d36633a470a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4066
diff changeset
  2669
wasLoadedFromFile:aBoolean
4097
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2670
    "set/clear the flag stating that the project was loaded from a file"
66466729c1de more PBrowser support
Claus Gittinger <cg@exept.de>
parents: 4089
diff changeset
  2671
4071
2b6946e843c5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4070
diff changeset
  2672
    self propertyAt:#wasLoadedFromFile put:aBoolean
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2673
! !
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2674
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2675
!Project methodsFor:'queries'!
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2676
4688
1b27165b9f97 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4685
diff changeset
  2677
areAllClassesLoaded
1b27165b9f97 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4685
diff changeset
  2678
    "return true, if all classes of the package are loaded
1b27165b9f97 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4685
diff changeset
  2679
     (i.e. there are no autoloaded stubs present)"
1b27165b9f97 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4685
diff changeset
  2680
4690
563f4d832234 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4688
diff changeset
  2681
    |classes|
563f4d832234 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4688
diff changeset
  2682
563f4d832234 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4688
diff changeset
  2683
    classes := self classes.
563f4d832234 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4688
diff changeset
  2684
    classes isNil ifTrue:[^ isLoaded ? false].
563f4d832234 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4688
diff changeset
  2685
    classes do:[:aClass |
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2686
	aClass isLoaded ifFalse:[^ false].
4688
1b27165b9f97 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4685
diff changeset
  2687
    ].
1b27165b9f97 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4685
diff changeset
  2688
    ^ true
1b27165b9f97 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4685
diff changeset
  2689
1b27165b9f97 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4685
diff changeset
  2690
!
1b27165b9f97 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4685
diff changeset
  2691
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2692
classInfo
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2693
    "return a classInfo collection of classes belonging to that project"
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2694
4073
21939187f19c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4071
diff changeset
  2695
    |classInfo classes|
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2696
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2697
    properties notNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2698
	classInfo := properties at:#classInfo ifAbsent:nil.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2699
	classInfo notNil ifTrue:[^ classInfo].
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2700
    ].
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2701
4073
21939187f19c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4071
diff changeset
  2702
    classes := self classes.
21939187f19c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4071
diff changeset
  2703
    classes size == 0 ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2704
	classInfo := OrderedCollection new
4073
21939187f19c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4071
diff changeset
  2705
    ] ifFalse:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2706
	classInfo := classes asOrderedCollection
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2707
			collect:[:class |
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2708
			    |i fn|
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2709
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2710
			    i := ClassInfo new.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2711
			    i conditionForInclusion:#always.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2712
			    i className:class name.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2713
			    fn := class classFilename ? ((Smalltalk fileNameForClass:class) , '.st').
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2714
			    i classFileName:fn.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2715
			    i
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2716
			]
4073
21939187f19c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4071
diff changeset
  2717
    ].
21939187f19c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4071
diff changeset
  2718
    self propertyAt:#classInfo put:classInfo.
21939187f19c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4071
diff changeset
  2719
    ^ classInfo
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2720
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2721
    "Modified: 4.1.1997 / 16:51:18 / cg"
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2722
!
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2723
4789
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2724
classInfoFor:aClassOrClassName
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2725
    "return a classInfo for a particular class"
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2726
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2727
    |classInfo clsName index|
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2728
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2729
    (classInfo := self classInfo) isNil ifTrue:[^ nil].
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2730
    (clsName := aClassOrClassName) isBehavior ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2731
	clsName := aClassOrClassName name
4789
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2732
    ].
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2733
    ^ classInfo detect:[:i | i className = clsName] ifNone:nil.
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2734
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2735
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2736
    "Modified: 4.1.1997 / 16:51:18 / cg"
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2737
!
72a61dc595ad loadAll/Make.proto file generation
Claus Gittinger <cg@exept.de>
parents: 4787
diff changeset
  2738
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2739
classes
4013
f06d31702f2a ignore private classes in classList
Claus Gittinger <cg@exept.de>
parents: 4010
diff changeset
  2740
    "return a collection of classes belonging to that project.
f06d31702f2a ignore private classes in classList
Claus Gittinger <cg@exept.de>
parents: 4010
diff changeset
  2741
     This excludes any private classes."
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2742
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2743
    |classes classInfo|
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2744
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2745
    properties notNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2746
	classInfo := properties at:#classInfo ifAbsent:nil.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2747
	classInfo notNil ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2748
	    classes := classInfo collect:[:i | i className]
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2749
	] ifFalse:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2750
	    classes := properties at:#classes ifAbsent:nil
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2751
	]
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2752
    ].
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  2753
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2754
    classes isNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2755
	classes := OrderedCollection new.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2756
	Smalltalk 
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2757
	    allClassesDo:[:aClass |
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2758
		(true "aClass owningClass isNil"
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2759
		and:[aClass isMeta not
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2760
		and:[aClass package = packageName
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2761
		and:[aClass isNamespace not or:[aClass == Smalltalk]]]]) ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2762
		    classes add:aClass
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2763
		]
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2764
	    ].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2765
	classes isEmpty ifTrue:[^ nil].
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2766
    ].
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2767
    ^ classes
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2768
2056
1beb5756e9e9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2034
diff changeset
  2769
    "Modified: 4.1.1997 / 16:51:18 / cg"
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2770
!
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2771
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2772
individualMethods
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2773
    "return a collection of individual methods belonging to that project,
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2774
     only methods are returned which are not contained in the
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2775
     projects class set."
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2776
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2777
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2778
"/
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2779
"/ obsoleted by #methods ...
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2780
"/
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2781
    |classes methods|
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2782
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2783
    classes := self classes.
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2784
    classes notNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2785
	classes := classes asIdentitySet.
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2786
    ] ifFalse:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2787
	classes := #()
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2788
    ].
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2789
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2790
    methods := IdentitySet new.
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2791
    Smalltalk allBehaviorsDo:[:cls |
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2792
	|classToCheck|
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2793
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2794
	classToCheck := cls.
4670
21eec331e1e9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4668
diff changeset
  2795
"/        cls isPrivate ifTrue:[
21eec331e1e9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4668
diff changeset
  2796
"/            classToCheck := cls topOwningClass
21eec331e1e9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4668
diff changeset
  2797
"/        ].
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2798
	(classes isNil 
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2799
	or:[((classes includes:classToCheck) 
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2800
	    or:[classes includes:classToCheck name]) not]) ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2801
	    cls methodDictionary do:[:m |
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2802
		m package = packageName ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2803
		    methods add:m
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2804
		]
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2805
	    ].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2806
	    cls class methodDictionary do:[:m |
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2807
		m package = packageName ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2808
		    methods add:m
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2809
		]
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2810
	    ].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2811
	]
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2812
    ].
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2813
    ^ methods asArray
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2814
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2815
    "
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2816
     Project current classes
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2817
     Project current individualMethods
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2818
    "
1461
dd25bb1e9973 Use methodDictionary instead of selector/method arrays.
Stefan Vogel <sv@exept.de>
parents: 1420
diff changeset
  2819
dd25bb1e9973 Use methodDictionary instead of selector/method arrays.
Stefan Vogel <sv@exept.de>
parents: 1420
diff changeset
  2820
    "Modified: 7.6.1996 / 09:16:25 / stefan"
4685
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2821
!
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2822
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2823
isLoaded
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2824
    "return true, if all of this project-package has been loaded
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2825
     into the system"
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2826
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  2827
    |binaryModule cls|
4685
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2828
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2829
    isLoaded notNil ifTrue:[^ isLoaded].
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2830
4791
c2cdad0ab823 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4790
diff changeset
  2831
    "/ check for loaded class-library - assume loaded if present.
4685
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2832
    binaryModule := ObjectMemory binaryModuleInfo detect:[:i | i package = self package] ifNone:nil.
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2833
    binaryModule notNil ifTrue:[
4819
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  2834
        ^ true
4685
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2835
    ].
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2836
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  2837
    "/ check for all classes ...
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  2838
    self classes do:[:aClassOrClassName |
4819
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  2839
        aClassOrClassName isBehavior ifFalse:[
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  2840
            aClassOrClassName isSymbol ifTrue:[
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  2841
                (cls := Smalltalk at:aClassOrClassName) isNil ifTrue:[
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  2842
                    ^ false
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  2843
                ].
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  2844
                cls isBehavior ifFalse:[^ false].
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  2845
                cls isLoaded ifFalse:[^ false].
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  2846
            ] ifFalse:[
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  2847
                self halt.
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  2848
                ^ false
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  2849
            ]
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  2850
        ]
4769
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  2851
    ].
202c54048ce4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4755
diff changeset
  2852
4791
c2cdad0ab823 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4790
diff changeset
  2853
    "/ check for all patches & extensions ...
c2cdad0ab823 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4790
diff changeset
  2854
    self methods do:[:aMethodInfo |
4819
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  2855
        aMethodInfo theMethod isNil ifTrue:[
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  2856
            ^ false
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  2857
        ].
4791
c2cdad0ab823 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4790
diff changeset
  2858
    ].
c2cdad0ab823 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4790
diff changeset
  2859
c2cdad0ab823 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4790
diff changeset
  2860
    ^ true
4685
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2861
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2862
    "
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2863
     (Project projectWithId:#'stx:libbasic') isLoaded
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2864
     (Project projectWithId:#'stx:goodies/persistency') isLoaded 
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2865
    "
d145298696b7 more package loading support
Claus Gittinger <cg@exept.de>
parents: 4670
diff changeset
  2866
4819
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  2867
    "Modified: / 26.9.1999 / 13:39:55 / cg"
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2868
!
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2869
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2870
methodInfo
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2871
    "return a methodInfo collection of methods belonging to that project"
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2872
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2873
    |methodInfo methods|
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2874
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2875
    properties notNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2876
	methodInfo := properties at:#methodInfo ifAbsent:nil.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2877
	methodInfo notNil ifTrue:[^ methodInfo].
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2878
    ].
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2879
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2880
    methods := self methods.
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2881
    methods size == 0 ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2882
	methodInfo := OrderedCollection new
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2883
    ] ifFalse:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2884
	methodInfo := methods asOrderedCollection
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2885
			collect:[:mthd |
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2886
			    |i fn who className selector|
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2887
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2888
			    mthd isMethod ifTrue:[   
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2889
				who := mthd who.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2890
				className := who methodClass name.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2891
				selector := who methodSelector.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2892
				i := MethodInfo new.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2893
				i conditionForInclusion:#always.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2894
				i className:className.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2895
				i methodName:className.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2896
				fn := mthd sourceFilename.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2897
				i fileName:fn.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2898
				i
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2899
			    ] ifFalse:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2900
				mthd "/ already a methodInfo
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2901
			    ]
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2902
			]
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2903
    ].
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2904
    self propertyAt:#methodInfo put:methodInfo.
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2905
    ^ methodInfo
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2906
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2907
    "Modified: 4.1.1997 / 16:51:18 / cg"
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2908
!
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2909
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2910
methods
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2911
    "return a collection of methods belonging to that project.
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2912
     This excludes any methods which are already in my class-set."
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2913
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2914
    |methods methodsInfo|
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2915
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2916
    properties notNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2917
	methodsInfo := properties at:#methodsInfo ifAbsent:nil.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2918
	methodsInfo notNil ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2919
	    methods := methodsInfo collect:[:i | i className]
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2920
	] ifFalse:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2921
	    methods := properties at:#methods ifAbsent:nil
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2922
	]
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2923
    ].
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2924
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2925
    methods isNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2926
	methods := OrderedCollection new.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2927
	Smalltalk allClassesDo:[:aClass |
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2928
	    (true "aClass owningClass isNil"
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2929
	    and:[aClass isMeta not
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2930
	    and:[aClass package ~= packageName
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2931
	    and:[aClass isNamespace not or:[aClass == Smalltalk]]]]) ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2932
	    
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2933
		aClass methodDictionary keysAndValuesDo:[:sel :mthd |
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2934
		    mthd package = packageName ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2935
			methods add:(MethodInfo new
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2936
					className:aClass name;
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2937
					methodName:sel;
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2938
					yourself)
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2939
		    ].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2940
		].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2941
		aClass class methodDictionary keysAndValuesDo:[:sel :mthd |
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2942
		    mthd package = packageName ifTrue:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2943
			methods add:(MethodInfo new
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2944
					className:(aClass name , ' class');
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2945
					methodName:sel;
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2946
					yourself)
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2947
		    ].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2948
		]
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2949
	    ]
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2950
	].
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2951
	methods isEmpty ifTrue:[^ #()].
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2952
    ].
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2953
    ^ methods
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2954
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  2955
    "Modified: 4.1.1997 / 16:51:18 / cg"
2
claus
parents: 1
diff changeset
  2956
! !
claus
parents: 1
diff changeset
  2957
claus
parents: 1
diff changeset
  2958
!Project methodsFor:'specifications'!
claus
parents: 1
diff changeset
  2959
claus
parents: 1
diff changeset
  2960
readSpec
claus
parents: 1
diff changeset
  2961
    |s chunk fileName|
claus
parents: 1
diff changeset
  2962
claus
parents: 1
diff changeset
  2963
    fileName := (properties at:#directoryName) asFilename construct:'.project'.
claus
parents: 1
diff changeset
  2964
    s := fileName readStream.
claus
parents: 1
diff changeset
  2965
    s isNil ifTrue:[^ self].
claus
parents: 1
diff changeset
  2966
    [s atEnd] whileFalse:[
203
3d88fa870de0 *** empty log message ***
claus
parents: 150
diff changeset
  2967
	chunk := s nextChunk.
3d88fa870de0 *** empty log message ***
claus
parents: 150
diff changeset
  2968
	Compiler evaluate:chunk receiver:properties notifying:nil
2
claus
parents: 1
diff changeset
  2969
    ].
claus
parents: 1
diff changeset
  2970
    s close.
claus
parents: 1
diff changeset
  2971
claus
parents: 1
diff changeset
  2972
    "(Project new directory:'../projects/Clock') readSpec"
claus
parents: 1
diff changeset
  2973
!
claus
parents: 1
diff changeset
  2974
claus
parents: 1
diff changeset
  2975
saveSpec
claus
parents: 1
diff changeset
  2976
    |f d s|
claus
parents: 1
diff changeset
  2977
claus
parents: 1
diff changeset
  2978
    d := (properties at:#directoryName) asFilename.
claus
parents: 1
diff changeset
  2979
    d exists ifFalse:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2980
	self error:'directory does not exist' mayProceed:true.
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2981
	^ self
2
claus
parents: 1
diff changeset
  2982
    ].
claus
parents: 1
diff changeset
  2983
    f := d construct:'.project'.
claus
parents: 1
diff changeset
  2984
    s := f writeStream.
claus
parents: 1
diff changeset
  2985
    s isNil ifTrue:[^ self].
claus
parents: 1
diff changeset
  2986
    properties associationsDo:[:aProp |
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2987
	(aProp == #directoryName) ifFalse:[
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2988
	    s nextChunkPut:('self at:' , aProp key storeString, 
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2989
			       ' put:' , aProp value storeString).
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2990
	    s cr
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2991
	]
2
claus
parents: 1
diff changeset
  2992
    ].
claus
parents: 1
diff changeset
  2993
    s close
claus
parents: 1
diff changeset
  2994
claus
parents: 1
diff changeset
  2995
    "((Project new directory:'../projects/Clock') readSpec
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  2996
	 directory:'../projects/xxx') saveSpec"
2
claus
parents: 1
diff changeset
  2997
! !
claus
parents: 1
diff changeset
  2998
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  2999
!Project methodsFor:'views'!
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3000
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3001
addView:aView
2164
063b0227aeda use #remap instead of #map to show views
Claus Gittinger <cg@exept.de>
parents: 2056
diff changeset
  3002
    "add a view to this projects set of views"
063b0227aeda use #remap instead of #map to show views
Claus Gittinger <cg@exept.de>
parents: 2056
diff changeset
  3003
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3004
    views notNil ifTrue:[views add:aView]
2164
063b0227aeda use #remap instead of #map to show views
Claus Gittinger <cg@exept.de>
parents: 2056
diff changeset
  3005
063b0227aeda use #remap instead of #map to show views
Claus Gittinger <cg@exept.de>
parents: 2056
diff changeset
  3006
    "Modified: 14.2.1997 / 15:36:51 / cg"
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3007
!
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3008
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3009
destroyViews
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3010
    "destroy all views of this project"
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3011
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3012
    views notNil ifTrue:[
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3013
	views do:[:aView |
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3014
	    aView notNil ifTrue:[aView destroy]
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3015
	]
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3016
    ].
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3017
!
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3018
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3019
hideViews
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3020
    "hide all views of this project"
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3021
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3022
    views notNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  3023
	views do:[:aView |
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  3024
	    aView notNil ifTrue:[aView unmap]
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  3025
	]
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3026
    ].
1332
a1d72522f5fc Rename unrealize-->unmap, rerealize->map.
Stefan Vogel <sv@exept.de>
parents: 1298
diff changeset
  3027
a1d72522f5fc Rename unrealize-->unmap, rerealize->map.
Stefan Vogel <sv@exept.de>
parents: 1298
diff changeset
  3028
    "Modified: 3.5.1996 / 23:48:51 / stefan"
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3029
!
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3030
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3031
removeView:aView
2164
063b0227aeda use #remap instead of #map to show views
Claus Gittinger <cg@exept.de>
parents: 2056
diff changeset
  3032
    "remove a view from this projects set of views"
063b0227aeda use #remap instead of #map to show views
Claus Gittinger <cg@exept.de>
parents: 2056
diff changeset
  3033
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  3034
    views notNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  3035
	views remove:aView ifAbsent:nil
3996
3183ccccabaa more support for projectBrowser
Claus Gittinger <cg@exept.de>
parents: 3974
diff changeset
  3036
    ]
2164
063b0227aeda use #remap instead of #map to show views
Claus Gittinger <cg@exept.de>
parents: 2056
diff changeset
  3037
063b0227aeda use #remap instead of #map to show views
Claus Gittinger <cg@exept.de>
parents: 2056
diff changeset
  3038
    "Modified: 14.2.1997 / 15:37:20 / cg"
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3039
!
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3040
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3041
showViews
2164
063b0227aeda use #remap instead of #map to show views
Claus Gittinger <cg@exept.de>
parents: 2056
diff changeset
  3042
    "show all views of this project"
063b0227aeda use #remap instead of #map to show views
Claus Gittinger <cg@exept.de>
parents: 2056
diff changeset
  3043
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3044
    views notNil ifTrue:[
4814
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  3045
	views do:[:aView |
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  3046
	    aView notNil ifTrue:[aView remap]
7825b9141f01 changes to allow compilation under win32 (does not like strings beginning
Claus Gittinger <cg@exept.de>
parents: 4813
diff changeset
  3047
	]
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3048
    ].
1332
a1d72522f5fc Rename unrealize-->unmap, rerealize->map.
Stefan Vogel <sv@exept.de>
parents: 1298
diff changeset
  3049
a1d72522f5fc Rename unrealize-->unmap, rerealize->map.
Stefan Vogel <sv@exept.de>
parents: 1298
diff changeset
  3050
    "Modified: 3.5.1996 / 23:59:10 / stefan"
2164
063b0227aeda use #remap instead of #map to show views
Claus Gittinger <cg@exept.de>
parents: 2056
diff changeset
  3051
    "Modified: 14.2.1997 / 15:38:47 / cg"
617
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3052
! !
427245e28240 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 530
diff changeset
  3053
4832
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3054
!Project::ClassInfo methodsFor:'accessing'!
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3055
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3056
classFileName
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3057
    "return the value of the instance variable 'classFileName' (automatically generated)"
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3058
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3059
    ^ classFileName!
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3060
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3061
classFileName:something
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3062
    "set the value of the instance variable 'classFileName' (automatically generated)"
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3063
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3064
    classFileName := something.!
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3065
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3066
className
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3067
    "return the value of the instance variable 'className' (automatically generated)"
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3068
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3069
    ^ className!
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3070
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3071
className:something
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3072
    "set the value of the instance variable 'className' (automatically generated)"
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3073
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3074
    className := something.!
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3075
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3076
conditionForInclusion
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3077
    "return the value of the instance variable 'conditionForInclusion' (automatically generated)"
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3078
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3079
    ^ conditionForInclusion!
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3080
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3081
conditionForInclusion:something
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3082
    "set the value of the instance variable 'conditionForInclusion' (automatically generated)"
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3083
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3084
    conditionForInclusion := something.! !
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3085
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3086
!Project::ClassInfo methodsFor:'printing & storing'!
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3087
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3088
displayString
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3089
    ^ 'ClassInfo: ' , className
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3090
! !
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3091
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3092
!Project::ClassInfo methodsFor:'queries'!
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3093
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3094
theClass
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3095
    |cls|
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3096
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3097
    cls := Smalltalk classNamed:className.
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3098
    cls isNil ifTrue:[ ^ nil].
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3099
    ^ cls
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3100
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3101
    "Created: / 26.9.1999 / 13:39:00 / cg"
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3102
! !
d335c43bf297 care for inheritance order, when saving a project file.
Claus Gittinger <cg@exept.de>
parents: 4824
diff changeset
  3103
4743
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3104
!Project::MethodInfo methodsFor:'accessing'!
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3105
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3106
className
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3107
    "return the value of the instance variable 'className' (automatically generated)"
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3108
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3109
    ^ className!
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3110
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3111
className:something
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3112
    "set the value of the instance variable 'className' (automatically generated)"
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3113
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3114
    className := something.!
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3115
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  3116
conditionForInclusion
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  3117
    "return the value of the instance variable 'conditionForInclusion' (automatically generated)"
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  3118
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  3119
    ^ conditionForInclusion!
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  3120
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  3121
conditionForInclusion:something
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  3122
    "set the value of the instance variable 'conditionForInclusion' (automatically generated)"
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  3123
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  3124
    conditionForInclusion := something.!
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  3125
4743
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3126
fileName
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3127
    "return the value of the instance variable 'fileName' (automatically generated)"
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3128
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3129
    ^ fileName!
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3130
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3131
fileName:something
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3132
    "set the value of the instance variable 'fileName' (automatically generated)"
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3133
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3134
    fileName := something.!
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3135
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3136
methodName
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3137
    "return the value of the instance variable 'methodName' (automatically generated)"
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3138
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3139
    ^ methodName!
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3140
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3141
methodName:something
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3142
    "set the value of the instance variable 'methodName' (automatically generated)"
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3143
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3144
    methodName := something.! !
11f9e45976cb *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 4727
diff changeset
  3145
4755
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  3146
!Project::MethodInfo methodsFor:'printing & storing'!
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  3147
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  3148
displayString
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  3149
    ^ 'MethodInfo: ' , className , ' ' , methodName
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  3150
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  3151
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  3152
! !
2d866f87d1da preps to keep track of methods
Claus Gittinger <cg@exept.de>
parents: 4747
diff changeset
  3153
4791
c2cdad0ab823 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4790
diff changeset
  3154
!Project::MethodInfo methodsFor:'queries'!
c2cdad0ab823 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4790
diff changeset
  3155
c2cdad0ab823 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4790
diff changeset
  3156
method
4819
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  3157
    self obsoleteMethodWarning.
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  3158
    ^ self theMethod.
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  3159
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  3160
    "Modified: / 26.9.1999 / 13:40:16 / cg"
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  3161
!
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  3162
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  3163
theMethod
4791
c2cdad0ab823 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4790
diff changeset
  3164
    |cls|
c2cdad0ab823 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4790
diff changeset
  3165
c2cdad0ab823 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4790
diff changeset
  3166
    cls := Smalltalk classNamed:className.
c2cdad0ab823 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4790
diff changeset
  3167
    cls isNil ifTrue:[ ^ nil].
c2cdad0ab823 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4790
diff changeset
  3168
    ^ cls compiledMethodAt:methodName asSymbol.
4819
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  3169
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  3170
    "Created: / 26.9.1999 / 13:39:07 / cg"
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  3171
! !
19b89da166c0 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4814
diff changeset
  3172
1854
b44227fd2b3d use new Method>>who interface
Claus Gittinger <cg@exept.de>
parents: 1636
diff changeset
  3173
!Project class methodsFor:'documentation'!
630
b785d23d7c5b version at the end
Claus Gittinger <cg@exept.de>
parents: 617
diff changeset
  3174
b785d23d7c5b version at the end
Claus Gittinger <cg@exept.de>
parents: 617
diff changeset
  3175
version
4834
522f10359ce9 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 4833
diff changeset
  3176
    ^ '$Header: /cvs/stx/stx/libbasic/Project.st,v 1.120 1999-10-03 16:55:37 cg Exp $'
1298
23d0ba91c9be documentation
Claus Gittinger <cg@exept.de>
parents: 1286
diff changeset
  3177
! !
1
a27a279701f8 Initial revision
claus
parents:
diff changeset
  3178
Project initialize!