ProjectDefinition.st
author Jan Vrany <jan.vrany@fit.cvut.cz>
Wed, 13 Mar 2013 02:24:08 +0100
changeset 14859 1511cfd924cd
parent 14851 7be11ef3d914
child 14860 b8bc6ecbd1b0
permissions -rw-r--r--
Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
9553
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
     1
"
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
     2
 COPYRIGHT (c) 2006 by eXept Software AG
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
     3
              All Rights Reserved
9553
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
     4
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
     5
 This software is furnished under a license and may be used
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
     6
 only in accordance with the terms of that license and with the
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
     7
 inclusion of the above copyright notice.   This software may not
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
     8
 be provided or otherwise made available to, or used by, any
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
     9
 other person.  No title to or ownership of the software is
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
    10
 hereby transferred.
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
    11
"
9671
cb20763db715 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9667
diff changeset
    12
"{ Package: 'stx:libbasic' }"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
    13
9569
b0bf179c9bf5 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9559
diff changeset
    14
Object subclass:#ProjectDefinition
13820
f46f7306eea2 changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents: 13809
diff changeset
    15
	instanceVariableNames:''
f46f7306eea2 changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents: 13809
diff changeset
    16
	classVariableNames:'LibraryType GUIApplicationType NonGUIApplicationType
f46f7306eea2 changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents: 13809
diff changeset
    17
		PackagesBeingLoaded Verbose AbbrevDictionary AccessLock'
f46f7306eea2 changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents: 13809
diff changeset
    18
	poolDictionaries:''
f46f7306eea2 changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents: 13809
diff changeset
    19
	category:'System-Support-Projects'
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
    20
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
    21
14580
b9514d8a5211 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14577
diff changeset
    22
ProjectDefinition class instanceVariableNames:'safeForOverwrittenMethods extensionOverwriteInfo projectIsLoaded'
9607
3cae5cf71c03 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9601
diff changeset
    23
3cae5cf71c03 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9601
diff changeset
    24
"
3cae5cf71c03 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9601
diff changeset
    25
 No other class instance variables are inherited by this class.
3cae5cf71c03 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9601
diff changeset
    26
"
3cae5cf71c03 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9601
diff changeset
    27
!
3cae5cf71c03 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9601
diff changeset
    28
13592
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
    29
Object subclass:#AbbrevEntry
13820
f46f7306eea2 changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents: 13809
diff changeset
    30
	instanceVariableNames:'className fileName category numClassInstVars'
f46f7306eea2 changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents: 13809
diff changeset
    31
	classVariableNames:''
f46f7306eea2 changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents: 13809
diff changeset
    32
	poolDictionaries:''
f46f7306eea2 changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents: 13809
diff changeset
    33
	privateIn:ProjectDefinition
13592
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
    34
!
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
    35
9569
b0bf179c9bf5 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9559
diff changeset
    36
!ProjectDefinition class methodsFor:'documentation'!
9553
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
    37
12210
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    38
buildingMakefiles
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    39
"
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    40
    You can define additional rules and flag settings for use in the makeFile generation:
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    41
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    42
    redefinable build-file attributes:
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
    43
        stcOptimizationOptions  -> STCLOCALOPT
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
    44
        stcWarningOptions       -> STCLOCALOPT
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
    45
        localIncludes_unix      -> LOCALINCLUDES (Make.proto)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
    46
        localIncludes_win32     -> LOCALINCLUDES (bc.mak)
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
    47
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
    48
    for applications:
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
    49
        startupClassName
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
    50
        startupSelector
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
    51
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
    52
    for libraries:
12210
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    53
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    54
"
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    55
!
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    56
9553
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
    57
copyright
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
    58
"
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
    59
 COPYRIGHT (c) 2006 by eXept Software AG
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
    60
              All Rights Reserved
9553
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
    61
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
    62
 This software is furnished under a license and may be used
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
    63
 only in accordance with the terms of that license and with the
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
    64
 inclusion of the above copyright notice.   This software may not
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
    65
 be provided or otherwise made available to, or used by, any
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
    66
 other person.  No title to or ownership of the software is
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
    67
 hereby transferred.
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
    68
"
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
    69
!
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
    70
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
    71
documentation
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
    72
"
12210
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    73
    As ST/X is (still) very tightly bound with stc, we keep the package and project information
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    74
    in a class-object (instead of some Project-object). This has the advantage, that it can be
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    75
    compiled and included in a compiled class library just like any other class.
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    76
    Every package includes an subclass of me (an instance of my meta), which provides useful
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    77
    information about the versioning and packaging. Me myself, I know how to generate dependency
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    78
    information and can generate makefiles and other build-support files for compilation.
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    79
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    80
    Some special notes about extension methods:
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    81
    if a package is loaded (Smalltalk loadPackage:'foo:bar/baz'), any already loaded package of which
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    82
    methods are overwritten by an extension of this package, the other package is asked to safe those
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    83
    methods in its safe(ForOverwrittenMethods). Thus, if the other package or any of its classes is asked
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    84
    to file itself out, it can do so using the safe (otherwise, you'D not be able to checkin a class while
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    85
    it has an overriding extension loaded).
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    86
    Also, the information about which other package was in charge when a method is overwritten is recorded in
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    87
    extensionOverwriteInfo. This is used to correctly reinstall an overwritten method, whenever a package is
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
    88
    unloaded.
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
    89
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
    90
"
9553
0ba9e1ed1aee *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9551
diff changeset
    91
! !
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
    92
9569
b0bf179c9bf5 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9559
diff changeset
    93
!ProjectDefinition class methodsFor:'instance creation'!
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
    94
12371
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
    95
definitionClassForMonticelloPackage:aMonicelloPackagename
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
    96
    ^ self definitionClassForMonticelloPackage:aMonicelloPackagename createIfAbsent:false
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
    97
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
    98
    "
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
    99
     self definitionClassForMonticelloPackage:'foobar'
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   100
    "
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   101
!
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   102
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   103
definitionClassForMonticelloPackage:aMonicelloPackagename createIfAbsent:createIfAbsent
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   104
    ^ self allSubclasses
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   105
        detect:[:eachProjectDefinition |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   106
            eachProjectDefinition monticelloPackageName = aMonicelloPackagename ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   107
        ifNone:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   108
            |dfn squeakPackageInfo|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   109
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   110
            createIfAbsent ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   111
                dfn := ApplicationDefinition
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   112
                    definitionClassForPackage:'mc:',aMonicelloPackagename createIfAbsent:true projectType:GUIApplicationType.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   113
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   114
                "/ if the squeak-stuff is loaded, use it.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   115
                PackageInfo notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   116
                    squeakPackageInfo := PackageInfo allSubclasses
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   117
                                            detect:[:pi | pi new packageName = aMonicelloPackagename] ifNone:nil.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   118
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   119
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   120
                squeakPackageInfo notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   121
                    dfn classNames:(squeakPackageInfo new classes collect:[:each | each name]).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   122
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   123
            ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   124
                nil
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   125
            ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   126
        ]
12371
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   127
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   128
    "
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   129
     self definitionClassForMonticelloPackage:'foobar'
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   130
     self definitionClassForMonticelloPackage:'foobar' createIfAbsent:true
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   131
    "
13118
06c6d0c09bb2 changed: #definitionClassForMonticelloPackage:createIfAbsent:
Claus Gittinger <cg@exept.de>
parents: 13090
diff changeset
   132
06c6d0c09bb2 changed: #definitionClassForMonticelloPackage:createIfAbsent:
Claus Gittinger <cg@exept.de>
parents: 13090
diff changeset
   133
    "Modified: / 30-10-2010 / 00:26:07 / cg"
12371
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   134
!
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   135
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   136
definitionClassForPackage:aPackageID
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   137
    ^ self definitionClassForPackage:aPackageID createIfAbsent:false
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   138
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   139
    "Modified: / 17-08-2006 / 14:33:35 / cg"
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   140
!
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   141
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   142
definitionClassForPackage:aPackageID createIfAbsent:doCreateIfAbsent
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   143
    ^ self definitionClassForPackage:aPackageID createIfAbsent:doCreateIfAbsent projectType:nil
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   144
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   145
    "Modified: / 23-08-2006 / 14:29:15 / cg"
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   146
!
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   147
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   148
definitionClassForPackage: aPackageID createIfAbsent: doCreateIfAbsent projectType:typeOrNil
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   149
    |packageDefinitionClassName class|
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   150
14812
bdbf34a42482 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14809
diff changeset
   151
    packageDefinitionClassName := self initialClassNameForDefinitionOf:aPackageID.
12371
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   152
    class := Smalltalk classNamed:packageDefinitionClassName.
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   153
    class isNil ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   154
        doCreateIfAbsent ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   155
            class := self newForPackage:aPackageID.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   156
            "setup before prerequisites are defined"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   157
            class setupForType:typeOrNil.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   158
            "/ look what is there and include it; is this ok ?
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   159
            class compileDescriptionMethods
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   160
        ].
12371
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   161
    ] ifFalse:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   162
        typeOrNil notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   163
            class projectType == typeOrNil ifFalse: [
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   164
                class setupForType:typeOrNil.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   165
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   166
        ].
12371
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   167
    ].
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   168
    ^ class
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   169
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   170
    "Created: / 23-08-2006 / 14:29:21 / cg"
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   171
    "Modified: / 23-08-2006 / 15:35:26 / cg"
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   172
!
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   173
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   174
definitionClassForPackage:newProjectID projectType:typeOrNil createIfAbsent:createIfAbsent
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   175
    ^ (self definitionClassForType:typeOrNil)
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   176
            definitionClassForPackage:newProjectID
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   177
            createIfAbsent:createIfAbsent
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   178
            projectType:typeOrNil
12371
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   179
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   180
    "Created: / 23-08-2006 / 14:28:53 / cg"
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   181
!
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   182
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   183
definitionClassForType: type
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   184
    "answer the class that describes a give project type"
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   185
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   186
    (type = LibraryType) ifTrue:[ ^ LibraryDefinition ].
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   187
    (type = GUIApplicationType) ifTrue:[ ^ ApplicationDefinition ].
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   188
    (type = NonGUIApplicationType) ifTrue:[ ^ ApplicationDefinition ].
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   189
    (type = 'Application') ifTrue:[ ^ ApplicationDefinition ].     "/ temporary - for backward compat.
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   190
    self error:'unknown project type'.
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   191
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   192
    "Created: / 17-08-2006 / 14:46:28 / cg"
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   193
    "Modified: / 23-08-2006 / 13:49:27 / cg"
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   194
!
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   195
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   196
newForPackage:packageID
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   197
    ^ self
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   198
        newNamed:(self initialClassNameForDefinitionOf:packageID)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   199
        package:packageID.
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   200
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   201
    "Created: / 11-08-2006 / 14:27:19 / cg"
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   202
!
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   203
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   204
newNamed:newName package:packageID
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   205
    |newClass|
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   206
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   207
    "/ for now, we are strict.
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   208
    self assert:(self initialClassNameForDefinitionOf:packageID) = newName.
9569
b0bf179c9bf5 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9559
diff changeset
   209
    self assert:(self ~~ ProjectDefinition).  "ProjectDefinition is abstract"
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   210
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   211
    newClass := self
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   212
                    subclass:(newName asSymbol)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   213
                    instanceVariableNames:''
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   214
                    classVariableNames:''
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   215
                    poolDictionaries:''
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   216
                    category:(self defaultCategory).
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   217
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   218
    newClass package:packageID asSymbol.
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   219
    ^ newClass
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   220
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   221
    "Created: / 09-08-2006 / 17:57:37 / fm"
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   222
    "Modified: / 09-08-2006 / 19:27:53 / fm"
9569
b0bf179c9bf5 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9559
diff changeset
   223
    "Modified: / 17-08-2006 / 17:24:23 / cg"
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   224
! !
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   225
9569
b0bf179c9bf5 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9559
diff changeset
   226
!ProjectDefinition class methodsFor:'accessing'!
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   227
12575
aa30728c3045 added: #directory
Claus Gittinger <cg@exept.de>
parents: 12574
diff changeset
   228
directory
aa30728c3045 added: #directory
Claus Gittinger <cg@exept.de>
parents: 12574
diff changeset
   229
    "for packageId compatibility"
aa30728c3045 added: #directory
Claus Gittinger <cg@exept.de>
parents: 12574
diff changeset
   230
aa30728c3045 added: #directory
Claus Gittinger <cg@exept.de>
parents: 12574
diff changeset
   231
    ^ self moduleDirectory
aa30728c3045 added: #directory
Claus Gittinger <cg@exept.de>
parents: 12574
diff changeset
   232
aa30728c3045 added: #directory
Claus Gittinger <cg@exept.de>
parents: 12574
diff changeset
   233
    "
aa30728c3045 added: #directory
Claus Gittinger <cg@exept.de>
parents: 12574
diff changeset
   234
     bosch_dapasx_datenbasis_Definition moduleDirectory
aa30728c3045 added: #directory
Claus Gittinger <cg@exept.de>
parents: 12574
diff changeset
   235
     bosch_dapasx_parameter_system_Definition moduleDirectory
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   236
     stx_libbasic3 moduleDirectory
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   237
     cg_croquet moduleDirectory
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   238
     cg_croquet package asPackageId module
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   239
     cg_croquet moduleDirectory
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   240
     stx_goodies_xml_vw moduleDirectory
12575
aa30728c3045 added: #directory
Claus Gittinger <cg@exept.de>
parents: 12574
diff changeset
   241
    "
aa30728c3045 added: #directory
Claus Gittinger <cg@exept.de>
parents: 12574
diff changeset
   242
aa30728c3045 added: #directory
Claus Gittinger <cg@exept.de>
parents: 12574
diff changeset
   243
    "Created: / 08-08-2006 / 20:25:39 / fm"
aa30728c3045 added: #directory
Claus Gittinger <cg@exept.de>
parents: 12574
diff changeset
   244
    "Modified: / 18-08-2006 / 12:18:33 / cg"
aa30728c3045 added: #directory
Claus Gittinger <cg@exept.de>
parents: 12574
diff changeset
   245
!
aa30728c3045 added: #directory
Claus Gittinger <cg@exept.de>
parents: 12574
diff changeset
   246
13823
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   247
extensionsRevisionInfoForManager:managerOrNil
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   248
    "return the revisionInfo object for my extensions for a particular source code manager.
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   249
     Return nil, if there is either no manager, or I have no extensions"
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   250
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   251
    |mgr versionMethod revString|
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   252
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   253
    (mgr := managerOrNil) isNil ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   254
        mgr := SourceCodeManagerUtilities default sourceCodeManagerFor:self.
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   255
        mgr isNil ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   256
            ^ nil
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   257
        ].
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   258
    ].
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   259
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   260
    versionMethod := mgr nameOfVersionMethodForExtensions.
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   261
    (self class implements:versionMethod) ifFalse:[^ nil].
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   262
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   263
    revString := self perform:(mgr nameOfVersionMethodForExtensions) ifNotUnderstood:nil.
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   264
    revString isNil ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   265
        ^ nil.
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   266
    ].
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   267
    ^ mgr revisionInfoFromString:revString.
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   268
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   269
    "
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   270
     (stx_libcomp extensionsRevisionInfoForManager:nil) revision  
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   271
     (stx_libbasic extensionsRevisionInfoForManager:nil) 
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   272
    "
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   273
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   274
    "Created: / 25-11-2011 / 14:34:01 / cg"
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   275
!
Claus Gittinger <cg@exept.de>
parents: 13820
diff changeset
   276
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   277
initialClassNameForDefinitionOf:aPackageId
12360
18b9a4b30466 preps to allow for monticello packages to be loaded
Claus Gittinger <cg@exept.de>
parents: 12357
diff changeset
   278
    "given a package-ID, return an appropriate class name for this package"
18b9a4b30466 preps to allow for monticello packages to be loaded
Claus Gittinger <cg@exept.de>
parents: 12357
diff changeset
   279
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   280
    |s|
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   281
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   282
    s := aPackageId asString copy replaceAny:':/' with:$_.
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   283
    (s endsWith:$_) ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   284
        s := s copyWithoutLast:1
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   285
    ].
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   286
    ^ s
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   287
12186
Claus Gittinger <cg@exept.de>
parents: 12143
diff changeset
   288
    "
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   289
     DapasXProject initialClassNameForDefinitionOf:'bosch:dapasx/interactiver_editor'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   290
     DapasXProject initialClassNameForDefinitionOf:'stx:libbasic'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   291
     DapasXProject initialClassNameForDefinitionOf:'stx:goodies/xml'
12186
Claus Gittinger <cg@exept.de>
parents: 12143
diff changeset
   292
    "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   293
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   294
    "Created: / 09-08-2006 / 17:44:47 / fm"
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   295
    "Modified: / 11-08-2006 / 14:00:05 / cg"
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   296
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   297
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   298
libraryName
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
   299
    ^ self package asPackageId libraryName
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   300
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   301
    "
9688
aa6ccbfbd00b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9685
diff changeset
   302
     bosch_dapasx_datenbasis libraryName
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
   303
     stx_libbasic3 libraryName
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   304
    "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   305
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   306
    "Modified: / 09-08-2006 / 18:20:29 / fm"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
   307
    "Modified: / 18-08-2006 / 12:36:45 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   308
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   309
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   310
libraryNameFor:aProjectID
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
   311
    ^ aProjectID asPackageId libraryName
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   312
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   313
    "
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
   314
     bosch_dapasx_datenbasis libraryName
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
   315
     stx_libbasic3 libraryNameFor:'stx:libbasic'
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   316
     stx_libbasic3 libraryNameFor:'bosch:dapasx/datenbasis'
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   317
    "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   318
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   319
    "Modified: / 09-08-2006 / 18:20:29 / fm"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
   320
    "Modified: / 18-08-2006 / 12:37:02 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   321
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   322
14577
7cb6091c3966 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14547
diff changeset
   323
loadDirectory
7cb6091c3966 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14547
diff changeset
   324
    "if I was loaded from a directory (as oposed to loaded via a dll or from a scm),
7cb6091c3966 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14547
diff changeset
   325
     return that directory. Otherwise return nil."
7cb6091c3966 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14547
diff changeset
   326
14583
266314c7fbfc class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14580
diff changeset
   327
    ^ self getAttribute:#projectDirectory
14577
7cb6091c3966 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14547
diff changeset
   328
!
7cb6091c3966 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14547
diff changeset
   329
7cb6091c3966 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14547
diff changeset
   330
loadDirectory:aDirectory
7cb6091c3966 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14547
diff changeset
   331
    "remember the directory from which I was loaded from"
7cb6091c3966 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14547
diff changeset
   332
14583
266314c7fbfc class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14580
diff changeset
   333
    self setAttribute:#projectDirectory to:aDirectory
14577
7cb6091c3966 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14547
diff changeset
   334
!
7cb6091c3966 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14547
diff changeset
   335
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   336
module
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   337
    ^ self moduleOfClass:self
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   338
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   339
    "
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   340
       bosch_dapasx_datenbasis_Definition module
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   341
       DapasX_Datenbasis module
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   342
       stx_libbasic3 module
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   343
       stx_libbasic3 directory
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   344
    "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   345
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   346
    "Created: / 08-08-2006 / 20:24:53 / fm"
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   347
    "Modified: / 09-08-2006 / 16:16:37 / fm"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
   348
    "Modified: / 17-08-2006 / 20:50:46 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   349
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   350
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   351
moduleDirectory
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
   352
    ^ (PackageId from:self package) directory
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   353
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   354
    "
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
   355
     bosch_dapasx_datenbasis_Definition moduleDirectory
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
   356
     bosch_dapasx_parameter_system_Definition moduleDirectory
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   357
     stx_libbasic3 moduleDirectory
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   358
     cg_croquet moduleDirectory
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   359
     cg_croquet package asPackageId module
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   360
     cg_croquet moduleDirectory
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   361
     stx_goodies_xml_vw moduleDirectory
14339
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
   362
     cg_demos_demo1 moduleDirectory 
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   363
    "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   364
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   365
    "Created: / 08-08-2006 / 20:25:39 / fm"
14339
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
   366
    "Modified (comment): / 05-09-2012 / 10:07:18 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   367
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   368
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   369
moduleDirectoryFor:aProjectID
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   370
    ^ (aProjectID subStrings:$:) last
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   371
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   372
    "
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   373
        bosch_dapasx_datenbasis_Definition moduleDirectory
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   374
        bosch_dapasx_parameter_system_Definition moduleDirectory
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   375
    "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   376
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   377
    "Created: / 08-08-2006 / 20:25:39 / fm"
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   378
    "Modified: / 17-08-2006 / 14:13:41 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   379
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   380
9891
62a779fbc130 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9888
diff changeset
   381
moduleDirectory_win32
62a779fbc130 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9888
diff changeset
   382
    ^ (PackageId from:self package) directory copy replaceAll:$/ with:$\
62a779fbc130 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9888
diff changeset
   383
62a779fbc130 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9888
diff changeset
   384
    "
62a779fbc130 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9888
diff changeset
   385
     bosch_dapasx_datenbasis moduleDirectory_win32
62a779fbc130 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9888
diff changeset
   386
     bosch_dapasx_parameter_system moduleDirectory_win32
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   387
     stx_libbasic3 moduleDirectory_win32
9891
62a779fbc130 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9888
diff changeset
   388
    "
62a779fbc130 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9888
diff changeset
   389
62a779fbc130 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9888
diff changeset
   390
    "Created: / 14-09-2006 / 20:19:17 / cg"
62a779fbc130 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9888
diff changeset
   391
!
62a779fbc130 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9888
diff changeset
   392
10562
929109c6ad37 *** empty log message ***
fm
parents: 10507
diff changeset
   393
moduleDirectory_win32For: projectID
929109c6ad37 *** empty log message ***
fm
parents: 10507
diff changeset
   394
929109c6ad37 *** empty log message ***
fm
parents: 10507
diff changeset
   395
    ^(self moduleDirectoryFor:projectID) copy replaceAll:$/ with:$\
929109c6ad37 *** empty log message ***
fm
parents: 10507
diff changeset
   396
929109c6ad37 *** empty log message ***
fm
parents: 10507
diff changeset
   397
    "
929109c6ad37 *** empty log message ***
fm
parents: 10507
diff changeset
   398
     self moduleDirectory_win32For: #'bosch:dapasx/pav_vergleich'
929109c6ad37 *** empty log message ***
fm
parents: 10507
diff changeset
   399
     self moduleDirectory_win32For: #'stx:goodies/xml/stx'
929109c6ad37 *** empty log message ***
fm
parents: 10507
diff changeset
   400
     self moduleDirectory_win32For: #'stx:libbasic2'
929109c6ad37 *** empty log message ***
fm
parents: 10507
diff changeset
   401
    "
929109c6ad37 *** empty log message ***
fm
parents: 10507
diff changeset
   402
!
929109c6ad37 *** empty log message ***
fm
parents: 10507
diff changeset
   403
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   404
moduleFor:aProjectID
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   405
    ^ (aProjectID subStrings:$:) first
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   406
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   407
    "
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   408
       DapasXProject module
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   409
       DapasX_Datenbasis module
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   410
    "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   411
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   412
    "Created: / 09-08-2006 / 16:16:16 / fm"
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   413
    "Modified: / 17-08-2006 / 14:13:46 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   414
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   415
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   416
moduleOfClass:aClass
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   417
    ^ self moduleFor:aClass package
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   418
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   419
    "
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   420
       DapasXProject module
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   421
       DapasX_Datenbasis module
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   422
    "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   423
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   424
    "Created: / 09-08-2006 / 16:16:16 / fm"
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   425
    "Modified: / 17-08-2006 / 14:13:51 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   426
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   427
12360
18b9a4b30466 preps to allow for monticello packages to be loaded
Claus Gittinger <cg@exept.de>
parents: 12357
diff changeset
   428
monticelloPackageName
18b9a4b30466 preps to allow for monticello packages to be loaded
Claus Gittinger <cg@exept.de>
parents: 12357
diff changeset
   429
    "hook for packages which have been loaded from monticello"
18b9a4b30466 preps to allow for monticello packages to be loaded
Claus Gittinger <cg@exept.de>
parents: 12357
diff changeset
   430
18b9a4b30466 preps to allow for monticello packages to be loaded
Claus Gittinger <cg@exept.de>
parents: 12357
diff changeset
   431
    ^ nil
18b9a4b30466 preps to allow for monticello packages to be loaded
Claus Gittinger <cg@exept.de>
parents: 12357
diff changeset
   432
!
18b9a4b30466 preps to allow for monticello packages to be loaded
Claus Gittinger <cg@exept.de>
parents: 12357
diff changeset
   433
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   434
msdosPathToPackage:toPackageID from:fromPackageID
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   435
    "Returns the path to the package defined by aPackageID relative to my path"
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   436
10976
5696faf1af02 fix #msdosPathToPackage:from: (do not use , since it is relative to the current directory)
Stefan Vogel <sv@exept.de>
parents: 10974
diff changeset
   437
    |parts1 parts2 common up down|
9852
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   438
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   439
    parts1 := fromPackageID asCollectionOfSubstringsSeparatedByAny:':/'.
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   440
    parts2 := toPackageID asCollectionOfSubstringsSeparatedByAny:':/'.
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   441
    common := parts1 commonPrefixWith:parts2.
10976
5696faf1af02 fix #msdosPathToPackage:from: (do not use , since it is relative to the current directory)
Stefan Vogel <sv@exept.de>
parents: 10974
diff changeset
   442
    up := ((1 to:parts1 size - common size) collect:[:p | '..']) asStringWith:'\'.
5696faf1af02 fix #msdosPathToPackage:from: (do not use , since it is relative to the current directory)
Stefan Vogel <sv@exept.de>
parents: 10974
diff changeset
   443
    down := (parts2 copyFrom:common size+1) asStringWith:'\'.
5696faf1af02 fix #msdosPathToPackage:from: (do not use , since it is relative to the current directory)
Stefan Vogel <sv@exept.de>
parents: 10974
diff changeset
   444
    up isEmpty ifTrue:[
5696faf1af02 fix #msdosPathToPackage:from: (do not use , since it is relative to the current directory)
Stefan Vogel <sv@exept.de>
parents: 10974
diff changeset
   445
       down isEmpty ifTrue:[^ '.'].
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   446
        ^ down.
9852
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   447
    ].
10976
5696faf1af02 fix #msdosPathToPackage:from: (do not use , since it is relative to the current directory)
Stefan Vogel <sv@exept.de>
parents: 10974
diff changeset
   448
    down isEmpty ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   449
        ^ up.
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   450
    ].
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   451
    ^ up, '\', down
9901
6ea34c2d6a54 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9898
diff changeset
   452
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   453
    "
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   454
     self msdosPathToPackage:'bosch:dapasx/kernel' from:'bosch:dapasx/application'
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   455
     self msdosPathToPackage:'stx:libbasic' from:'bosch:dapasx/application'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   456
     self msdosPathToPackage:'bosch:dapasx/application' from:'stx:libbasic'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   457
     self msdosPathToPackage:'exept:expecco' from:'exept:expecco/application'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   458
     self msdosPathToPackage:'exept:expecco/application' from:'exept:expecco'
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   459
    "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   460
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   461
    "Created: / 17-08-2006 / 14:26:39 / cg"
9901
6ea34c2d6a54 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9898
diff changeset
   462
    "Modified: / 14-09-2006 / 22:04:56 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   463
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   464
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   465
msdosPathToTopFor:aProjectID
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   466
    "Returns the path to stx counting the number of $/ and $: in the package name and adding for each one '../' to get the ST/X top directory"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   467
9852
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   468
    |parts|
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   469
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   470
    parts := aProjectID asCollectionOfSubstringsSeparatedByAny:':/'.
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   471
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   472
    aProjectID asPackageId module = 'stx' ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   473
        parts size == 1 ifTrue:[^ '.'].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   474
        ^ (((2 to:parts size-1) collect:[:p | '..\']) asStringWith:'') , '..'
9852
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   475
    ].
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   476
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   477
    ^ ((parts collect:[:p | '..\']) asStringWith:'') , 'stx'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   478
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   479
    "
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   480
     self msdosPathToTopFor: #'bosch'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   481
     self msdosPathToTopFor: #'bosch:dapasx'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   482
     self msdosPathToTopFor: #'bosch:dapasx/datenbasis'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   483
     self msdosPathToTopFor: #'stx'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   484
     self msdosPathToTopFor: #'stx:libview'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   485
     self msdosPathToTopFor: #'stx:goodies/foo'
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   486
    "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   487
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   488
    "Created: / 09-08-2006 / 15:45:54 / fm"
9852
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   489
    "Modified: / 14-09-2006 / 14:49:17 / cg"
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   490
!
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   491
12028
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
   492
packageDirectory
14577
7cb6091c3966 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14547
diff changeset
   493
    "if I was loaded from a directory (as oposed to loaded via a dll or from a scm),
7cb6091c3966 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14547
diff changeset
   494
     return that directory. 
7cb6091c3966 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14547
diff changeset
   495
     Otherwise ask Smalltalk for my package directory a long the package path."
7cb6091c3966 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14547
diff changeset
   496
14580
b9514d8a5211 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14577
diff changeset
   497
    |loadDirectory|
b9514d8a5211 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14577
diff changeset
   498
14586
4e6d15f5defc class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14585
diff changeset
   499
    (loadDirectory := self loadDirectory) ifNotNil:[ ^ loadDirectory ].
12315
71599fb91dcf comment/format in: #packageDirectory
Claus Gittinger <cg@exept.de>
parents: 12314
diff changeset
   500
    ^ Smalltalk packageDirectoryForPackageId: self package
12028
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
   501
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
   502
    "Created: / 15-06-2009 / 12:01:18 / Jan Vrany <vranyj1@fel.cvut.cz>"
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
   503
!
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
   504
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   505
packageName
9688
aa6ccbfbd00b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9685
diff changeset
   506
    "the last component"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   507
9688
aa6ccbfbd00b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9685
diff changeset
   508
    ^ self packageNameFor: self package
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   509
9688
aa6ccbfbd00b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9685
diff changeset
   510
    "
10810
e62a55885c85 New: #allPreRequisitesSorted
Stefan Vogel <sv@exept.de>
parents: 10806
diff changeset
   511
     stx_libwidg2 packageName
9688
aa6ccbfbd00b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9685
diff changeset
   512
     bosch_dapasx_hw_schnittstellen packageName
aa6ccbfbd00b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9685
diff changeset
   513
     bosch_dapasx_datenbasis packageName
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   514
     bosch_dapasx_parameter_system packageName
9688
aa6ccbfbd00b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9685
diff changeset
   515
    "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   516
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   517
    "Created: / 08-08-2006 / 20:24:53 / fm"
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   518
    "Modified: / 09-08-2006 / 16:16:37 / fm"
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   519
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   520
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   521
packageNameFor: aProjectID
9688
aa6ccbfbd00b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9685
diff changeset
   522
    ^ (aProjectID asCollectionOfSubstringsSeparatedByAny:':/') last.
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   523
9688
aa6ccbfbd00b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9685
diff changeset
   524
    "
aa6ccbfbd00b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9685
diff changeset
   525
     bosch_dapasx_hw_schnittstellen packageName
aa6ccbfbd00b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9685
diff changeset
   526
     bosch_dapasx_datenbasis packageName
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   527
     bosch_dapasx_parameter_system packageName
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   528
     cg_croquet packageName
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   529
     stx_goodies_xml_vw packageName
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   530
     stx_goodies_xml_vw packageDirectory
9688
aa6ccbfbd00b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9685
diff changeset
   531
    "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   532
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   533
    "Created: / 08-08-2006 / 20:24:53 / fm"
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   534
    "Modified: / 09-08-2006 / 16:16:37 / fm"
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   535
    "Modified: / 11-08-2006 / 14:02:32 / cg"
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   536
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   537
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   538
parentProject
10306
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
   539
    ^ (self parentProjectFor: self package)
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   540
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   541
"
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   542
    bosch_dapasx_hw_schnittstellen_Definition  parentProject
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   543
    DapasX_Datenbasis parentProject
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   544
"
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   545
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   546
    "Created: / 07-08-2006 / 20:18:27 / fm"
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   547
    "Modified: / 08-08-2006 / 10:47:37 / fm"
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   548
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   549
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   550
parentProjectFor: aProjectID
10306
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
   551
    ^ (aProjectID subStrings: $/) first
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   552
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   553
"
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
   554
    bosch_dapasx_hw_schnittstellen parentProject
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   555
"
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   556
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   557
    "Created: / 07-08-2006 / 20:18:27 / fm"
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   558
    "Modified: / 08-08-2006 / 10:47:37 / fm"
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
   559
    "Modified: / 23-08-2006 / 15:07:36 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   560
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   561
10366
8990764f8911 #compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents: 10350
diff changeset
   562
pathSeparator:platformName
8990764f8911 #compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents: 10350
diff changeset
   563
    platformName == #unix ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   564
        ^ self pathSeparator_unix
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   565
    ].
10366
8990764f8911 #compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents: 10350
diff changeset
   566
    platformName == #win32 ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   567
        ^ self pathSeparator_win32
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   568
    ].
10366
8990764f8911 #compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents: 10350
diff changeset
   569
    self error:'unknown operating system platform'.
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   570
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   571
    "Created: / 14-09-2006 / 13:38:00 / cg"
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   572
!
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   573
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   574
pathSeparator_unix
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   575
    ^ $/
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   576
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   577
    "Created: / 14-09-2006 / 13:37:18 / cg"
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   578
!
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   579
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   580
pathSeparator_win32
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   581
    ^ $\
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   582
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   583
    "Created: / 14-09-2006 / 13:37:23 / cg"
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   584
!
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   585
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   586
pathTo:aBaseFilename inPackage:aPackageID architecture:arch
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   587
    "Returns the path to stx counting the number of $/ and $: in the package name and adding for each one '../' to get the ST/X top directory"
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   588
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   589
    |p|
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   590
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   591
    arch == #unix ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   592
        p := (self pathToPackage_unix:aPackageID).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   593
        aBaseFilename isNil ifTrue:[^ p].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   594
        ^ p , '/' , aBaseFilename
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   595
    ].
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   596
    arch == #win32 ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   597
        p := self pathToPackage_win32:aPackageID.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   598
        aBaseFilename isNil ifTrue:[^ p].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   599
        ^ p , '\' , aBaseFilename
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   600
    ].
10366
8990764f8911 #compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents: 10350
diff changeset
   601
    self error:'unknown operating system platform'.
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   602
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   603
    "Created: / 14-09-2006 / 13:29:20 / cg"
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   604
!
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   605
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   606
pathToPackage_unix:aPackageID
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   607
    "Returns the path to stx counting the number of $/ and $: in the package name and adding for each one '../' to get the ST/X top directory"
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   608
10875
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   609
    |rel|
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   610
9880
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   611
    aPackageID asPackageId module = self package asPackageId module ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   612
        ^ self unixPathToPackage:aPackageID from:self package
9880
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   613
    ].
10875
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   614
    rel := self topRelativePathToPackage_unix:aPackageID.
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   615
    (rel startsWith:'stx/') ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   616
        ^ '$(TOP)/', (rel copyFrom:'stx/' size + 1).
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   617
    ] ifFalse:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   618
        ^ '$(TOP)/../', rel
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   619
    ]
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   620
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   621
    "
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   622
     bosch_dapasx_kernel pathToPackage_unix:'bosch:dapasx/kernel'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   623
     bosch_dapasx_kernel pathToPackage_unix:'bosch:dapasx/support'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   624
     stx_libbasic pathToPackage_unix:'bosch:dapasx/kernel'
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   625
    "
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   626
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   627
    "Modified: / 16-08-2006 / 18:55:41 / User"
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   628
    "Created: / 14-09-2006 / 13:21:23 / cg"
9880
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   629
    "Modified: / 14-09-2006 / 15:23:59 / cg"
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   630
!
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   631
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   632
pathToPackage_win32:aPackageID
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   633
    "Returns the path to the package defined by aPackageID relative to my path"
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   634
10875
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   635
    |rel|
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   636
9880
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   637
    aPackageID asPackageId module = self package asPackageId module ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   638
        ^ self msdosPathToPackage:aPackageID from:self package
9880
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   639
    ].
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   640
10875
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   641
    rel := self topRelativePathToPackage_win32:aPackageID.
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   642
    (rel startsWith:'stx\') ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   643
        ^ '$(TOP)\', (rel copyFrom:'stx\' size + 1).
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   644
    ] ifFalse:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   645
        ^ '$(TOP)\..\', rel
10875
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   646
    ]
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   647
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   648
    "
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   649
     self pathToPackage_win32:'bosch:dapasx/kernel'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   650
     bosch_dapasx_kernel pathToPackage_win32:'bosch:dapasx/kernel'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   651
     bosch_dapasx_kernel pathToPackage_win32:'bosch:dapasx/support'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   652
     stx_libbasic pathToPackage_win32:'bosch:dapasx/kernel'
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   653
    "
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   654
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   655
    "Created: / 14-09-2006 / 13:22:52 / cg"
9880
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   656
    "Modified: / 14-09-2006 / 15:28:45 / cg"
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   657
!
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   658
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   659
pathToTop_unix
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   660
    "Returns the path to stx counting the number of $/ and $: in the package name and adding for each one '../' to get the ST/X top directory"
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   661
9852
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   662
    ^ self unixPathToTopFor:self package.
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   663
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   664
    "
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   665
     bosch_dapasx_kernel pathToTop_unix
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   666
     stx_goodies_xml pathToTop_unix
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   667
     stx_libhtml pathToTop_unix
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   668
     stx_goodies_refactoryBrowser_changes pathToTop_unix
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   669
    "
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   670
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   671
    "Created: / 09-08-2006 / 15:45:54 / fm"
9852
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   672
    "Modified: / 14-09-2006 / 15:01:47 / cg"
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   673
!
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   674
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   675
pathToTop_win32
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   676
    "Returns the path to stx counting the number of $/ and $: in the package name and adding for each one '../' to get the ST/X top directory"
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   677
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   678
    ^self msdosPathToTopFor: self package
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   679
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   680
    "
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   681
     bosch_dapasx_datenbasis pathToTop_win32
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   682
     stx_libbasic pathToTop_win32
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   683
    "
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   684
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   685
    "Created: / 09-08-2006 / 15:45:54 / fm"
9831
02b8fd184e2b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9829
diff changeset
   686
    "Modified: / 07-09-2006 / 15:51:00 / cg"
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   687
!
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
   688
10433
4768502f5cbf Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents: 10430
diff changeset
   689
projectIsLoaded
4768502f5cbf Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents: 10430
diff changeset
   690
    "answer true, if this project is completely loaded into the image"
4768502f5cbf Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents: 10430
diff changeset
   691
10434
25f76184bf81 project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents: 10433
diff changeset
   692
    projectIsLoaded isNil ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   693
        projectIsLoaded := false.
10433
4768502f5cbf Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents: 10430
diff changeset
   694
    ].
10434
25f76184bf81 project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents: 10433
diff changeset
   695
    ^ projectIsLoaded
10433
4768502f5cbf Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents: 10430
diff changeset
   696
4768502f5cbf Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents: 10430
diff changeset
   697
    "
4768502f5cbf Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents: 10430
diff changeset
   698
      stx_libbasic projectIsLoaded
13251
a7dbdfdc87e6 changed:
Stefan Vogel <sv@exept.de>
parents: 13216
diff changeset
   699
      (ProjectDefinition definitionClassForPackage:#'stx:libbasic') projectIsLoaded
10433
4768502f5cbf Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents: 10430
diff changeset
   700
    "
4768502f5cbf Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents: 10430
diff changeset
   701
!
4768502f5cbf Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents: 10430
diff changeset
   702
4768502f5cbf Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents: 10430
diff changeset
   703
projectIsLoaded:something
10434
25f76184bf81 project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents: 10433
diff changeset
   704
    projectIsLoaded := something.
13251
a7dbdfdc87e6 changed:
Stefan Vogel <sv@exept.de>
parents: 13216
diff changeset
   705
    something ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   706
        "register myself as dependent - I want to get notified on method changes"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   707
        self class addDependent:self.
10434
25f76184bf81 project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents: 10433
diff changeset
   708
    ].
10433
4768502f5cbf Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents: 10430
diff changeset
   709
!
4768502f5cbf Do not try to load already loaded projects
Stefan Vogel <sv@exept.de>
parents: 10430
diff changeset
   710
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   711
requiredProjects
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
   712
    ^ Set new
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
   713
        addAll:self effectivePreRequisites;
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
   714
        addAll:self subProjects;
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
   715
        yorself.
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   716
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   717
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   718
topRelativePathTo:aBaseFilename inPackage:aPackageID architecture:arch
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   719
    "Returns the path to stx counting the number of $/ and $: in the package name
10366
8990764f8911 #compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents: 10350
diff changeset
   720
     and adding for each one '../' to get the ST/X top directory"
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   721
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   722
    |p|
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   723
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   724
    arch == #unix ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   725
        p := (self topRelativePathToPackage_unix:aPackageID).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   726
        aBaseFilename isNil ifTrue:[^ p].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   727
        ^ p , '/' , aBaseFilename
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   728
    ].
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   729
    arch == #win32 ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   730
        p := self topRelativePathToPackage_win32:aPackageID.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   731
        aBaseFilename isNil ifTrue:[^ p].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   732
        ^ p , '\' , aBaseFilename
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   733
    ].
10366
8990764f8911 #compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents: 10350
diff changeset
   734
    self error:'unknown operating system platform'.
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   735
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   736
    "Created: / 14-09-2006 / 13:34:05 / cg"
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   737
!
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   738
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   739
topRelativePathToPackage_unix:aPackageID
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   740
    "Returns the path to the package as specified by aPackageID relative to the top directory"
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   741
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   742
    ^ aPackageID asString copy replaceAny:':/' with:$/
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   743
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   744
    "
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   745
     self topRelativePathToPackage_unix:'stx:goodies/xml'
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   746
     self topRelativePathToPackage_unix:'bosch:dapasx/kernel'
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   747
    "
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   748
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   749
    "Created: / 14-09-2006 / 13:20:40 / cg"
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   750
!
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   751
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   752
topRelativePathToPackage_win32:aPackageID
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   753
    "Returns the path to the package as specified by aPackageID relative to the top directory"
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   754
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   755
    ^ aPackageID asString copy replaceAny:':/' with:$\
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   756
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   757
    "
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   758
     self topRelativePathToPackage_win32:'stx:goodies/xml'
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   759
     self topRelativePathToPackage_win32:'bosch:dapasx/kernel'
9559
06e8b0498471 code cleanup
Claus Gittinger <cg@exept.de>
parents: 9555
diff changeset
   760
    "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   761
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
   762
    "Created: / 14-09-2006 / 13:20:12 / cg"
9852
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   763
!
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   764
9880
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   765
unixPathToPackage:toPackageID from:fromPackageID
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   766
    "Returns the path to the package defined by aPackageID relative to my path"
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   767
10875
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   768
    |parts1 parts2 common up down rel|
9880
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   769
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   770
    parts1 := fromPackageID asCollectionOfSubstringsSeparatedByAny:':/'.
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   771
    parts2 := toPackageID asCollectionOfSubstringsSeparatedByAny:':/'.
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   772
    common := parts1 commonPrefixWith:parts2.
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   773
    common notEmpty ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   774
        up := ((1 to:parts1 size - common size) collect:[:p | '../']) asStringWith:''.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   775
        down := (parts2 copyFrom:common size+1) asStringWith:'/'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   776
        (up isEmpty and:[down isEmpty]) ifTrue:[^ '.'].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   777
        ^ up , down
9880
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   778
    ].
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   779
10875
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   780
    rel := (self topRelativePathToPackage_unix:toPackageID).
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   781
    (rel startsWith:'stx/') ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   782
        ^ '$(TOP)', (rel copyFrom:'stx/' size)
9880
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   783
    ].
10875
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   784
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   785
    ^ '$(TOP)/../', rel.
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   786
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   787
"/    pTop := self unixPathToTopFor:fromPackageID.
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   788
"/    (pTop endsWith:'/stx') ifTrue:[
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   789
"/        pTop := pTop copyButLast:'stx' size.
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   790
"/    ] ifFalse:[
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   791
"/        pTop isEmpty ifTrue:[
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   792
"/            pTop := '../'.
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   793
"/        ] ifFalse:[
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   794
"/            pTop := pTop, '/../'.
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   795
"/        ].
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   796
"/    ].
ed4bd37a995e Fix unix Make.proto generation: resource file copy
Stefan Vogel <sv@exept.de>
parents: 10872
diff changeset
   797
"/    ^ pTop, (self topRelativePathToPackage_unix:toPackageID)
9880
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   798
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   799
    "
10713
5772d2920a27 *** empty log message ***
fm
parents: 10691
diff changeset
   800
     self unixPathToPackage:'bosch:dapasx/kernel' from:'bosch:dapasx/application'
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   801
     self unixPathToPackage:'stx:libbasic' from:'bosch:dapasx/application'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   802
     self unixPathToPackage:'bosch:dapasx/application' from:'stx:libbasic'
9880
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   803
    "
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   804
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   805
    "Created: / 14-09-2006 / 15:21:10 / cg"
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   806
!
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
   807
9852
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   808
unixPathToTopFor:aProjectID
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   809
    "Returns the path to stx counting the number of $/ and $: in the package name and adding for each one '../' to get the ST/X top directory"
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   810
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   811
    |parts|
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   812
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   813
    parts := aProjectID asCollectionOfSubstringsSeparatedByAny:':/'.
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   814
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   815
    aProjectID asPackageId module = 'stx' ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   816
        parts size == 1 ifTrue:[^ ''].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   817
        ^ (((2 to:parts size-1) collect:[:p | '../']) asStringWith:'') , '..'
9852
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   818
    ].
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   819
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   820
    ^ ((parts collect:[:p | '../']) asStringWith:'') , 'stx'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   821
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   822
    "
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   823
     self unixPathToTopFor: #'bosch'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   824
     self unixPathToTopFor: #'bosch:dapasx'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   825
     self unixPathToTopFor: #'bosch:dapasx/datenbasis'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   826
     self unixPathToTopFor: #'stx'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   827
     self unixPathToTopFor: #'stx:libview'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   828
     self unixPathToTopFor: #'stx:goodies/foo'
9852
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   829
    "
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   830
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
   831
    "Created: / 14-09-2006 / 14:59:53 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   832
! !
3a835fa7e38b initial checkin
fm
parents:
diff changeset
   833
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
   834
12339
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   835
!ProjectDefinition class methodsFor:'accessing - packaging'!
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   836
12371
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   837
classNames:aCollectionOfClassNames
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   838
    "set the set of classes"
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   839
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   840
    self classNamesAndAttributes:aCollectionOfClassNames usingCompiler:nil
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   841
!
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   842
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   843
classNamesAndAttributes:newSpec usingCompiler:compilerOrNil
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   844
    "set the set of classes. and attributes
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   845
     Because this requires compilation of my classList-method, a compiler can be passed in,
12371
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   846
     which has to do the job.
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   847
     (this is used by the systembrowser to pass in a CodeGeneratorTool with undo support)"
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   848
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   849
    |oldSpec newCode|
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   850
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   851
    oldSpec := self classNamesAndAttributes.
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   852
    newSpec = oldSpec ifTrue: [^ self].
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   853
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   854
    newCode := self classNamesAndAttributes_codeFor:newSpec.
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   855
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   856
    (compilerOrNil ? self compilerClass)
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   857
        compile:newCode
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   858
        forClass:self theMetaclass
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   859
        inCategory:'description - contents'.
12371
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   860
!
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   861
12339
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   862
excludeClasses:toExclude usingCompiler:compilerOrNil
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   863
    "exclude (remove from classList) a number of classes.
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   864
     Because this requires compilation of my classList-method, a compiler can be passed in,
12339
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   865
     which has to do the job.
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   866
     (this is used by the systembrowser to pass in a CodeGeneratorTool with undo support)"
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   867
12371
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   868
    |newSpec|
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   869
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   870
    newSpec := self classNamesAndAttributes copy.
12339
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   871
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   872
    toExclude do:[:eachClassToExclude |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   873
        |className|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   874
        className := eachClassToExclude theNonMetaclass name.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   875
        (self allClassNames includes:className) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   876
            |idx|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   877
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   878
            idx := newSpec findFirst:[:entry | entry = className or:[entry first = className]].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   879
            idx ~~ 0 ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   880
                newSpec := newSpec copyWithoutIndex:idx.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   881
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   882
        ].
12339
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   883
    ].
12371
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   884
    self classNamesAndAttributes:newSpec usingCompiler:compilerOrNil
12339
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   885
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   886
    "Created: / 30-08-2007 / 18:28:28 / cg"
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   887
!
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   888
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   889
includeClasses:toInclude usingCompiler:compilerOrNil
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   890
    "include (add to classList) a number of classes.
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   891
     Because this requires compilation of my classList-method, a compiler can be passed in,
12339
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   892
     which has to do the job.
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   893
     (this is used by the systembrowser to pass in a CodeGeneratorTool with undo support)"
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   894
12371
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   895
    |oldSpec newSpec|
12339
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   896
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   897
    oldSpec := self classNamesAndAttributes.
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   898
    newSpec := oldSpec copy.
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   899
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   900
    toInclude do:[:eachClassToInclude |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   901
        |className|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   902
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   903
        className := eachClassToInclude theNonMetaclass name.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   904
        (self compiled_classNames includes:className) ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   905
            | idx entry|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   906
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   907
            idx := oldSpec findFirst:[:entry | entry = className or:[entry first = className]].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   908
            idx == 0 ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   909
                newSpec := newSpec copyWith:(Array with:className)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   910
            ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   911
                entry := newSpec at:idx.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   912
                entry isArray ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   913
                    entry := entry copyWithout:#autoload
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   914
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   915
                newSpec at:idx put:entry
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   916
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   917
        ].
12339
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   918
    ].
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   919
12371
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   920
    self classNamesAndAttributes:newSpec usingCompiler:compilerOrNil
12339
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   921
!
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   922
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   923
makeClassesAutoloaded:toMakeAutoloaded usingCompiler:compilerOrNil
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   924
    "include as autoloaded (add to classList) a number of classes.
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   925
     Because this requires compilation of my classList-method, a compiler can be passed in,
12339
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   926
     which has to do the job.
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   927
     (this is used by the systembrowser to pass in a CodeGeneratorTool with undo support)"
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   928
12371
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   929
    |newSpec|
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   930
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   931
    newSpec := self classNamesAndAttributes copy.
12339
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   932
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   933
    toMakeAutoloaded do:[:eachClassToMakeAutoloaded |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   934
        |className|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   935
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   936
        className := eachClassToMakeAutoloaded theNonMetaclass name.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   937
        (self autoloaded_classNames includes:className) ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   938
            |idx entry|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   939
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   940
            idx := newSpec findFirst:[:entry | entry = className or:[entry first = className]].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   941
            idx == 0 ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   942
                newSpec := newSpec copyWith:(Array with:className with:#autoload)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   943
            ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   944
                entry := newSpec at:idx.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   945
                entry isArray ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   946
                    entry := (entry copyWithout:#autoload) copyWith:#autoload.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   947
                ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   948
                    entry := Array with:entry with:#autoload
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   949
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   950
                newSpec at:idx put:entry.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   951
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   952
        ].
12339
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   953
    ].
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   954
12371
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
   955
    self classNamesAndAttributes:newSpec usingCompiler:compilerOrNil
12339
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   956
! !
918b3eddd723 #excludeClasses:usingCompiler:
Claus Gittinger <cg@exept.de>
parents: 12338
diff changeset
   957
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   958
!ProjectDefinition class methodsFor:'accessing - tests'!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   959
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
   960
excludedFromTestSuite
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   961
    "List of testcases and/or tests excluded from testsuite.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   962
     Entries maybe ClassName or #(ClassName testName)
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   963
    "
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   964
    ^ #()
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   965
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   966
    "Created: / 03-06-2011 / 16:56:48 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   967
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   968
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   969
testSuite
13544
4c9779fe1181 commented: #testSuite
Claus Gittinger <cg@exept.de>
parents: 13485
diff changeset
   970
    "generate and return a testSuite containing all of my test-classes"
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   971
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   972
    |suite classes|
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   973
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   974
    suite := TestSuite named:self package.
13695
Claus Gittinger <cg@exept.de>
parents: 13694
diff changeset
   975
    classes := self classes
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
   976
		select:[:each |
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
   977
		    [
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
   978
		    each isLoaded ifFalse:[each autoload].
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
   979
		    (each isTestCaseLike) and:[ each isAbstract not ]
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
   980
		    ] on: Autoload autoloadFailedSignal do:[
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
   981
			false
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
   982
		    ]
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
   983
		].
13544
4c9779fe1181 commented: #testSuite
Claus Gittinger <cg@exept.de>
parents: 13485
diff changeset
   984
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   985
    classes := classes asSortedCollection:[:a :b | a name <= b name ].
13695
Claus Gittinger <cg@exept.de>
parents: 13694
diff changeset
   986
    classes do: [:eachClass |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   987
        | tests |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   988
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   989
        tests := eachClass suite tests.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   990
        tests := tests reject:[:test|self shouldExcludeTest: test].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
   991
        suite addTests: tests
13544
4c9779fe1181 commented: #testSuite
Claus Gittinger <cg@exept.de>
parents: 13485
diff changeset
   992
    ].
4c9779fe1181 commented: #testSuite
Claus Gittinger <cg@exept.de>
parents: 13485
diff changeset
   993
    ^ suite
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   994
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   995
    "Created: / 01-04-2011 / 15:20:02 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
   996
    "Modified: / 03-06-2011 / 17:07:04 / Jan Vrany <jan.vrany@fit.cvut.cz>"
13568
b11206771e27 changed: #testSuite
Claus Gittinger <cg@exept.de>
parents: 13559
diff changeset
   997
    "Modified: / 08-08-2011 / 14:59:45 / cg"
12028
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
   998
! !
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
   999
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1000
!ProjectDefinition class methodsFor:'class initialization'!
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1001
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1002
initialize
14776
28a1f265cd65 add user friendly name to semaphores
Stefan Vogel <sv@exept.de>
parents: 14764
diff changeset
  1003
    AccessLock isNil ifTrue:[
28a1f265cd65 add user friendly name to semaphores
Stefan Vogel <sv@exept.de>
parents: 14764
diff changeset
  1004
        LibraryType := #Library.
28a1f265cd65 add user friendly name to semaphores
Stefan Vogel <sv@exept.de>
parents: 14764
diff changeset
  1005
        GUIApplicationType := #'GUI-Application'.
28a1f265cd65 add user friendly name to semaphores
Stefan Vogel <sv@exept.de>
parents: 14764
diff changeset
  1006
        NonGUIApplicationType := #'NonGUI-Application'.
28a1f265cd65 add user friendly name to semaphores
Stefan Vogel <sv@exept.de>
parents: 14764
diff changeset
  1007
        AccessLock := Semaphore forMutualExclusion name:'ProjectDefinition Lock'.
28a1f265cd65 add user friendly name to semaphores
Stefan Vogel <sv@exept.de>
parents: 14764
diff changeset
  1008
        Verbose := false.
28a1f265cd65 add user friendly name to semaphores
Stefan Vogel <sv@exept.de>
parents: 14764
diff changeset
  1009
    ].
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1010
10121
067b986ee77b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10119
diff changeset
  1011
    "
067b986ee77b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10119
diff changeset
  1012
     self initialize
067b986ee77b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10119
diff changeset
  1013
    "
067b986ee77b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10119
diff changeset
  1014
13592
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  1015
    "Modified: / 18-08-2011 / 13:48:31 / cg"
10121
067b986ee77b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10119
diff changeset
  1016
!
067b986ee77b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10119
diff changeset
  1017
067b986ee77b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10119
diff changeset
  1018
initializeAllProjectDefinitions
067b986ee77b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10119
diff changeset
  1019
    "needs everything else (especially the compiler etc.) to be initialized.
067b986ee77b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10119
diff changeset
  1020
     Therefore, its not invoked by #initialize, but instead explicitely,
067b986ee77b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10119
diff changeset
  1021
     by Smalltalk"
13695
Claus Gittinger <cg@exept.de>
parents: 13694
diff changeset
  1022
13609
b46f07e8e7a3 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13592
diff changeset
  1023
    |isStandAloneApp|
b46f07e8e7a3 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13592
diff changeset
  1024
b46f07e8e7a3 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13592
diff changeset
  1025
    isStandAloneApp := Smalltalk isStandAloneApp.
b46f07e8e7a3 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13592
diff changeset
  1026
b46f07e8e7a3 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13592
diff changeset
  1027
    self allSubclassesDo:[:eachProjectDefinitionClass |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1028
        eachProjectDefinitionClass isAbstract ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1029
            isStandAloneApp ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1030
                eachProjectDefinitionClass installAutoloadedClasses.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1031
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1032
            eachProjectDefinitionClass projectIsLoaded:true.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1033
        ]
13609
b46f07e8e7a3 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13592
diff changeset
  1034
    ].
10115
a43005ac7423 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10114
diff changeset
  1035
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1036
    "
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1037
     self initialize
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1038
    "
10113
78086bf25905 install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents: 10106
diff changeset
  1039
10121
067b986ee77b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10119
diff changeset
  1040
    "Created: / 23-10-2006 / 16:40:53 / cg"
10113
78086bf25905 install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents: 10106
diff changeset
  1041
!
78086bf25905 install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents: 10106
diff changeset
  1042
78086bf25905 install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents: 10106
diff changeset
  1043
installAutoloadedClasses
12372
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1044
    "install all of my autoloaded classes (if any)"
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1045
13610
ec7ea708ebd2 changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13609
diff changeset
  1046
    |classesToFixClassFileName|
ec7ea708ebd2 changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13609
diff changeset
  1047
ec7ea708ebd2 changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13609
diff changeset
  1048
    classesToFixClassFileName := OrderedCollection new.
ec7ea708ebd2 changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13609
diff changeset
  1049
13592
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  1050
    self autoloaded_classNames do:[:className |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1051
        |cls|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1052
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1053
        "/ 'install as autoloaded: ' errorPrint. className errorPrintCR.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1054
        (cls := Smalltalk classNamed:className) isNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1055
            Error handle:[:ex |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1056
                (self name,' [warning]: failed to install autoloaded: ',className) errorPrintCR.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1057
                (self name,' [info]: reason: ',ex description) errorPrintCR.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1058
                "/ thisContext fullPrintAll.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1059
            ] do:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1060
                cls := Smalltalk
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1061
                    installAutoloadedClassNamed:className
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1062
                    category:'* as yet unknown category *'
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1063
                    package:self package
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1064
                    revision:nil
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1065
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1066
            cls notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1067
                classesToFixClassFileName add:cls.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1068
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1069
        ].
13592
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  1070
    ].
10113
78086bf25905 install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents: 10106
diff changeset
  1071
13610
ec7ea708ebd2 changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13609
diff changeset
  1072
    Smalltalk addStartBlock:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1073
        |abbrevs|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1074
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1075
        abbrevs := self abbrevs.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1076
        "/ patch the classFileNames
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1077
        classesToFixClassFileName do:[:cls |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1078
            |entry classFilenameFromAbbreviations|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1079
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1080
            entry := abbrevs at:cls name ifAbsent:nil.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1081
            entry notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1082
                classFilenameFromAbbreviations := entry fileName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1083
                classFilenameFromAbbreviations notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1084
                    classFilenameFromAbbreviations := classFilenameFromAbbreviations,'.st'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1085
                    (classFilenameFromAbbreviations ~= cls getClassFilename) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1086
                        cls setClassFilename:classFilenameFromAbbreviations
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1087
                    ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1088
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1089
            ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1090
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1091
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1092
        "/ patch the categories
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1093
        Class withoutUpdatingChangesDo:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1094
            |entry|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1095
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1096
            self classNames do:[:nm |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1097
                |cls|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1098
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1099
                ((cls := Smalltalk at: nm) notNil
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1100
                        and:[ cls isLoaded not
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1101
                        and:[ (entry := abbrevs at:cls name ifAbsent:[nil]) notNil
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1102
                ]]) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1103
                    cls category: (entry category)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1104
                ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1105
            ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1106
        ]
13610
ec7ea708ebd2 changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13609
diff changeset
  1107
    ].
ec7ea708ebd2 changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13609
diff changeset
  1108
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1109
10113
78086bf25905 install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents: 10106
diff changeset
  1110
    "
78086bf25905 install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents: 10106
diff changeset
  1111
     stx_libbasic installAutoloadedClasses
12268
b3cd2af642f2 changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 12264
diff changeset
  1112
     stx_libhtml installAutoloadedClasses
13592
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  1113
     stx_libtool2 installAutoloadedClasses
10113
78086bf25905 install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents: 10106
diff changeset
  1114
    "
78086bf25905 install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents: 10106
diff changeset
  1115
78086bf25905 install autoloaded classes (if not already present)
Claus Gittinger <cg@exept.de>
parents: 10106
diff changeset
  1116
    "Created: / 23-10-2006 / 16:02:12 / cg"
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1117
    "Modified: / 06-03-2011 / 18:26:58 / Jan Vrany <jan.vrany@fit.cvut.cz>"
13610
ec7ea708ebd2 changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13609
diff changeset
  1118
    "Modified: / 20-08-2011 / 23:32:32 / cg"
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1119
! !
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1120
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1121
!ProjectDefinition class methodsFor:'code generation'!
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1122
11072
deaddd7ad2ed icon filename - no longer automatic default
sr
parents: 11071
diff changeset
  1123
applicationIconFileName_code
deaddd7ad2ed icon filename - no longer automatic default
sr
parents: 11071
diff changeset
  1124
    ^ String streamContents:[:s |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1125
        s nextPutLine:'applicationIconFileName'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1126
        s nextPutLine:'    "Return the name (without suffix) of an icon-file (the app''s icon); will be included in the rc-resource file"'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1127
        s cr;
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1128
        nextPutLine:'    ^ nil';
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1129
        nextPutLine:'    "/ ^ self applicationName'.
11072
deaddd7ad2ed icon filename - no longer automatic default
sr
parents: 11071
diff changeset
  1130
    ].
deaddd7ad2ed icon filename - no longer automatic default
sr
parents: 11071
diff changeset
  1131
deaddd7ad2ed icon filename - no longer automatic default
sr
parents: 11071
diff changeset
  1132
    "
13873
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1133
     self applicationIconFileName_code
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1134
     stx_libbasic3 applicationIconFileName_code
11072
deaddd7ad2ed icon filename - no longer automatic default
sr
parents: 11071
diff changeset
  1135
    "
deaddd7ad2ed icon filename - no longer automatic default
sr
parents: 11071
diff changeset
  1136
deaddd7ad2ed icon filename - no longer automatic default
sr
parents: 11071
diff changeset
  1137
    "Created: / 18-08-2006 / 16:21:01 / cg"
deaddd7ad2ed icon filename - no longer automatic default
sr
parents: 11071
diff changeset
  1138
!
deaddd7ad2ed icon filename - no longer automatic default
sr
parents: 11071
diff changeset
  1139
10393
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1140
classNamesAndAttributes_codeFor:aSpecArray
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1141
    "generate method code returning all classes of the project from the given spec."
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1142
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1143
    ^ String streamContents:[:s |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1144
        s nextPutLine:'classNamesAndAttributes'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1145
        s nextPutLine:'    "lists the classes which are to be included in the project.'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1146
        s nextPutLine:'     Each entry in the list may be: a single class-name (symbol),'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1147
        s nextPutLine:'     or an array-literal consisting of class name and attributes.'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1148
        s nextPutLine:'     Attributes are: #autoload or #<os> where os is one of win32, unix,..."'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1149
        s nextPutLine:''.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1150
        s nextPutLine:'    ^ #('.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1151
        s nextPutLine:'        "<className> or (<className> attributes...) in load order"'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1152
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1153
        (self classNamesAndAttributesFromSpecArray:aSpecArray) do:[:entry |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1154
            s spaces:8.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1155
            entry storeArrayElementOn:s.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1156
            s cr.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1157
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1158
        s nextPutLine:'    )'
10393
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1159
    ].
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1160
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1161
    "
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1162
     stx_libbasic3 classNamesAndAttributes_codeFor:(stx_libbasic3 classNamesAndAttributes)
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1163
     exept_expecco classNamesAndAttributes_codeFor:(exept_expecco classNamesAndAttributes)
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1164
    "
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1165
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1166
    "Modified: / 08-08-2006 / 19:24:34 / fm"
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1167
    "Created: / 19-02-2007 / 15:43:27 / cg"
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1168
!
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1169
10064
fb1ad676019d update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents: 10063
diff changeset
  1170
classNamesAndAttributes_code_ignoreOldEntries:ignoreOldEntries ignoreOldDefinition:ignoreOldDefinition
10010
69b2dbff964b *** empty log message ***
Stefan Vogel <sv@exept.de>
parents: 10007
diff changeset
  1171
    "generate method code returning all classes of the project.
69b2dbff964b *** empty log message ***
Stefan Vogel <sv@exept.de>
parents: 10007
diff changeset
  1172
     Platform attributes are kept from the old definition.
10064
fb1ad676019d update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents: 10063
diff changeset
  1173
     If ignoreOldEntries is true, the list is completely recreated;
fb1ad676019d update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents: 10063
diff changeset
  1174
     if false, existing entries are preserved.
10010
69b2dbff964b *** empty log message ***
Stefan Vogel <sv@exept.de>
parents: 10007
diff changeset
  1175
     If ignoreOldDefinition is true, the autoload attribute is set/reset if
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  1176
     the class is installed as autoloaded in the image (i.e. the state in the image is taken).
10064
fb1ad676019d update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents: 10063
diff changeset
  1177
     If false, it is taken from an existing definition in #classNamesAndAttributes"
10010
69b2dbff964b *** empty log message ***
Stefan Vogel <sv@exept.de>
parents: 10007
diff changeset
  1178
10393
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1179
    |newSpec oldSpec ignored|
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1180
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1181
    oldSpec := self classNamesAndAttributesAsSpecArray.
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1182
    ignored := self ignoredClassNames asSet.
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1183
    newSpec := OrderedCollection new.
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1184
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1185
    ignoreOldEntries ifFalse:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1186
        oldSpec do:[:oldEntry |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1187
            |newEntry className cls |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1188
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1189
            newEntry := oldEntry copy.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1190
            className := newEntry first.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1191
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1192
            (ignored includes:className) ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1193
                cls := Smalltalk classNamed:className.
14354
4a571b9eb43c changed: #classNamesAndAttributes_code_ignoreOldEntries:ignoreOldDefinition:
Stefan Vogel <sv@exept.de>
parents: 14351
diff changeset
  1194
                cls notNil ifTrue:[
4a571b9eb43c changed: #classNamesAndAttributes_code_ignoreOldEntries:ignoreOldDefinition:
Stefan Vogel <sv@exept.de>
parents: 14351
diff changeset
  1195
                    ignoreOldDefinition ifTrue:[
4a571b9eb43c changed: #classNamesAndAttributes_code_ignoreOldEntries:ignoreOldDefinition:
Stefan Vogel <sv@exept.de>
parents: 14351
diff changeset
  1196
                        cls isLoaded ifFalse:[
4a571b9eb43c changed: #classNamesAndAttributes_code_ignoreOldEntries:ignoreOldDefinition:
Stefan Vogel <sv@exept.de>
parents: 14351
diff changeset
  1197
                            (newEntry includes:#autoload) ifFalse:[
4a571b9eb43c changed: #classNamesAndAttributes_code_ignoreOldEntries:ignoreOldDefinition:
Stefan Vogel <sv@exept.de>
parents: 14351
diff changeset
  1198
                                newEntry := newEntry copyWith:#autoload.
4a571b9eb43c changed: #classNamesAndAttributes_code_ignoreOldEntries:ignoreOldDefinition:
Stefan Vogel <sv@exept.de>
parents: 14351
diff changeset
  1199
                            ].
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1200
                        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1201
                    ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1202
                    "JV @ 2010-06-19
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1203
                     Force merge default class attributes with existing ones"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1204
                    newEntry := self mergeDefaultClassAttributesFor: cls with: newEntry.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1205
                    newSpec add:newEntry.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1206
                ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1207
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1208
        ].
10393
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1209
    ].
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1210
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1211
    self searchForClasses do:[:eachClass |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1212
        |className attributes oldSpecEntry oldAttributes newEntry|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1213
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1214
        className := eachClass name.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1215
        (ignored includes:className) ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1216
            oldSpecEntry := oldSpec detect:[:entry | entry first = className] ifNone:nil.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1217
14354
4a571b9eb43c changed: #classNamesAndAttributes_code_ignoreOldEntries:ignoreOldDefinition:
Stefan Vogel <sv@exept.de>
parents: 14351
diff changeset
  1218
            (ignoreOldEntries or:[oldSpecEntry isNil]) ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1219
                (eachClass isLoaded not or:[eachClass isPrivate not]) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1220
                    (self additionalClassNamesAndAttributes includes:className) ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1221
                        (oldSpecEntry size > 1) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1222
                            oldAttributes := oldSpecEntry copyFrom:2.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1223
                        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1224
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1225
                        ignoreOldDefinition ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1226
                            "take autoload attribute from classes state in the image"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1227
                            oldAttributes notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1228
                                attributes := oldAttributes copyWithout:#autoload.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1229
                            ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1230
                                attributes := #()
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1231
                            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1232
                            eachClass isLoaded ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1233
                                attributes := attributes copyWith:#autoload.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1234
                            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1235
                        ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1236
                            "keep any existing attribute"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1237
                            oldAttributes notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1238
                                attributes := oldAttributes.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1239
                            ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1240
                                attributes := eachClass isLoaded ifTrue:[ #() ] ifFalse:[ #(autoload) ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1241
                            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1242
                        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1243
                        "JV @ 2010-06-19
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1244
                         Support fo additional class attributes and programming language attribute"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1245
                        attributes := self mergeDefaultClassAttributesFor: eachClass with: attributes.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1246
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1247
                        newEntry := Array with:className.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1248
                        attributes notEmptyOrNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1249
                            newEntry := newEntry , attributes.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1250
                        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1251
                        newSpec add:newEntry
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1252
                    ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1253
                ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1254
            ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1255
        ]
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1256
    ].
10393
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1257
    ^ self classNamesAndAttributes_codeFor:newSpec
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1258
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  1259
    "
10393
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1260
     stx_libbasic3 classNamesAndAttributes_code_ignoreOldEntries:false ignoreOldDefinition:true
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1261
     exept_expecco classNamesAndAttributes_code_ignoreOldEntries:false ignoreOldDefinition:true
68b206e1af51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10380
diff changeset
  1262
    "
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1263
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1264
    "Modified: / 08-08-2006 / 19:24:34 / fm"
10064
fb1ad676019d update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents: 10063
diff changeset
  1265
    "Created: / 10-10-2006 / 22:00:50 / cg"
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1266
    "Modified: / 19-06-2010 / 10:56:46 / Jan Vrany <jan.vrany@fit.cvut.cz>"
13635
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  1267
    "Modified: / 06-09-2011 / 07:48:52 / cg"
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1268
!
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1269
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1270
companyName_code
12541
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1271
    ^ self companyName_codeFor:self companyName
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1272
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1273
    "
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1274
     self companyName_code
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1275
     stx_libbasic3 companyName_code
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1276
    "
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1277
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1278
    "Created: / 18-08-2006 / 16:20:42 / cg"
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1279
!
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1280
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1281
companyName_codeFor:aString
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1282
    ^ String streamContents:[:s |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1283
        s nextPutLine:'companyName'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1284
        s nextPutLine:'    "Return a companyname which will appear in <lib>.rc"'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1285
        s cr; nextPutLine:'    ^ ',aString storeString.
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1286
    ].
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1287
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1288
    "
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1289
     self companyName_code
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1290
     stx_libbasic3 companyName_code
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1291
    "
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1292
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1293
    "Created: / 18-08-2006 / 16:20:42 / cg"
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1294
!
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1295
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1296
compileDescriptionMethods
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1297
    (self isLibraryDefinition
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1298
    or:[ self isApplicationDefinition ] ) ifFalse:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1299
        self error:'I am abstract - must be a subclass of Libray- or ApplicationDefinition.'
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1300
    ].
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1301
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  1302
    self
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1303
        forEachMethodsCodeToCompileDo:[:code :category |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1304
            self compile:code categorized:category
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1305
        ].
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1306
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1307
"/    self instAndClassMethodsDo:[:m | m package:self package].
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1308
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1309
    "
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1310
     DapasXProject compileDescriptionMethods
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1311
     DapasX_Datenbasis compileDescriptionMethods
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1312
     bosch_dapasx_interactiver_editor compileDescriptionMethods
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1313
     stx_libbasic compileDescriptionMethods
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1314
    "
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1315
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1316
    "Created: / 09-08-2006 / 18:00:31 / fm"
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1317
    "Modified: / 05-09-2006 / 13:46:29 / cg"
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1318
!
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1319
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1320
description_code
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1321
    ^ String streamContents:[:s |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1322
        s nextPutLine:'description'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1323
        s nextPutLine:'    "Return a description string which will appear in vc.def / bc.def"'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1324
        s cr; nextPutLine:'    ^ ',self description asString storeString.
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1325
    ].
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1326
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1327
    "
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  1328
     self description_code
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  1329
     stx_libbasic3 description_code
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1330
    "
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1331
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1332
    "Created: / 17-08-2006 / 21:24:01 / cg"
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1333
    "Modified: / 18-08-2006 / 16:16:24 / cg"
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1334
!
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1335
11386
5e4e1acf7242 Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents: 11383
diff changeset
  1336
effectiveSubProjects
5e4e1acf7242 Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents: 11383
diff changeset
  1337
    "get the subProjects, that are not excluded"
5e4e1acf7242 Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents: 11383
diff changeset
  1338
5e4e1acf7242 Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents: 11383
diff changeset
  1339
    |subProjects|
5e4e1acf7242 Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents: 11383
diff changeset
  1340
5e4e1acf7242 Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents: 11383
diff changeset
  1341
    subProjects := self subProjects asSet.
5e4e1acf7242 Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents: 11383
diff changeset
  1342
    subProjects removeAllFoundIn:self excludedFromSubProjects.
5e4e1acf7242 Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents: 11383
diff changeset
  1343
    subProjects remove:self package ifAbsent:[].
5e4e1acf7242 Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents: 11383
diff changeset
  1344
5e4e1acf7242 Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents: 11383
diff changeset
  1345
    ^ subProjects
5e4e1acf7242 Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents: 11383
diff changeset
  1346
!
5e4e1acf7242 Fix #allPrerequisites to return prerequisites that are
Stefan Vogel <sv@exept.de>
parents: 11383
diff changeset
  1347
12425
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  1348
excludedFromPreRequisites_code
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  1349
    "generate the code of the #excludedFromPreRequisites method"
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  1350
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  1351
    ^ String streamContents:[:s |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1352
        s nextPutLine:'excludedFromPreRequisites'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1353
        s nextPutLine:'    "list all packages which should be ignored in the automatic'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1354
        s nextPutLine:'     preRequisites scan. See #preRequisites for more."'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1355
        s nextPutLine:''.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1356
        s nextPutLine:'    ^ #('.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1357
        s nextPutLine:'    )'
12425
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  1358
    ].
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  1359
!
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  1360
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1361
extensionMethodNames_code
10064
fb1ad676019d update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents: 10063
diff changeset
  1362
    ^ self extensionMethodNames_code_ignoreOldEntries:true
fb1ad676019d update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents: 10063
diff changeset
  1363
fb1ad676019d update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents: 10063
diff changeset
  1364
    "
fb1ad676019d update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents: 10063
diff changeset
  1365
     self extensionMethodNames_code
fb1ad676019d update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents: 10063
diff changeset
  1366
    "
fb1ad676019d update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents: 10063
diff changeset
  1367
fb1ad676019d update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents: 10063
diff changeset
  1368
    "Created: / 17-08-2006 / 21:21:48 / cg"
fb1ad676019d update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents: 10063
diff changeset
  1369
    "Modified: / 10-10-2006 / 22:02:42 / cg"
fb1ad676019d update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents: 10063
diff changeset
  1370
!
fb1ad676019d update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents: 10063
diff changeset
  1371
fb1ad676019d update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents: 10063
diff changeset
  1372
extensionMethodNames_code_ignoreOldEntries:ignoreOldEntries
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1373
    ^ String streamContents:[:s |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1374
        |oldSpec|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1375
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1376
        s nextPutLine:'extensionMethodNames'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1377
        s nextPutLine:'    "lists the extension methods which are to be included in the project.'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1378
        s nextPutLine:'     Entries are 2-element array literals, consisting of class-name and selector."'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1379
        s nextPutLine:''.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1380
        s nextPutLine:'    ^ #('.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1381
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1382
        oldSpec := self extensionMethodNames pairWiseCollect:[:className :selector | className -> selector ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1383
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1384
        ignoreOldEntries ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1385
            oldSpec do:[:entry |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1386
                |mclassName mselector|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1387
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1388
                mclassName := entry key asSymbol.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1389
                (mclassName endsWith:' class') ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1390
                    mclassName := mclassName asString.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1391
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1392
                mselector := entry value asSymbol.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1393
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1394
                s spaces:8.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1395
                mclassName storeArrayElementOn:s.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1396
                s space.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1397
                mselector storeArrayElementOn:s.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1398
                s cr.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1399
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1400
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1401
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1402
        self searchForExtensions do:[:eachMethod |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1403
            |attributes oldSpecEntry mclassName mselector|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1404
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1405
            mclassName := eachMethod mclass name.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1406
            mselector := eachMethod selector.
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1407
            "JV@2012-09-07: Do not list Java methods in extensionMethodNames.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1408
             They are loaded lazily by JavaClassReader and if listed here,
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1409
             they would cause an error if the package is loaded from source.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1410
             Sort of a HACK, indeed"
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1411
            eachMethod mclass theNonMetaclass isJavaClass ifFalse:[
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1412
                oldSpecEntry := oldSpec detect:[:entry | entry key = mclassName and:[ entry value = mselector]] ifNone:nil.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1413
                (ignoreOldEntries or:[ oldSpecEntry isNil]) ifTrue:[
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1414
                    s spaces:8.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1415
                    mclassName storeArrayElementOn:s.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1416
                    s space.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1417
                    mselector storeArrayElementOn:s.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1418
                    s cr.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1419
                ]
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1420
            ].
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1421
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1422
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1423
        s nextPutLine:'    )'
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1424
    ].
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1425
10106
c26879b72dfe extensionlist generator was buggy
Claus Gittinger <cg@exept.de>
parents: 10104
diff changeset
  1426
    "
c26879b72dfe extensionlist generator was buggy
Claus Gittinger <cg@exept.de>
parents: 10104
diff changeset
  1427
     self extensionMethodNames_code_ignoreOldEntries:false
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1428
     stx_libjava extensionMethodNames_code_ignoreOldEntries:false
10106
c26879b72dfe extensionlist generator was buggy
Claus Gittinger <cg@exept.de>
parents: 10104
diff changeset
  1429
     stx_libtool extensionMethodNames_code_ignoreOldEntries:true
c26879b72dfe extensionlist generator was buggy
Claus Gittinger <cg@exept.de>
parents: 10104
diff changeset
  1430
    "
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1431
10064
fb1ad676019d update spec vs. regenerate spec.
Claus Gittinger <cg@exept.de>
parents: 10063
diff changeset
  1432
    "Created: / 10-10-2006 / 22:02:36 / cg"
10106
c26879b72dfe extensionlist generator was buggy
Claus Gittinger <cg@exept.de>
parents: 10104
diff changeset
  1433
    "Modified: / 23-10-2006 / 11:07:29 / cg"
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1434
    "Modified: / 18-11-2012 / 19:41:33 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1435
!
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1436
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1437
forEachContentsMethodsCodeToCompileDo:aTwoArgBlock ignoreOldDefinition:ignoreOldDefinition
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  1438
    aTwoArgBlock
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1439
        value:(self classNamesAndAttributes_code_ignoreOldEntries:ignoreOldDefinition ignoreOldDefinition:ignoreOldDefinition)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1440
        value:'description - contents'.
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  1441
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  1442
    aTwoArgBlock
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1443
        value: (self extensionMethodNames_code_ignoreOldEntries:ignoreOldDefinition)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1444
        value: 'description - contents'.
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  1445
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  1446
    aTwoArgBlock
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1447
        value: self mandatoryPreRequisites_code
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1448
        value: 'description'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1449
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1450
    aTwoArgBlock
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1451
        value: self referencedPreRequisites_code
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1452
        value: 'description'.
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  1453
14812
bdbf34a42482 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14809
diff changeset
  1454
    ((self class includesSelector:#excludedFromPreRequisites) not or:[ignoreOldDefinition]) ifTrue:[
bdbf34a42482 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14809
diff changeset
  1455
        aTwoArgBlock
bdbf34a42482 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14809
diff changeset
  1456
            value: self excludedFromPreRequisites_code
bdbf34a42482 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14809
diff changeset
  1457
            value: 'description'.
bdbf34a42482 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14809
diff changeset
  1458
    ].
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1459
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1460
    (self monticelloPackageName notNil and:[self respondsTo:#monticelloTimestamps_code]) ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1461
        aTwoArgBlock
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1462
            value: self monticelloTimestamps_code
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1463
            value: 'description - monticello'.
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1464
    ].
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1465
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1466
    "Modified: / 09-11-2010 / 18:41:07 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1467
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1468
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1469
forEachMethodsCodeToCompileDo:aTwoArgBlock
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1470
    self forEachMethodsCodeToCompileDo:aTwoArgBlock ignoreOldDefinition:false
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1471
!
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1472
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1473
forEachMethodsCodeToCompileDo:aTwoArgBlock ignoreOldDefinition:ignoreOldDefinition
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  1474
    self
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1475
        forEachContentsMethodsCodeToCompileDo:aTwoArgBlock
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1476
        ignoreOldDefinition:ignoreOldDefinition.
10013
c6cd8f035693 pretty format of generated methods
Stefan Vogel <sv@exept.de>
parents: 10011
diff changeset
  1477
13873
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1478
    "/  code like:
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1479
    "/
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1480
    "/ (self class includesSelector:#productName) ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1481
    "/     aTwoArgBlock
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1482
    "/         value: self productName_code
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1483
    "/         value: 'description - project information'.
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1484
    "/ ].
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1485
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1486
    #(
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1487
        (productName productName_code)
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1488
        (description description_code)
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1489
        (companyName companyName_code)
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1490
        (legalCopyright legalCopyright_code)
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1491
        (applicationIconFileName applicationIconFileName_code)
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1492
        (productInstallDirBaseName productInstallDirBaseName_code)
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1493
    ) pairsDo:[:selector :codeMethodSelector |
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1494
        (self class includesSelector:selector) ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1495
            aTwoArgBlock
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1496
                value: (self perform:codeMethodSelector)
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1497
                value: 'description - project information'.
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1498
        ].
11072
deaddd7ad2ed icon filename - no longer automatic default
sr
parents: 11071
diff changeset
  1499
    ].
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1500
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1501
    (self monticelloPackageName notNil and:[self respondsTo:#monticelloTimestamps_code]) ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1502
        aTwoArgBlock
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1503
            value: self monticelloTimestamps_code
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1504
            value: 'description - monticello'.
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1505
    ].
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1506
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1507
    "Created: / 18-08-2006 / 16:22:37 / cg"
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1508
    "Modified: / 09-11-2010 / 18:41:15 / Jan Vrany <jan.vrany@fit.cvut.cz>"
13873
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1509
    "Modified: / 21-12-2011 / 16:42:41 / cg"
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1510
!
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1511
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1512
legalCopyright_code
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1513
    ^ String streamContents:[:s |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1514
        s nextPutLine:'legalCopyright'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1515
        s nextPutLine:'    "Return a copyright string which will appear in <lib>.rc"'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1516
        s cr; nextPutLine:'    ^ ', self legalCopyright storeString.
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1517
    ].
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1518
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1519
    "
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  1520
     self legalCopyright_code
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  1521
     stx_libbasic3 legalCopyright_code
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1522
    "
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1523
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1524
    "Created: / 18-08-2006 / 16:21:01 / cg"
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1525
!
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1526
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1527
mandatoryPreRequisites_code
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1528
    "generate the code of the #mandatoryPreRequisites method"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1529
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1530
    |preRequisites|
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1531
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1532
    preRequisites := self searchForPreRequisites first.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1533
    preRequisites removeAllKeys:self excludedFromPreRequisites ifAbsent:[].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1534
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1535
    ^ String streamContents:[:s |
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1536
        s nextPutLine:'mandatoryPreRequisites'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1537
        s nextPutLine:'    "list all required mandatory packages.'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1538
        s nextPutLine:'     Packages are mandatory, if they contain superclasses of the package''s classes'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1539
        s nextPutLine:'     or classes which are extended by this package.'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1540
        s nextPutLine:'     This list can be maintained manually or (better) generated and'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1541
        s nextPutLine:'     updated by scanning the superclass hierarchies'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1542
        s nextPutLine:'     (the browser has a menu function for that)'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1543
        s nextPutLine:'     However, often too much is found, and you may want to explicitely'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1544
        s nextPutLine:'     exclude individual packages in the #excludedFromPreRequisites method."'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1545
        s nextPutLine:''.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1546
        s nextPutLine:'    ^ #('.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1547
        preRequisites keys asSortedCollection do:[:eachPackageID |
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1548
            |reason|
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1549
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1550
            s spaces:8.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1551
            eachPackageID asSymbol storeOn:s.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1552
            reason := preRequisites at:eachPackageID ifAbsent:nil.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1553
            reason notEmptyOrNil ifTrue:[
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1554
                s nextPutAll:'    "'; nextPutAll:reason anElement; nextPutAll:' "'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1555
            ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1556
            s cr.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1557
        ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1558
        s nextPutLine:'    )'
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1559
    ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1560
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1561
    "
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1562
     demo_demoApp1 mandatoryPreRequisites_code
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1563
     stx_libbasic3 mandatoryPreRequisites_code
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1564
     stx_libtool2 mandatoryPreRequisites_code
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1565
    "
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1566
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1567
    "Modified: / 08-08-2006 / 19:24:34 / fm"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1568
    "Created: / 17-08-2006 / 21:28:09 / cg"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1569
    "Modified: / 09-10-2006 / 14:27:20 / cg"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1570
!
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1571
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1572
preRequisites_code
10574
b77b673bc36c Better reason comments in #preRequisites packages
Stefan Vogel <sv@exept.de>
parents: 10570
diff changeset
  1573
    "generate the code of the #preRequisites method"
b77b673bc36c Better reason comments in #preRequisites packages
Stefan Vogel <sv@exept.de>
parents: 10570
diff changeset
  1574
b77b673bc36c Better reason comments in #preRequisites packages
Stefan Vogel <sv@exept.de>
parents: 10570
diff changeset
  1575
    |preRequisites searchedPreRequisites importantReason|
b77b673bc36c Better reason comments in #preRequisites packages
Stefan Vogel <sv@exept.de>
parents: 10570
diff changeset
  1576
10179
cb4bc76044d0 *** empty log message ***
fm
parents: 10163
diff changeset
  1577
    searchedPreRequisites := self searchForPreRequisites.
14816
545edcfa21e0 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14815
diff changeset
  1578
    preRequisites := Set new
545edcfa21e0 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14815
diff changeset
  1579
        addAll: searchedPreRequisites keys;
545edcfa21e0 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14815
diff changeset
  1580
        removeAllFoundIn:self excludedFromPreRequisites;
14817
c166d17242cc class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14816
diff changeset
  1581
        remove:self package ifAbsent:[];
c166d17242cc class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14816
diff changeset
  1582
        yourself.
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1583
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1584
    ^ String streamContents:[:s |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1585
        s nextPutLine:'preRequisites'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1586
        s nextPutLine:'    "list all required packages.'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1587
        s nextPutLine:'     This list can be maintained manually or (better) generated and'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1588
        s nextPutLine:'     updated by scanning the superclass hierarchies and looking for'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1589
        s nextPutLine:'     global variable accesses. (the browser has a menu function for that)'.
14813
0d82556f56b5 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14812
diff changeset
  1590
        s nextPutLine:'     However, often too much is found, and you may want to explicitely'.
0d82556f56b5 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14812
diff changeset
  1591
        s nextPutLine:'     exclude individual packages in the #excludedFromPreRequisites method.'.
0d82556f56b5 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14812
diff changeset
  1592
        s nextPutLine:'     If you have explicit preqrequisites, define them in the #includedInPreRequisites method."'.
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1593
        s nextPutLine:''.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1594
        s nextPutLine:'    ^ #('.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1595
        preRequisites asSortedCollection do:[:eachPackageID |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1596
            |reason|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1597
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1598
            s spaces:8.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1599
            eachPackageID asSymbol storeOn:s.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1600
            reason := searchedPreRequisites at:eachPackageID ifAbsent:nil.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1601
            reason notEmptyOrNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1602
                "superclasses are really important"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1603
                importantReason := reason detect:[:eachReasonString|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1604
                    eachReasonString includesString:' superclass '
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1605
                ] ifNone:[reason anElement].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1606
                s nextPutAll:'    "'; nextPutAll:importantReason; nextPutAll:' "'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1607
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1608
            s cr.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1609
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1610
        s nextPutLine:'    )'
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1611
    ].
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1612
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1613
    "
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1614
     bosch_dapasx_application preRequisites_code
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1615
     demo_demoApp1 preRequisites_code
10574
b77b673bc36c Better reason comments in #preRequisites packages
Stefan Vogel <sv@exept.de>
parents: 10570
diff changeset
  1616
     stx_libbasic3 preRequisites_code
10013
c6cd8f035693 pretty format of generated methods
Stefan Vogel <sv@exept.de>
parents: 10011
diff changeset
  1617
     stx_libtool2 preRequisites_code
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1618
    "
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1619
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1620
    "Modified: / 08-08-2006 / 19:24:34 / fm"
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1621
    "Created: / 17-08-2006 / 21:28:09 / cg"
10063
580a7b4b4b81 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10058
diff changeset
  1622
    "Modified: / 09-10-2006 / 14:27:20 / cg"
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1623
!
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1624
13873
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1625
productInstallDirBaseName_code
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1626
    ^ String streamContents:[:s |
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1627
        s nextPutLine:'productInstallDirBaseName'.
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1628
        s nextPutLine:'    "Returns a default installDir which will appear in <app>.nsi.'.
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1629
        s nextPutLine:'     This is usually not the one you want to keep"'.
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1630
        s cr;
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1631
        nextPutLine:'    ^ (self package asCollectionOfSubstringsSeparatedByAny:'':/'') last'.
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1632
    ].
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1633
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1634
    "
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1635
     self productInstallDirBaseName_code
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1636
     stx_libbasic3 productInstallDirBaseName_code
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1637
     stx_clients_Clock_QlockTwoWatchApplication productInstallDirBaseName_code
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1638
    "
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1639
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1640
    "Created: / 21-12-2011 / 16:38:11 / cg"
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1641
!
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  1642
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1643
productName_code
12541
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1644
    ^ self productName_codeFor:(self productName)
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1645
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1646
    "
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1647
     self productName_code
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1648
     stx_libbasic3 productName_code
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1649
    "
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1650
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1651
    "Created: / 18-08-2006 / 16:14:19 / cg"
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1652
!
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1653
Claus Gittinger <cg@exept.de>
parents: 12526
diff changeset
  1654
productName_codeFor:aString
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1655
    ^ String streamContents:[:s |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1656
        s nextPutLine:'productName'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1657
        s nextPutLine:'    "Return a product name which will appear in <lib>.rc"'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1658
        s cr; nextPutLine:'    ^ ',aString storeString.
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1659
    ].
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1660
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1661
    "
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1662
     self productName_code
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1663
     stx_libbasic3 productName_code
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1664
    "
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1665
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1666
    "Created: / 18-08-2006 / 16:14:19 / cg"
12028
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  1667
!
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  1668
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1669
referencedPreRequisites_code
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1670
    "generate the code of the #referencedPreRequisites method"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1671
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1672
    |preRequisitesColl preRequisites|
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1673
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1674
    preRequisitesColl := self searchForPreRequisites.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1675
    preRequisites := self searchForPreRequisites second.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1676
    preRequisites 
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1677
        removeAllKeys:self excludedFromPreRequisites ifAbsent:[];
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1678
        removeAllKeys:preRequisitesColl first keys ifAbsent:[].  "remove the mandatory prerequisites"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1679
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1680
    ^ String streamContents:[:s |
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1681
        s nextPutLine:'referencedPreRequisites'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1682
        s nextPutLine:'    "list all packages containing classes referenced by the packages''s members.'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1683
        s nextPutLine:'     This list can be maintained manually or (better) generated and'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1684
        s nextPutLine:'     updated by looking for global variable accesses'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1685
        s nextPutLine:'     (the browser has a menu function for that)'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1686
        s nextPutLine:'     However, often too much is found, and you may want to explicitely'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1687
        s nextPutLine:'     exclude individual packages in the #excludedFromPreRequisites method."'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1688
        s nextPutLine:''.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1689
        s nextPutLine:'    ^ #('.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1690
        preRequisites keys asSortedCollection do:[:eachPackageID |
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1691
            |reason|
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1692
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1693
            s spaces:8.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1694
            eachPackageID asSymbol storeOn:s.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1695
            reason := preRequisites at:eachPackageID ifAbsent:nil.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1696
            reason notEmptyOrNil ifTrue:[
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1697
                s nextPutAll:'    "'; nextPutAll:reason anElement; nextPutAll:' "'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1698
            ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1699
            s cr.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1700
        ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1701
        s nextPutLine:'    )'
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1702
    ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1703
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1704
    "
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1705
     demo_demoApp1 referencedPreRequisites_code
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1706
     stx_libbasic3 referencedPreRequisites_code
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1707
     stx_libtool2 referencedPreRequisites_code
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1708
    "
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1709
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1710
    "Modified: / 08-08-2006 / 19:24:34 / fm"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1711
    "Created: / 17-08-2006 / 21:28:09 / cg"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1712
    "Modified: / 09-10-2006 / 14:27:20 / cg"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1713
!
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1714
12028
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  1715
svnRevisionNr_code: revisionNrOrNil
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  1716
    ^ String streamContents:[:s |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1717
        s nextPutLine:'svnRevisionNr'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1718
        s nextPutLine:'    "Return a SVN revision number of myself.'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1719
        s nextPutLine:'     This number is updated after a commit"'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1720
        s cr;
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1721
        nextPutLine:'    ^ "$SVN-Revision:"''', ('%-16s' printf: (Array with: revisionNrOrNil printString)) , '''"$"'.
12028
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  1722
    ].
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  1723
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  1724
    "
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  1725
     self svnRevisionNr_code
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  1726
     stx_libbasic3 svnRevisionNr_code
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  1727
    "
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  1728
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  1729
    "Created: / 16-06-2009 / 12:12:37 / Jan Vrany <vranyj1@fel.cvut.cz>"
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  1730
    "Modified: / 22-08-2009 / 09:05:05 / Jan Vrany <vranyj1@fel.cvut.cz>"
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1731
    "Modified: / 29-03-2012 / 18:43:18 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9998
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1732
! !
49e54dc8ecc0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9996
diff changeset
  1733
9569
b0bf179c9bf5 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9559
diff changeset
  1734
!ProjectDefinition class methodsFor:'defaults'!
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  1735
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  1736
applicationTypes
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1737
    GUIApplicationType isNil ifTrue:[self initialize].
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1738
    ^ Array with:GUIApplicationType with:NonGUIApplicationType
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  1739
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1740
    "
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  1741
     self applicationTypes
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1742
    "
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  1743
!
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  1744
10434
25f76184bf81 project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents: 10433
diff changeset
  1745
defaultCategory
10466
aa61cdb54299 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10434
diff changeset
  1746
    ^'* Projects & Packages *'
10434
25f76184bf81 project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents: 10433
diff changeset
  1747
25f76184bf81 project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents: 10433
diff changeset
  1748
    "Created: / 11-08-2006 / 14:16:49 / cg"
25f76184bf81 project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents: 10433
diff changeset
  1749
!
25f76184bf81 project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents: 10433
diff changeset
  1750
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1751
defaultProjectType
9745
82c6afc86a68 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9733
diff changeset
  1752
    ^ self libraryTypes first
82c6afc86a68 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9733
diff changeset
  1753
    "/ ^ self applicationTypes first
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1754
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1755
    "Created: / 23-08-2006 / 14:27:32 / cg"
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1756
!
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1757
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1758
defaultProjectTypeForGUIApplication
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1759
    ^ GUIApplicationType
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1760
!
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1761
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1762
defaultProjectTypeForNonGUIApplication
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1763
    ^ NonGUIApplicationType
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1764
!
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  1765
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1766
guiApplicationType
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1767
    ^ GUIApplicationType
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1768
!
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1769
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1770
libraryType
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1771
    ^ LibraryType
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1772
!
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1773
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  1774
libraryTypes
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1775
    LibraryType isNil ifTrue:[self initialize].
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1776
    ^ Array with:LibraryType
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1777
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1778
    "
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  1779
     self libraryTypes
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1780
    "
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1781
!
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1782
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1783
nonGuiApplicationType
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  1784
    ^ NonGUIApplicationType
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  1785
!
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  1786
12331
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1787
projectTypeSelectors
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1788
    "a list of possible project type selectors"
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1789
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1790
    ^ #( libraryType guiApplicationType nonGuiApplicationType )
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1791
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1792
    "
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1793
     self libraryType
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1794
     self guiApplicationType
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1795
     self nonGuiApplicationType
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1796
    "
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1797
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1798
    "Created: / 23-08-2006 / 14:27:32 / cg"
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1799
!
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1800
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  1801
projectTypes
12331
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1802
    "a list of possible project types"
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1803
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  1804
    ^ self libraryTypes , self applicationTypes
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  1805
12331
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1806
    "
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1807
     self projectTypes
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1808
    "
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  1809
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  1810
    "Created: / 23-08-2006 / 14:27:32 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  1811
! !
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  1812
9569
b0bf179c9bf5 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9559
diff changeset
  1813
!ProjectDefinition class methodsFor:'description'!
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  1814
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  1815
excludedFromPreRequisites
9983
f128c0a46573 preRequisite generation
Claus Gittinger <cg@exept.de>
parents: 9979
diff changeset
  1816
    "list packages which are to be explicitely excluded from the automatic constructed
f128c0a46573 preRequisite generation
Claus Gittinger <cg@exept.de>
parents: 9979
diff changeset
  1817
     prerequisites list. If empty, everything that is found along the inheritance of any of
f128c0a46573 preRequisite generation
Claus Gittinger <cg@exept.de>
parents: 9979
diff changeset
  1818
     my classes is considered to be a prerequisite package."
f128c0a46573 preRequisite generation
Claus Gittinger <cg@exept.de>
parents: 9979
diff changeset
  1819
f128c0a46573 preRequisite generation
Claus Gittinger <cg@exept.de>
parents: 9979
diff changeset
  1820
    ^ #()
f128c0a46573 preRequisite generation
Claus Gittinger <cg@exept.de>
parents: 9979
diff changeset
  1821
f128c0a46573 preRequisite generation
Claus Gittinger <cg@exept.de>
parents: 9979
diff changeset
  1822
    "Modified: / 17-08-2006 / 19:48:59 / cg"
f128c0a46573 preRequisite generation
Claus Gittinger <cg@exept.de>
parents: 9979
diff changeset
  1823
!
f128c0a46573 preRequisite generation
Claus Gittinger <cg@exept.de>
parents: 9979
diff changeset
  1824
10380
ff1cfee6130b Fix subproject incluseion in Make.proto
Stefan Vogel <sv@exept.de>
parents: 10369
diff changeset
  1825
excludedFromSubProjects
ff1cfee6130b Fix subproject incluseion in Make.proto
Stefan Vogel <sv@exept.de>
parents: 10369
diff changeset
  1826
    "list packages which are to be explicitely excluded from the automatic constructed
ff1cfee6130b Fix subproject incluseion in Make.proto
Stefan Vogel <sv@exept.de>
parents: 10369
diff changeset
  1827
     subProjects list. If empty, every sub-package is included as a prerequisite."
ff1cfee6130b Fix subproject incluseion in Make.proto
Stefan Vogel <sv@exept.de>
parents: 10369
diff changeset
  1828
ff1cfee6130b Fix subproject incluseion in Make.proto
Stefan Vogel <sv@exept.de>
parents: 10369
diff changeset
  1829
    ^ #()
ff1cfee6130b Fix subproject incluseion in Make.proto
Stefan Vogel <sv@exept.de>
parents: 10369
diff changeset
  1830
ff1cfee6130b Fix subproject incluseion in Make.proto
Stefan Vogel <sv@exept.de>
parents: 10369
diff changeset
  1831
    "Modified: / 17-08-2006 / 19:49:40 / cg"
10039
0270d37a36c8 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10034
diff changeset
  1832
!
0270d37a36c8 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10034
diff changeset
  1833
14808
9b6499b3ca93 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14790
diff changeset
  1834
includedInPreRequisites
9b6499b3ca93 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14790
diff changeset
  1835
    "list packages which are to be explicitely included in the prerequisites list,
9b6499b3ca93 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14790
diff changeset
  1836
     even if not found by the automatic search.
9b6499b3ca93 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14790
diff changeset
  1837
     Redefine this, if classes from other packages are referred to via reflection
9b6499b3ca93 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14790
diff changeset
  1838
     or by constructing names dynamically (i.e. the search cannot find it)"
9b6499b3ca93 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14790
diff changeset
  1839
9b6499b3ca93 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14790
diff changeset
  1840
    ^ #()
9b6499b3ca93 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14790
diff changeset
  1841
!
9b6499b3ca93 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14790
diff changeset
  1842
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1843
mandatoryPreRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1844
    "list packages which are mandatory as a prerequisite.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1845
     This are packages containing superclasses of my classes and classes which
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1846
     are extended by myself.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1847
     They are mandatory, beacuse we need these packages as a prerequisite for loading and compiling.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1848
     This method is generated automatically,
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1849
     by searching along the inheritance chain of all of my classes."
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1850
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1851
    ^ #()
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1852
!
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1853
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1854
preRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1855
    "list packages which are required as a prerequisite."
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1856
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1857
    "use an OrderedSet here, so that mandatory prerequisites come first"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1858
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1859
    ^ OrderedSet new
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1860
        addAll:self mandatoryPreRequisites;
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1861
        addAll:self referencedPreRequisites;
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1862
        addAll:self includedInPreRequisites;
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1863
        removeAllFoundIn:self excludedFromPreRequisites;
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1864
        yourself.
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1865
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1866
    "Modified: / 17-08-2006 / 19:54:21 / cg"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1867
!
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1868
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1869
preRequisitesFor:packageId 
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1870
    |def|
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1871
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1872
    def := self definitionClassForPackage:packageId.
13820
f46f7306eea2 changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents: 13809
diff changeset
  1873
    def isNil ifTrue:[
f46f7306eea2 changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents: 13809
diff changeset
  1874
        "Maybe the package is not loaded? Try to load it..."
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1875
        (Smalltalk loadPackage:packageId) ifTrue:[
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1876
            def := self definitionClassForPackage:packageId
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1877
        ]
13820
f46f7306eea2 changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents: 13809
diff changeset
  1878
    ].
f46f7306eea2 changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents: 13809
diff changeset
  1879
    ^ def isNil 
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1880
        ifTrue:[
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1881
            "Still no project definition - maybe it does not exist?"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1882
            Transcript showCR:'Warning: no definition class for package: ', packageId.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1883
            (ProjectDefinition searchForPreRequisites:packageId) keys
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1884
        ]
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1885
        ifFalse:[ def effectivePreRequisites ]
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1886
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1887
    "Created: / 24-02-2011 / 22:47:41 / Jan Vrany <jan.vrany@fit.cvut.cz>"
13820
f46f7306eea2 changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents: 13809
diff changeset
  1888
    "Modified: / 18-11-2011 / 14:52:43 / cg"
f46f7306eea2 changed: #preRequisitesFor:
Claus Gittinger <cg@exept.de>
parents: 13809
diff changeset
  1889
    "Modified (format): / 19-11-2011 / 11:25:36 / cg"
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1890
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  1891
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1892
referencedPreRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1893
    "list packages which are a prerequisite, because the contain
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1894
     classes which are referenced by my classes.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1895
     We do not need these packages as a prerequisite for loading or compiling.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1896
     This method is generated automatically,
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1897
     by searching along the inheritance chain of all of my classes."
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1898
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  1899
    ^ #()
12186
Claus Gittinger <cg@exept.de>
parents: 12143
diff changeset
  1900
!
Claus Gittinger <cg@exept.de>
parents: 12143
diff changeset
  1901
9685
e6a533e0a5e5 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9683
diff changeset
  1902
siblingsAreSubProjects
e6a533e0a5e5 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9683
diff changeset
  1903
    ^ false
e6a533e0a5e5 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9683
diff changeset
  1904
!
e6a533e0a5e5 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9683
diff changeset
  1905
11377
35d261aa5493 splash file definition
Claus Gittinger <cg@exept.de>
parents: 11369
diff changeset
  1906
splashFileName
35d261aa5493 splash file definition
Claus Gittinger <cg@exept.de>
parents: 11369
diff changeset
  1907
    "answer the base-name of the splash bitmap.
35d261aa5493 splash file definition
Claus Gittinger <cg@exept.de>
parents: 11369
diff changeset
  1908
35d261aa5493 splash file definition
Claus Gittinger <cg@exept.de>
parents: 11369
diff changeset
  1909
     Default is nil, for no splash. If non-nil, it must be a bmp file's name"
35d261aa5493 splash file definition
Claus Gittinger <cg@exept.de>
parents: 11369
diff changeset
  1910
35d261aa5493 splash file definition
Claus Gittinger <cg@exept.de>
parents: 11369
diff changeset
  1911
    ^ nil.
35d261aa5493 splash file definition
Claus Gittinger <cg@exept.de>
parents: 11369
diff changeset
  1912
!
35d261aa5493 splash file definition
Claus Gittinger <cg@exept.de>
parents: 11369
diff changeset
  1913
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1914
subProjects
12748
0092049ca4d1 changed:
Claus Gittinger <cg@exept.de>
parents: 12743
diff changeset
  1915
    <resource: #obsolete>
0092049ca4d1 changed:
Claus Gittinger <cg@exept.de>
parents: 12743
diff changeset
  1916
0092049ca4d1 changed:
Claus Gittinger <cg@exept.de>
parents: 12743
diff changeset
  1917
    "OBSOLETE.
0092049ca4d1 changed:
Claus Gittinger <cg@exept.de>
parents: 12743
diff changeset
  1918
     list packages which are known as subprojects. This method is generated automatically.
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1919
     However, when generating automatically, packages are only added - never removed, unless listed
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1920
     in excludedFromSubProjects."
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1921
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1922
    ^ #()
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1923
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1924
    "Modified: / 17-08-2006 / 19:57:46 / cg"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1925
! !
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1926
12372
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1927
!ProjectDefinition class methodsFor:'description - actions'!
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1928
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1929
postLoadAction
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1930
    "invoked after loading a project"
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1931
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1932
    "/ intentionally left blank, to be redefined by subclasses (i.e. real projects)
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1933
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1934
    "Modified: / 17-08-2006 / 19:59:17 / cg"
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1935
!
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1936
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1937
preLoadAction
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1938
    "invoked before loading a project"
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1939
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1940
    "/ intentionally left blank, to be redefined by subclasses (i.e. real projects)
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1941
!
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1942
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1943
preUnloadAction
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1944
    "invoked before unloading a project"
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1945
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1946
    "/ intentionally left blank, to be redefined by subclasses (i.e. real projects)
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1947
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1948
    "Modified: / 17-08-2006 / 19:59:26 / cg"
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1949
! !
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  1950
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  1951
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1952
!ProjectDefinition class methodsFor:'description - classes'!
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1953
9621
1d07872787b0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9618
diff changeset
  1954
additionalClassNamesAndAttributes
1d07872787b0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9618
diff changeset
  1955
    ^ #()
1d07872787b0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9618
diff changeset
  1956
1d07872787b0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9618
diff changeset
  1957
    "Created: / 21-08-2006 / 19:53:04 / cg"
1d07872787b0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9618
diff changeset
  1958
!
1d07872787b0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9618
diff changeset
  1959
9607
3cae5cf71c03 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9601
diff changeset
  1960
classNamesAndAttributes
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  1961
    "a correponding method with real names must be present in my concrete subclasses"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1962
12202
99295d0c6e3f changed:
Claus Gittinger <cg@exept.de>
parents: 12201
diff changeset
  1963
    "/ should this be a subclassResponsibility here ?
9595
016b493d0fe8 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9592
diff changeset
  1964
    ^ #()
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  1965
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1966
    "Created: / 07-08-2006 / 19:02:57 / fm"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1967
    "Modified: / 07-08-2006 / 21:25:25 / fm"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1968
    "Modified: / 17-08-2006 / 20:47:20 / cg"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1969
!
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1970
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1971
extensionMethodNames
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1972
    "list class/selector pairs of extensions.
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  1973
     A correponding method with real names must be present in my concrete subclasses"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  1974
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  1975
    "/ should this be a subclassResponsibility here ?
9595
016b493d0fe8 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9592
diff changeset
  1976
    ^ #()
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1977
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1978
    "Modified: / 17-08-2006 / 20:49:51 / cg"
10350
f70405894961 added optional ignoredClassNames method.
Claus Gittinger <cg@exept.de>
parents: 10331
diff changeset
  1979
!
f70405894961 added optional ignoredClassNames method.
Claus Gittinger <cg@exept.de>
parents: 10331
diff changeset
  1980
f70405894961 added optional ignoredClassNames method.
Claus Gittinger <cg@exept.de>
parents: 10331
diff changeset
  1981
ignoredClassNames
f70405894961 added optional ignoredClassNames method.
Claus Gittinger <cg@exept.de>
parents: 10331
diff changeset
  1982
    "can be redefined to suppress some classes from being included in a
f70405894961 added optional ignoredClassNames method.
Claus Gittinger <cg@exept.de>
parents: 10331
diff changeset
  1983
     generated classNamesAndAttributes spec"
f70405894961 added optional ignoredClassNames method.
Claus Gittinger <cg@exept.de>
parents: 10331
diff changeset
  1984
f70405894961 added optional ignoredClassNames method.
Claus Gittinger <cg@exept.de>
parents: 10331
diff changeset
  1985
    ^ #()
f70405894961 added optional ignoredClassNames method.
Claus Gittinger <cg@exept.de>
parents: 10331
diff changeset
  1986
f70405894961 added optional ignoredClassNames method.
Claus Gittinger <cg@exept.de>
parents: 10331
diff changeset
  1987
    "Created: / 23-01-2007 / 19:08:27 / cg"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1988
! !
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1989
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  1990
!ProjectDefinition class methodsFor:'description - compilation'!
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  1991
11940
cb9e5867b474 base address definition moved into a separate spec
Claus Gittinger <cg@exept.de>
parents: 11937
diff changeset
  1992
additionalBaseAddressDefinition_bc_dot_mak
cb9e5867b474 base address definition moved into a separate spec
Claus Gittinger <cg@exept.de>
parents: 11937
diff changeset
  1993
    "allows for a base-address definition to be added to the bc.mak file.
cb9e5867b474 base address definition moved into a separate spec
Claus Gittinger <cg@exept.de>
parents: 11937
diff changeset
  1994
     Subclasses may redefine this to something like
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  1995
        LIB_BASE=$(LIBWIDG_BASE)
11940
cb9e5867b474 base address definition moved into a separate spec
Claus Gittinger <cg@exept.de>
parents: 11937
diff changeset
  1996
     This will be inserted BEFORE the 'include stdHeader'
cb9e5867b474 base address definition moved into a separate spec
Claus Gittinger <cg@exept.de>
parents: 11937
diff changeset
  1997
    "
cb9e5867b474 base address definition moved into a separate spec
Claus Gittinger <cg@exept.de>
parents: 11937
diff changeset
  1998
cb9e5867b474 base address definition moved into a separate spec
Claus Gittinger <cg@exept.de>
parents: 11937
diff changeset
  1999
    ^ nil
cb9e5867b474 base address definition moved into a separate spec
Claus Gittinger <cg@exept.de>
parents: 11937
diff changeset
  2000
!
cb9e5867b474 base address definition moved into a separate spec
Claus Gittinger <cg@exept.de>
parents: 11937
diff changeset
  2001
11829
2d880f341cfc #additionalDefinitions for both bc_dot_mak and make_dot_proto
Stefan Vogel <sv@exept.de>
parents: 11789
diff changeset
  2002
additionalDefinitions
2d880f341cfc #additionalDefinitions for both bc_dot_mak and make_dot_proto
Stefan Vogel <sv@exept.de>
parents: 11789
diff changeset
  2003
    "allows for additional definitions/rules to be added to the make.proto and bc.mak file."
2d880f341cfc #additionalDefinitions for both bc_dot_mak and make_dot_proto
Stefan Vogel <sv@exept.de>
parents: 11789
diff changeset
  2004
2d880f341cfc #additionalDefinitions for both bc_dot_mak and make_dot_proto
Stefan Vogel <sv@exept.de>
parents: 11789
diff changeset
  2005
    ^ ''
2d880f341cfc #additionalDefinitions for both bc_dot_mak and make_dot_proto
Stefan Vogel <sv@exept.de>
parents: 11789
diff changeset
  2006
!
2d880f341cfc #additionalDefinitions for both bc_dot_mak and make_dot_proto
Stefan Vogel <sv@exept.de>
parents: 11789
diff changeset
  2007
10306
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2008
additionalDefinitions_bc_dot_mak
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2009
    "allows for additional definitions/rules to be added to the bc.mak file.
10974
9887cad6b7fd typo in comment
Stefan Vogel <sv@exept.de>
parents: 10970
diff changeset
  2010
     Subclasses may redefine this."
10306
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2011
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2012
    ^ self additionalDefinitions_nt_dot_mak
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2013
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2014
    "Created: / 22-08-2006 / 23:59:32 / cg"
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2015
!
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2016
9625
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2017
additionalDefinitions_make_dot_proto
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2018
    "allows for additional definitions/rules to be added to the make.proto file."
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2019
11829
2d880f341cfc #additionalDefinitions for both bc_dot_mak and make_dot_proto
Stefan Vogel <sv@exept.de>
parents: 11789
diff changeset
  2020
    ^ self additionalDefinitions
9625
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2021
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2022
    "Created: / 22-08-2006 / 23:53:08 / cg"
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2023
!
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2024
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2025
additionalDefinitions_nt_dot_mak
10306
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2026
    "obsolete - kept for compatibility with old project files"
9625
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2027
11829
2d880f341cfc #additionalDefinitions for both bc_dot_mak and make_dot_proto
Stefan Vogel <sv@exept.de>
parents: 11789
diff changeset
  2028
    ^ self additionalDefinitions
9625
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2029
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2030
    "Created: / 22-08-2006 / 23:59:32 / cg"
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2031
!
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2032
13688
4f43dc4a3182 added: #additionalHeaderRulesUsingTemplate:pathConverter:
Claus Gittinger <cg@exept.de>
parents: 13687
diff changeset
  2033
additionalHeaderRulesUsingTemplate:template pathConverter:pathConverter
13687
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2034
    "rules for header files (of autoloaded classes).
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2035
     For each extended class, which is autoloaded (and therefore, we will not find a header file for it),
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2036
     generate a rule to create the header file only."
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2037
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2038
    ^ String streamContents:[:s |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2039
        (self extensionClassesWithSuperclasses:true) do:[:eachExtendedClass |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2040
            |headerFileDirPath baseFilename|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2041
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2042
            (eachExtendedClass isLoaded not or:[eachExtendedClass wasAutoloaded]) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2043
                headerFileDirPath := self perform:pathConverter with:eachExtendedClass package.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2044
                baseFilename := self filenameForClass:eachExtendedClass.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2045
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2046
                s nextPutAll:(template
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2047
                    bindWith:headerFileDirPath
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2048
                    with:baseFilename).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2049
            ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2050
        ].
13687
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2051
    ].
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2052
13688
4f43dc4a3182 added: #additionalHeaderRulesUsingTemplate:pathConverter:
Claus Gittinger <cg@exept.de>
parents: 13687
diff changeset
  2053
    "Created: / 12-09-2011 / 16:23:52 / cg"
13687
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2054
!
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2055
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2056
additionalHeaderRules_bc_dot_mak
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2057
    "rules for header files (of autoloaded classes)"
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2058
13695
Claus Gittinger <cg@exept.de>
parents: 13694
diff changeset
  2059
    ^ self
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2060
        additionalHeaderRulesUsingTemplate:(self singleHeaderRuleTemplate_bc_dot_mak)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2061
        pathConverter:#pathToPackage_win32:
13687
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2062
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2063
    "Created: / 12-09-2011 / 15:44:09 / cg"
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2064
!
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2065
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2066
additionalHeaderRules_make_dot_proto
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2067
    "rules for header files (of autoloaded classes)"
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2068
13695
Claus Gittinger <cg@exept.de>
parents: 13694
diff changeset
  2069
    ^ self
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2070
        additionalHeaderRulesUsingTemplate:(self singleHeaderRuleTemplate_make_dot_proto)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2071
        pathConverter:#pathToPackage_unix:
13687
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2072
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2073
    "Created: / 12-09-2011 / 15:44:28 / cg"
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2074
!
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2075
10306
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2076
additionalLinkLibraries_bc_dot_mak
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2077
    "allows for additional static libraries to be added to the bc.mak file.
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2078
     Subclasses may redefine this"
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2079
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2080
    "backward compatibilty with old projects"
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2081
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2082
    ^ self additionalLinkLibraries_nt_dot_mak
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2083
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2084
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2085
    "Created: / 22-08-2006 / 23:53:33 / cg"
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2086
!
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2087
9733
ce3c5ea1d4d0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9726
diff changeset
  2088
additionalLinkLibraries_make_dot_proto
9972
c63164ec0584 Allow shared libraries to be defined for a class lib (needed for liboracle)
Stefan Vogel <sv@exept.de>
parents: 9964
diff changeset
  2089
    "allows for additional static libraries to be added to the make.proto file."
9733
ce3c5ea1d4d0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9726
diff changeset
  2090
ce3c5ea1d4d0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9726
diff changeset
  2091
    ^ ''
ce3c5ea1d4d0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9726
diff changeset
  2092
ce3c5ea1d4d0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9726
diff changeset
  2093
    "Created: / 22-08-2006 / 23:53:33 / cg"
ce3c5ea1d4d0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9726
diff changeset
  2094
!
ce3c5ea1d4d0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9726
diff changeset
  2095
10299
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  2096
additionalLinkLibraries_nt_dot_mak
10306
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2097
    "obsolete - kept for compatibility with old project files"
10299
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  2098
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  2099
    ^ ''
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  2100
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  2101
    "Created: / 22-08-2006 / 23:53:33 / cg"
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  2102
!
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  2103
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2104
additionalRulesHG_bc_dot_mak
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2105
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2106
    (self class includesSelector: #version_HG) ifFalse:[^''].
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2107
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2108
    ^'
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2109
# **Must be at end**
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2110
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2111
# Enforce recompilation of package definition class if Mercurial working
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2112
# copy state changes. Together with --guessVersion it ensures that package
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2113
# definition class always contains correct binary revision string.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2114
!!IFDEF HGROOT
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2115
$(OUTDIR)%1.$(O): $(HGROOT)\.hg\dirstate
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2116
!!ENDIF
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2117
' bindWith: self name.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2118
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2119
    "
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2120
        stx_libscm_mercurial additionalRulesHG_bc_dot_mak
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2121
    "
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2122
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2123
    "Created: / 28-11-2012 / 10:15:05 / Jan Vrany <jan.vrany@fit.cvut.cz>"
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2124
    "Modified: / 08-12-2012 / 12:18:56 / Jan Vrany <jan.vrany@fit.cvut.cz>"
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2125
!
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2126
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2127
additionalRulesHG_make_dot_proto
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2128
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2129
    (self class includesSelector: #version_HG) ifFalse:[^''].
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2130
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2131
    ^'
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2132
# Enforce recompilation of package definition class if Mercurial working
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2133
# copy state changes. Together with --guessVersion it ensures that package
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2134
# definition class always contains correct binary revision string.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2135
ifneq (**NOHG**, $(shell hg root 2> /dev/null || echo -n ''**NOHG**''))
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2136
%1.$(O): $(shell hg root)/.hg/dirstate
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2137
endif
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2138
' bindWith: self name.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2139
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2140
    "
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2141
        stx_libscm_mercurial additionalRulesHG_make_dot_proto
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2142
    "
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2143
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2144
    "Created: / 28-11-2012 / 10:12:03 / Jan Vrany <jan.vrany@fit.cvut.cz>"
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2145
!
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2146
12028
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  2147
additionalRulesSvn_make_dot_proto
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  2148
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  2149
    (self class includesSelector: #svnRevisionNr) ifFalse:[^''].
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  2150
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2151
    ^'
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2152
# Update SVN revision in package definition class
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2153
ifneq (,$(findstring .svn,$(wildcard .svn)))
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2154
.svnversion: *.st
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2155
        if [ -d .svn ]; then \
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2156
                rev=$(shell svnversion -n); \
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2157
                echo -n $$rev > .svnversion; \
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2158
        else \
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2159
                echo -n exported > .svnversion; \
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2160
        fi
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2161
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2162
%1.o: %1.st .svnversion
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2163
        @if [ -d .svn ]; then \
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2164
                rev2="$(shell printf "%-16s" $$(cat .svnversion))"; \
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2165
                echo "  [SV]  Expanding svnRevisionNo in $1.st"; \
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2166
                sed -e "s/\"\$$SVN\-Revision:\".*\"\$$\"/\"\$$SVN-Revision:\"\''$$rev2\''\"\$$\"/g" $< > .%1.svn.st; \
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2167
        fi
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2168
        $(MAKE) CC="$(CLASSLIB_CC)" OPT="$(OPT)" SEPINITCODE="$(SEPINITCODE)" STC="$(STC)" STFILE=.%1.svn $(C_RULE);
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2169
        sed -i -e "s/\".%1.svn.st\");/\"\%1.st\");/g" .%1.svn.c
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2170
        $(MAKE) .%1.svn.$(O)
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2171
        @mv .%1.svn.$(O) %1.$(O)
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2172
endif
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2173
' bindWith: self name.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2174
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2175
    "
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2176
        stx_libbasic3 additionalRulesSvn_make_dot_proto
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2177
    "
12028
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  2178
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  2179
    "Created: / 24-06-2009 / 21:33:32 / Jan Vrany <vranyj1@fel.cvut.cz>"
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2180
    "Modified: / 28-11-2012 / 10:12:24 / Jan Vrany <jan.vrany@fit.cvut.cz>"
12028
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  2181
!
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  2182
10306
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2183
additionalRules_bc_dot_mak
10312
7f71d47b09bd #additionalTargets_bc_dot_mak for applications
Stefan Vogel <sv@exept.de>
parents: 10306
diff changeset
  2184
    "obsolete - kept for compatibility with old project files"
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  2185
10312
7f71d47b09bd #additionalTargets_bc_dot_mak for applications
Stefan Vogel <sv@exept.de>
parents: 10306
diff changeset
  2186
    ^ ''
7f71d47b09bd #additionalTargets_bc_dot_mak for applications
Stefan Vogel <sv@exept.de>
parents: 10306
diff changeset
  2187
7f71d47b09bd #additionalTargets_bc_dot_mak for applications
Stefan Vogel <sv@exept.de>
parents: 10306
diff changeset
  2188
    "Created: / 22-08-2006 / 23:59:24 / cg"
10306
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2189
!
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2190
9625
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2191
additionalRules_make_dot_proto
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2192
    "allows for additional rules to be added to the make.proto file."
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2193
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2194
    ^ ''
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2195
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2196
    "Created: / 22-08-2006 / 23:59:16 / cg"
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2197
!
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2198
9972
c63164ec0584 Allow shared libraries to be defined for a class lib (needed for liboracle)
Stefan Vogel <sv@exept.de>
parents: 9964
diff changeset
  2199
additionalSharedLinkLibraries_make_dot_proto
c63164ec0584 Allow shared libraries to be defined for a class lib (needed for liboracle)
Stefan Vogel <sv@exept.de>
parents: 9964
diff changeset
  2200
    "allows for additional shared libraries to be added to the make.proto file."
c63164ec0584 Allow shared libraries to be defined for a class lib (needed for liboracle)
Stefan Vogel <sv@exept.de>
parents: 9964
diff changeset
  2201
c63164ec0584 Allow shared libraries to be defined for a class lib (needed for liboracle)
Stefan Vogel <sv@exept.de>
parents: 9964
diff changeset
  2202
    ^ ''
c63164ec0584 Allow shared libraries to be defined for a class lib (needed for liboracle)
Stefan Vogel <sv@exept.de>
parents: 9964
diff changeset
  2203
!
c63164ec0584 Allow shared libraries to be defined for a class lib (needed for liboracle)
Stefan Vogel <sv@exept.de>
parents: 9964
diff changeset
  2204
12028
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  2205
additionalTargetsSvn_make_dot_proto
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2206
    "Returns additional targets to make when build projec
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2207
     checked out from SVN"
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2208
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2209
    "As of 2011-02-06, new version of libsvn does not use any additional targets"
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2210
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2211
    ^''
12028
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  2212
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  2213
    "Created: / 24-06-2009 / 21:35:15 / Jan Vrany <vranyj1@fel.cvut.cz>"
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2214
    "Modified (comment): / 06-02-2012 / 15:34:04 / Jan Vrany <jan.vrany@fit.cvut.cz>"
12028
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  2215
!
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  2216
10306
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2217
additionalTargets_bc_dot_mak
10312
7f71d47b09bd #additionalTargets_bc_dot_mak for applications
Stefan Vogel <sv@exept.de>
parents: 10306
diff changeset
  2218
    "obsolete - kept for compatibility with old project files"
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  2219
10312
7f71d47b09bd #additionalTargets_bc_dot_mak for applications
Stefan Vogel <sv@exept.de>
parents: 10306
diff changeset
  2220
    ^ ''
10306
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2221
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2222
    "Created: / 23-08-2006 / 00:00:35 / cg"
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2223
!
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2224
9625
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2225
additionalTargets_make_dot_proto
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2226
    "allows for additional targets to be added to the make.proto file."
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2227
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2228
    ^ ''
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2229
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2230
    "Created: / 22-08-2006 / 23:53:33 / cg"
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2231
!
dc6a4ebdb1f4 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9624
diff changeset
  2232
10979
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2233
globalDefines
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2234
    "allow for the specification of additional defines for stc compilation of prerequisite packages
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2235
     an subprojects"
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2236
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2237
    ^ ''
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2238
!
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2239
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2240
globalDefines_unix
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2241
    "allow for the specification of additional defines for stc compilation of prerequisite packages
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2242
     an subprojects"
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2243
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2244
    ^ self globalDefines
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2245
!
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2246
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2247
globalDefines_win32
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2248
    "allow for the specification of additional defines for stc compilation of prerequisite packages
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2249
     an subprojects"
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2250
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2251
    ^ self globalDefines
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2252
!
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2253
10331
3a697063403e Add localDefines
Stefan Vogel <sv@exept.de>
parents: 10317
diff changeset
  2254
localDefines
10979
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2255
    "allow for the specification of additional defines for stc compilation"
10331
3a697063403e Add localDefines
Stefan Vogel <sv@exept.de>
parents: 10317
diff changeset
  2256
3a697063403e Add localDefines
Stefan Vogel <sv@exept.de>
parents: 10317
diff changeset
  2257
    ^ ''
3a697063403e Add localDefines
Stefan Vogel <sv@exept.de>
parents: 10317
diff changeset
  2258
!
3a697063403e Add localDefines
Stefan Vogel <sv@exept.de>
parents: 10317
diff changeset
  2259
3a697063403e Add localDefines
Stefan Vogel <sv@exept.de>
parents: 10317
diff changeset
  2260
localDefines_unix
10979
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2261
    "allow for the specification of additional defines for stc compilation"
10331
3a697063403e Add localDefines
Stefan Vogel <sv@exept.de>
parents: 10317
diff changeset
  2262
3a697063403e Add localDefines
Stefan Vogel <sv@exept.de>
parents: 10317
diff changeset
  2263
    ^ self localDefines
3a697063403e Add localDefines
Stefan Vogel <sv@exept.de>
parents: 10317
diff changeset
  2264
!
3a697063403e Add localDefines
Stefan Vogel <sv@exept.de>
parents: 10317
diff changeset
  2265
3a697063403e Add localDefines
Stefan Vogel <sv@exept.de>
parents: 10317
diff changeset
  2266
localDefines_win32
10979
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2267
    "allow for the specification of additional defines for stc compilation"
10331
3a697063403e Add localDefines
Stefan Vogel <sv@exept.de>
parents: 10317
diff changeset
  2268
3a697063403e Add localDefines
Stefan Vogel <sv@exept.de>
parents: 10317
diff changeset
  2269
    ^ self localDefines
3a697063403e Add localDefines
Stefan Vogel <sv@exept.de>
parents: 10317
diff changeset
  2270
!
3a697063403e Add localDefines
Stefan Vogel <sv@exept.de>
parents: 10317
diff changeset
  2271
9826
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  2272
localIncludes
10979
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2273
    "allow for the specification of additional include directories"
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  2274
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  2275
    ^ ''
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  2276
9826
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  2277
    "Created: / 06-09-2006 / 18:14:31 / cg"
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  2278
!
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  2279
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  2280
localIncludes_unix
10979
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2281
    "allow for the specification of additional include directories"
9826
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  2282
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  2283
    ^ self makeUnixIncludes:(self localIncludes)
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  2284
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  2285
    "Created: / 18-08-2006 / 12:50:27 / cg"
9826
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  2286
    "Modified: / 06-09-2006 / 18:15:26 / cg"
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  2287
!
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  2288
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  2289
localIncludes_win32
10979
8dca736dfb68 Fix LOCALDEFINES
Stefan Vogel <sv@exept.de>
parents: 10976
diff changeset
  2290
    "allow for the specification of additional include directories"
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  2291
9826
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  2292
    ^ self makeWin32Includes:(self localIncludes)
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  2293
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  2294
    "Created: / 18-08-2006 / 12:50:27 / cg"
9826
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  2295
    "Modified: / 06-09-2006 / 18:15:37 / cg"
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  2296
!
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  2297
11576
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2298
primaryTarget
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2299
    "allows the primary make target to be defined in the Make.proto/bc.mak file."
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2300
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2301
    ^ ''
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2302
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2303
    "Created: / 22-08-2006 / 23:53:33 / cg"
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2304
!
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2305
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2306
primaryTarget_bc_dot_mak
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2307
    "allows the primary make target to be defined in the bc.mak file."
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2308
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2309
    ^ self primaryTarget
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2310
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2311
    "Created: / 22-08-2006 / 23:53:33 / cg"
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2312
!
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2313
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2314
primaryTarget_make_dot_proto
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2315
    "allows the primary make target to be defined in the Make.proto file."
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2316
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2317
    ^ self primaryTarget
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2318
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2319
    "Created: / 22-08-2006 / 23:53:33 / cg"
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2320
!
8b244e994b96 Allow to define primary make target (needed, if sub.makes have to be performed -
Stefan Vogel <sv@exept.de>
parents: 11562
diff changeset
  2321
13687
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2322
singleHeaderRuleTemplate_bc_dot_mak
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2323
    "rules for header files (of autoloaded classes)"
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2324
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2325
    ^ '
13688
4f43dc4a3182 added: #additionalHeaderRulesUsingTemplate:pathConverter:
Claus Gittinger <cg@exept.de>
parents: 13687
diff changeset
  2326
%1\%2.$(H):
4f43dc4a3182 added: #additionalHeaderRulesUsingTemplate:pathConverter:
Claus Gittinger <cg@exept.de>
parents: 13687
diff changeset
  2327
    pushd %1 \
13687
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2328
    & $(STC) $(FFLAGS) $(STCFLAGS) $(STC_MSGFORMAT) $(DBGFLAGS) $(DEFS) -C -headerOnly %2.st \
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2329
    & popd
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2330
'
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2331
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2332
    "Created: / 12-09-2011 / 15:55:49 / cg"
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2333
!
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2334
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2335
singleHeaderRuleTemplate_make_dot_proto
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2336
    "rules for header files (of autoloaded classes)"
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2337
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2338
    ^ '
13688
4f43dc4a3182 added: #additionalHeaderRulesUsingTemplate:pathConverter:
Claus Gittinger <cg@exept.de>
parents: 13687
diff changeset
  2339
%1/%2.$(H):
4f43dc4a3182 added: #additionalHeaderRulesUsingTemplate:pathConverter:
Claus Gittinger <cg@exept.de>
parents: 13687
diff changeset
  2340
    pushd %1 \
13687
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2341
    & $(STC) $(FFLAGS) $(STCFLAGS) $(STC_MSGFORMAT) $(DBGFLAGS) $(DEFS) -C -headerOnly %2.st \
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2342
    & popd
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2343
'
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2344
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2345
    "Created: / 12-09-2011 / 15:55:57 / cg"
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2346
!
1577ea868878 generate rules for header files of extended classes
Claus Gittinger <cg@exept.de>
parents: 13650
diff changeset
  2347
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2348
stcOptimizationOptions
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2349
    "see the stc reference / stc usage for options.
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2350
     For now, the following variants are useful:
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2351
        +optspace3                  most compact code
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2352
                                    - use for all gui, application code.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2353
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2354
        +optinline +optinline2 +inlineNew
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2355
                                    fastest code
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2356
                                    - use only for computation-intensive classes"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2357
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2358
    ^ '+optspace3'
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2359
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2360
    "Created: / 18-08-2006 / 12:50:27 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2361
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2362
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2363
stcWarningOptions
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2364
    "see the stc reference / stc usage for options.
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2365
     For now, the following variants are useful:
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2366
        -warn                   no warnings
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2367
        -warnNonStandard        no warnings about non-standard smalltalk features"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2368
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  2369
    ^ '-warnNonStandard'
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2370
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2371
    "Created: / 18-08-2006 / 12:51:38 / cg"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2372
! !
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2373
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2374
!ProjectDefinition class methodsFor:'description - project information'!
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2375
11611
fa06cde6bd11 Allow for additional icon files to be placed in resources
Stefan Vogel <sv@exept.de>
parents: 11580
diff changeset
  2376
applicationAdditionalIconFileNames
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  2377
    "Return the icon-filenames for additional icons of the application
11611
fa06cde6bd11 Allow for additional icon files to be placed in resources
Stefan Vogel <sv@exept.de>
parents: 11580
diff changeset
  2378
    (empty collection if there are none)"
fa06cde6bd11 Allow for additional icon files to be placed in resources
Stefan Vogel <sv@exept.de>
parents: 11580
diff changeset
  2379
fa06cde6bd11 Allow for additional icon files to be placed in resources
Stefan Vogel <sv@exept.de>
parents: 11580
diff changeset
  2380
    ^ #()
fa06cde6bd11 Allow for additional icon files to be placed in resources
Stefan Vogel <sv@exept.de>
parents: 11580
diff changeset
  2381
!
fa06cde6bd11 Allow for additional icon files to be placed in resources
Stefan Vogel <sv@exept.de>
parents: 11580
diff changeset
  2382
11039
1f977c01e7df Fix usage of #iconFilename vs. #applicationIconFilename
Stefan Vogel <sv@exept.de>
parents: 11035
diff changeset
  2383
applicationIconFileName
1f977c01e7df Fix usage of #iconFilename vs. #applicationIconFilename
Stefan Vogel <sv@exept.de>
parents: 11035
diff changeset
  2384
    "Return the icon-filename for the application (nil if there is none)"
1f977c01e7df Fix usage of #iconFilename vs. #applicationIconFilename
Stefan Vogel <sv@exept.de>
parents: 11035
diff changeset
  2385
1f977c01e7df Fix usage of #iconFilename vs. #applicationIconFilename
Stefan Vogel <sv@exept.de>
parents: 11035
diff changeset
  2386
    ^ nil
1f977c01e7df Fix usage of #iconFilename vs. #applicationIconFilename
Stefan Vogel <sv@exept.de>
parents: 11035
diff changeset
  2387
!
1f977c01e7df Fix usage of #iconFilename vs. #applicationIconFilename
Stefan Vogel <sv@exept.de>
parents: 11035
diff changeset
  2388
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2389
companyName
9584
40fa96f1313a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9579
diff changeset
  2390
    "Returns a company string which will appear in <lib>.rc.
40fa96f1313a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9579
diff changeset
  2391
     Under win32, this is placed into the dlls file-info"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2392
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  2393
    (
11172
04ba10b4fcf9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 11157
diff changeset
  2394
      #(
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2395
        'stx'
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2396
        'exept'
11172
04ba10b4fcf9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 11157
diff changeset
  2397
      ) includes:self module) ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2398
        ^ 'eXept Software AG'
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2399
    ].
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2400
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2401
    ^ 'My Company'
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2402
9584
40fa96f1313a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9579
diff changeset
  2403
    "Modified: / 18-08-2006 / 16:08:20 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2404
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2405
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2406
description
10306
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2407
    "Returns a description string which will appear in vc.def / bc.def"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2408
9803
cbec7d6caec8 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9799
diff changeset
  2409
    ^self productName,' ',self packageName
cbec7d6caec8 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9799
diff changeset
  2410
"/    ^ self name
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2411
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2412
    "Created: / 08-08-2006 / 11:15:01 / fm"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2413
    "Modified: / 17-08-2006 / 20:53:34 / cg"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2414
!
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2415
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2416
fileDescription
10416
e4fe2bf2276d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10414
diff changeset
  2417
    "Returns a description string which will appear in libName.rc and the rc-file"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2418
9803
cbec7d6caec8 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9799
diff changeset
  2419
    ^self description
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2420
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2421
    "Modified: / 17-08-2006 / 20:27:07 / cg"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2422
!
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2423
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2424
fileMajorVersionNr
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2425
    "Returns a versionNumber which will appear in libName.rc"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2426
11100
c9ec12ef4b3b Set default for fileMajorVersionNumber and fileMajorVersionNumber
Stefan Vogel <sv@exept.de>
parents: 11074
diff changeset
  2427
    ^ self majorVersionNr
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2428
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2429
    "Created: / 18-08-2006 / 12:03:32 / cg"
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2430
    "Modified: / 30-08-2006 / 18:50:51 / cg"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2431
!
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2432
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2433
fileMinorVersionNr
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2434
    "Returns a versionNumber which will appear in libName.rc"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2435
11100
c9ec12ef4b3b Set default for fileMajorVersionNumber and fileMajorVersionNumber
Stefan Vogel <sv@exept.de>
parents: 11074
diff changeset
  2436
    ^ self minorVersionNr
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2437
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2438
    "Created: / 18-08-2006 / 12:03:13 / cg"
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2439
    "Modified: / 30-08-2006 / 18:50:46 / cg"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2440
!
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2441
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2442
fileReleaseNr
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2443
    "Returns a releaseNumber which will appear in libName.rc"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2444
11035
ff88ec6339a3 Generate valid project.rc files even if the CVS revision string ends with
Stefan Vogel <sv@exept.de>
parents: 10979
diff changeset
  2445
    "take the default revision from the cvs-version,
ff88ec6339a3 Generate valid project.rc files even if the CVS revision string ends with
Stefan Vogel <sv@exept.de>
parents: 10979
diff changeset
  2446
     but ignore a possibly present 'm'-flag that is set when this revision has been modified"
ff88ec6339a3 Generate valid project.rc files even if the CVS revision string ends with
Stefan Vogel <sv@exept.de>
parents: 10979
diff changeset
  2447
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2448
    "JV@2012-11-20: Original code was:
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2449
11035
ff88ec6339a3 Generate valid project.rc files even if the CVS revision string ends with
Stefan Vogel <sv@exept.de>
parents: 10979
diff changeset
  2450
    ^ self cvsRevision last upTo:$m
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2451
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2452
    But this is too CVS specific. Modern SCMs does not use X.Y style
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2453
    revision numbers, instead it uses hashes (Git/Mercurial/Darcs/Monotone).
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2454
    Even worse, all the SCM code passes strings around, so providing compatible,
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2455
    polymorph object is not possible. Hence following hack."
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2456
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2457
    | nr |
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2458
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2459
    nr := (self cvsRevision last upTo:$m) select:[:c|c isDigit].
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2460
    nr isEmptyOrNil ifTrue:[^'0'].
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2461
    nr := (nr asInteger min: 16r7FFF) printString.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2462
    ^nr
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2463
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2464
    "Created: / 18-08-2006 / 12:02:58 / cg"
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2465
    "Modified: / 30-08-2006 / 18:54:48 / cg"
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2466
    "Modified: / 23-11-2012 / 11:24:09 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2467
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2468
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2469
fileRevisionNr
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2470
    "Returns a revisionNumber which will appear in libName.rc"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2471
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2472
    "take the default revision from the cvs-version"
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2473
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2474
    "JV@2012-11-20: Original code was:
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2475
9618
adc627ef4702 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9615
diff changeset
  2476
    ^ self cvsRevision first
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2477
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2478
    But this is too CVS specific. Modern SCMs does not use X.Y style
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2479
    revision numbers, instead it uses hashes (Git/Mercurial/Darcs/Monotone).
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2480
    Even worse, all the SCM code passes strings around, so providing compatible,
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2481
    polymorph object is not possible. Hence following hack."
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2482
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2483
    | nr |
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2484
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2485
    nr := self cvsRevision first select:[:c|c isDigit].
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2486
    nr isEmptyOrNil ifTrue:[^'0'].
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2487
    nr := (nr asInteger min: 16r7FFF) printString.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2488
    ^nr
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2489
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2490
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2491
    "
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2492
    stx_libbasic fileRevisionNr
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2493
    stx_libbasic2 fileRevisionNr
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2494
    stx_libscm_mercurial fileRevisionNr
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2495
    "
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2496
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2497
    "Created: / 18-08-2006 / 12:02:39 / cg"
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2498
    "Modified: / 30-08-2006 / 18:54:39 / cg"
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  2499
    "Modified: / 23-11-2012 / 11:24:12 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2500
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2501
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2502
fileVersion
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2503
    "Returns a fileVersion string which will appear in libName.rc"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2504
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2505
    "<major>.<minor>.<rev>.<rel> (such as '1.2.17.1') "
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2506
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  2507
    ^ '%1.%2.%3.%4'
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2508
        bindWith:self fileMajorVersionNr
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2509
        with:self fileMinorVersionNr
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2510
        with:self fileRevisionNr
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2511
        with:self fileReleaseNr.
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2512
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2513
    "
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2514
     self fileVersion
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2515
    "
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2516
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2517
    "Modified: / 30-08-2006 / 18:51:49 / cg"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2518
!
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2519
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2520
fileVersionCommaSeparated
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2521
    "Returns a fileVersion string which will appear in libName.rc"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2522
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2523
    "<major>,<minor>,<revision>,<release> (such as '2,17,1,2') "
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2524
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  2525
    ^ '%1,%2,%3,%4'
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2526
        bindWith:self fileMajorVersionNr
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2527
        with:self fileMinorVersionNr
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2528
        with:self fileRevisionNr
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2529
        with:self fileReleaseNr.
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2530
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2531
    "Created: / 17-08-2006 / 20:16:17 / cg"
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2532
    "Modified: / 30-08-2006 / 18:54:20 / cg"
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2533
!
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2534
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2535
internalName
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2536
    "Returns a name string which will appear in libName.rc"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2537
11041
3bb26d86e616 Fix #description and #internalName
Stefan Vogel <sv@exept.de>
parents: 11039
diff changeset
  2538
    ^ self package
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2539
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2540
    "Modified: / 17-08-2006 / 20:27:37 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2541
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2542
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2543
legalCopyright
9584
40fa96f1313a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9579
diff changeset
  2544
    "Returns a copyright string which will appear in <lib>.rc.
40fa96f1313a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9579
diff changeset
  2545
     Under win32, this is placed into the dlls file-info"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2546
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2547
    self module = 'stx' ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2548
        "hardwired-default"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2549
        ^ 'Copyright Claus Gittinger 1988-%1\nCopyright eXept Software AG 1998-%1'
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2550
            bindWith:(Date today year printString)
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2551
    ].
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2552
    self module = 'exept' ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2553
        "hardwired-default"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2554
        ^ 'Copyright eXept Software AG 1998-%1'
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2555
            bindWith:(Date today year printString)
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2556
    ].
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2557
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2558
    ^ 'My CopyRight or CopyLeft'
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2559
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2560
    "Modified: / 30-08-2006 / 18:53:36 / cg"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2561
!
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2562
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2563
majorVersionNr
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2564
    "Returns a versionNumber which will appear in libName.rc"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2565
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2566
    "<major>.<minor>.<revision>.<release> (such as '5.3.2.1')
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2567
     the default here takes smalltalks version number.
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2568
     But thats probably not good for an end-user-app."
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2569
11042
686cd566a2b1 Fix version stuff
Stefan Vogel <sv@exept.de>
parents: 11041
diff changeset
  2570
    ^ Smalltalk majorVersionNr
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2571
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2572
    "Created: / 17-08-2006 / 20:20:18 / cg"
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2573
    "Modified: / 30-08-2006 / 18:52:13 / cg"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2574
!
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2576
minorVersionNr
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2577
    "Returns a versionNumber which will appear in libName.rc"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2578
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2579
    "<major>.<minor>.<revision>.<release> (such as '5.3.2.1')
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2580
     the default here takes smalltalks version number.
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2581
     But thats probably not good for an end-user-app."
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2582
11042
686cd566a2b1 Fix version stuff
Stefan Vogel <sv@exept.de>
parents: 11041
diff changeset
  2583
    ^ Smalltalk minorVersionNr
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2584
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2585
    "Created: / 17-08-2006 / 20:20:32 / cg"
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2586
    "Modified: / 30-08-2006 / 18:52:16 / cg"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2587
!
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2588
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2589
productDate
11043
eb2bd420e952 Fix version stuff
Stefan Vogel <sv@exept.de>
parents: 11042
diff changeset
  2590
    "Returns a product-date string which will appear in libName.rc and the installer file"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2591
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2592
    "take the current date - by default"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2593
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2594
    ^ Timestamp now printStringRFC1123Format
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2595
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2596
    "Created: / 17-08-2006 / 20:17:28 / cg"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2597
!
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2598
13177
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2599
productDescription
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2600
    "Returns a description (for autopackage)"
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2601
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2602
    ^ self description
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2603
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2604
    "Created: / 21-12-2010 / 09:32:16 / cg"
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2605
!
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2606
10426
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2607
productFilename
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2608
    "Returns a filename which be used as linkname, product file name etc."
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2609
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2610
    ^ self productNameAsValidFilename
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2611
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2612
    "
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  2613
     stx_projects_smalltalk productName
10426
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2614
     stx_projects_smalltalk productFilename
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2615
    "
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2616
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2617
    "Created: / 01-03-2007 / 19:33:06 / cg"
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2618
!
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2619
9898
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2620
productInstallDir
13873
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  2621
    "Returns a default installDir which will appear in <app>.nsi."
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  2622
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  2623
    ^ '$PROGRAMFILES\',(self productInstallDirBaseName).
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  2624
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  2625
    "
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  2626
     stx_projects_smalltalk productInstallDir
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  2627
     stx_clients_Clock_QlockTwoWatchApplication productInstallDir
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  2628
    "
9898
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2629
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2630
    "Created: / 14-09-2006 / 21:23:01 / cg"
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2631
!
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2632
13873
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  2633
productInstallDirBaseName
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  2634
    "Returns a default installDir which will appear in <app>.nsi.
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  2635
     This is usually not the one you want to keep"
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  2636
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  2637
    ^ self module
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  2638
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  2639
    "Created: / 21-12-2011 / 16:31:38 / cg"
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  2640
!
Claus Gittinger <cg@exept.de>
parents: 13863
diff changeset
  2641
13177
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2642
productLicense
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2643
    "Returns the license (for autopackage)"
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2644
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2645
    ^ 'Commercial'
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2646
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2647
    "Created: / 21-12-2010 / 09:31:25 / cg"
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2648
!
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2649
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2650
productMaintainer
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2651
    "Returns the maintainer (for autopackage)"
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2652
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2653
    ^ self companyName
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2654
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2655
    "Created: / 21-12-2010 / 09:26:16 / cg"
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2656
!
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2657
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2658
productName
9584
40fa96f1313a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9579
diff changeset
  2659
    "Returns a product name which will appear in <lib>.rc.
40fa96f1313a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9579
diff changeset
  2660
     Under win32, this is placed into the dlls file-info"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2661
10785
da5023cdf55b no need for productName string (already inherited)
Claus Gittinger <cg@exept.de>
parents: 10774
diff changeset
  2662
    |m|
da5023cdf55b no need for productName string (already inherited)
Claus Gittinger <cg@exept.de>
parents: 10774
diff changeset
  2663
da5023cdf55b no need for productName string (already inherited)
Claus Gittinger <cg@exept.de>
parents: 10774
diff changeset
  2664
    m := self module.
da5023cdf55b no need for productName string (already inherited)
Claus Gittinger <cg@exept.de>
parents: 10774
diff changeset
  2665
    m = 'stx' ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2666
        ^ 'Smalltalk/X'
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2667
    ].
10785
da5023cdf55b no need for productName string (already inherited)
Claus Gittinger <cg@exept.de>
parents: 10774
diff changeset
  2668
    m = 'exept' ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2669
        ^ 'eXept addOns'
10785
da5023cdf55b no need for productName string (already inherited)
Claus Gittinger <cg@exept.de>
parents: 10774
diff changeset
  2670
    ].
10296
48eb9cc9eef0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10251
diff changeset
  2671
    Error handle:[:ex |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2672
        ^ 'ProductName'
10296
48eb9cc9eef0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10251
diff changeset
  2673
    ] do:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2674
        ^ self startupClassName
10296
48eb9cc9eef0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10251
diff changeset
  2675
    ].
48eb9cc9eef0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10251
diff changeset
  2676
10785
da5023cdf55b no need for productName string (already inherited)
Claus Gittinger <cg@exept.de>
parents: 10774
diff changeset
  2677
    "Modified: / 08-11-2007 / 16:45:14 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2678
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2679
10426
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2680
productNameAsValidFilename
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2681
    "Returns a product name which will appear in <lib>.rc.
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2682
     Under win32, this is placed into the dlls file-info"
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2683
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2684
    |nm|
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2685
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2686
    nm := self productName.
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2687
    ^ nm copy replaceAny:'/\:;.,' with:$_
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2688
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2689
    "
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2690
     'Smalltalk/X' replaceAny:'/\:;.,' with:nil
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2691
    "
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2692
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2693
    "Created: / 01-03-2007 / 19:19:21 / cg"
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2694
!
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2695
9898
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2696
productPublisher
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2697
    "Returns a product publisher which will appear in <app>.nsi."
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2698
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2699
    ( #('exept' 'stx') includes:self module) ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2700
        ^ 'eXept Software AG'
9898
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2701
    ].
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2702
11789
8d56dc5fa8a8 Default productPublisher is companyName
Stefan Vogel <sv@exept.de>
parents: 11777
diff changeset
  2703
    ^ self companyName
9898
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2704
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2705
    "Created: / 14-09-2006 / 21:12:54 / cg"
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2706
!
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2707
13177
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2708
productType
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2709
    "Returns the product type for autopackage"
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2710
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2711
    ^ 'Application'
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2712
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2713
    "Created: / 21-12-2010 / 09:28:48 / cg"
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2714
!
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2715
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2716
productVersion
11043
eb2bd420e952 Fix version stuff
Stefan Vogel <sv@exept.de>
parents: 11042
diff changeset
  2717
    "Returns a product version which will appear in libName.rc and the installer file"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2718
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2719
    "<major>.<minor>.<revision>.<release> (such as '5.3.2.1')"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2720
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  2721
    ^ '%1.%2.%3.%4'
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2722
        bindWith:self majorVersionNr
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2723
        with:self minorVersionNr
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2724
        with:self revisionNr
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2725
        with:self releaseNr.
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2726
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2727
    "
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2728
     self productVersion
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2729
    "
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2730
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2731
    "Modified: / 30-08-2006 / 18:52:47 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2732
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2733
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2734
productVersionCommaSeparated
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2735
    "Returns a product version which will appear in libName.rc"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2736
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2737
    "<major>.<minor>.<revision>.<release> (such as '0,1,1,1') "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2738
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  2739
    ^ '%1,%2,%3,%4'
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2740
        bindWith:self majorVersionNr
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2741
        with:self minorVersionNr
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2742
        with:self revisionNr
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2743
        with:self releaseNr.
11042
686cd566a2b1 Fix version stuff
Stefan Vogel <sv@exept.de>
parents: 11041
diff changeset
  2744
686cd566a2b1 Fix version stuff
Stefan Vogel <sv@exept.de>
parents: 11041
diff changeset
  2745
    "
686cd566a2b1 Fix version stuff
Stefan Vogel <sv@exept.de>
parents: 11041
diff changeset
  2746
     self productVersionCommaSeparated
686cd566a2b1 Fix version stuff
Stefan Vogel <sv@exept.de>
parents: 11041
diff changeset
  2747
    "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2748
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2749
    "Created: / 17-08-2006 / 20:13:32 / cg"
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2750
    "Modified: / 30-08-2006 / 18:52:42 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2751
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2752
9898
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2753
productWebSite
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2754
    "Returns a product webSite which will appear in <app>.nsi."
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2755
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2756
    ( #('exept' 'stx') includes:self module) ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2757
        ^ 'http://www.exept.de'
9898
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2758
    ].
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2759
10426
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2760
    "/ should be redefined by concrete ApplicationDefinition
9898
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2761
    ^ 'http://www.yoursite.com'
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2762
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2763
    "Created: / 14-09-2006 / 21:15:05 / cg"
10426
37dc4c920ba3 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10416
diff changeset
  2764
    "Modified: / 01-03-2007 / 18:11:27 / cg"
9898
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2765
!
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2766
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2767
releaseNr
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2768
    "Returns a releaseNr which will appear in libName.rc"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2769
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2770
    "<major>.<minor>.<revision>.<release> (such as '5.3.2.1')
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2771
     the default here takes smalltalks version number.
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2772
     But thats probably not good for an end-user-app."
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2773
11042
686cd566a2b1 Fix version stuff
Stefan Vogel <sv@exept.de>
parents: 11041
diff changeset
  2774
    ^ Smalltalk releaseNr
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2775
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2776
    "Created: / 17-08-2006 / 20:20:51 / cg"
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2777
    "Modified: / 30-08-2006 / 18:52:22 / cg"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2778
!
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2779
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2780
revisionNr
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2781
    "Returns a revisionNr which will appear in libName.rc"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2782
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2783
    "<major>.<minor>.<revision>.<release> (such as '5.3.2.1')
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2784
     the default here takes smalltalks version number.
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2785
     But thats probably not good for an end-user-app."
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2786
11042
686cd566a2b1 Fix version stuff
Stefan Vogel <sv@exept.de>
parents: 11041
diff changeset
  2787
    ^ Smalltalk revisionNr
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2788
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2789
    "Created: / 17-08-2006 / 20:20:40 / cg"
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  2790
    "Modified: / 30-08-2006 / 18:52:32 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2791
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2792
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2793
versionNumber
10306
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  2794
    "Returns a version string which will appear in bc.def / vc.def "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2795
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2796
    ^''
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2797
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2798
    "Created: / 08-08-2006 / 11:35:52 / fm"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  2799
    "Modified: / 17-08-2006 / 19:46:29 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2800
! !
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2801
9569
b0bf179c9bf5 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9559
diff changeset
  2802
!ProjectDefinition class methodsFor:'file generation'!
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2803
13177
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2804
apspecFilename
13968
03b79717bd2b comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13959
diff changeset
  2805
    "/ for linux
13177
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2806
    ^ 'autopackage/default.apspec'
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2807
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2808
    "Created: / 21-12-2010 / 09:43:13 / cg"
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2809
!
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2810
9852
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
  2811
basicFileNamesToGenerate
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  2812
    "answer a dictionary (filename -> generator method) with all the files,
11937
622f2641439d vcmake.bat generation
Claus Gittinger <cg@exept.de>
parents: 11869
diff changeset
  2813
     that have to be generated for this package"
10864
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2814
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2815
    |dict|
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2816
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  2817
    dict := OrderedDictionary withKeysAndValues:#(
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2818
          'Make.spec'         #'generate_make_dot_spec'
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2819
          'Make.proto'        #'generate_make_dot_proto'
13968
03b79717bd2b comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13959
diff changeset
  2820
          'Makefile'          #'generate_makefile'          "/ for unix
03b79717bd2b comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13959
diff changeset
  2821
          'bc.mak'            #'generate_bc_dot_mak'        "/ for windows
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2822
          'abbrev.stc'        #'generate_abbrev_dot_stc'
13968
03b79717bd2b comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13959
diff changeset
  2823
          'bmake.bat'         #'generate_bmake_dot_mak'     "/ for bcc32
03b79717bd2b comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13959
diff changeset
  2824
          'vcmake.bat'        #'generate_vcmake_dot_mak'    "/ for msvc
14334
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  2825
          'lccmake.bat'       #'generate_lccmake_dot_mak'   "/ for lcc
14345
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  2826
          "/ 'tccmake.bat'       #'generate_tccmake_dot_mak'     "/ for tcc - cannot link at the moment
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  2827
          'mingwmake.bat'     #'generate_mingwmake_dot_mak'   "/ for mingw
10864
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2828
    ).
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2829
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  2830
    dict
14060
cefb6d8205e4 changed:
Stefan Vogel <sv@exept.de>
parents: 14045
diff changeset
  2831
        at:self rcFilename      put:#'generate_packageName_dot_rc'.             "/ for windows
10864
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2832
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2833
    ^ dict.
13154
bac0fcd8a888 make sure that the makefiles are generated before the libInit file
Claus Gittinger <cg@exept.de>
parents: 13148
diff changeset
  2834
14345
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  2835
    "Modified (comment): / 05-09-2012 / 19:43:07 / cg"
9852
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
  2836
!
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
  2837
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2838
fileNamesToGenerate
12200
7e452033e984 rememberOverwrittenExtensionMethods
Claus Gittinger <cg@exept.de>
parents: 12198
diff changeset
  2839
    "answer the files that have to be generated as a dictionary of names and generator method"
10864
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2840
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2841
    ^ self basicFileNamesToGenerate removeAllKeys:self protectedFileNames ifAbsent:[]
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2842
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2843
    "
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2844
      stx_libbasic fileNamesToGenerate
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2845
    "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2846
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2847
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  2848
forEachFileNameAndGeneratedContentsDo:aTwoArgBlock
9544
5ee38738942e *** empty log message ***
fm
parents: 9541
diff changeset
  2849
    |pairs|
5ee38738942e *** empty log message ***
fm
parents: 9541
diff changeset
  2850
5ee38738942e *** empty log message ***
fm
parents: 9541
diff changeset
  2851
    pairs := OrderedCollection new.
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  2852
    self forEachFileNameAndGeneratorMethodDo:[:fileName :generator |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2853
        |file|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2854
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2855
        file := self perform:generator.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2856
        pairs add:(Array with:fileName with:file)
9544
5ee38738942e *** empty log message ***
fm
parents: 9541
diff changeset
  2857
    ].
5ee38738942e *** empty log message ***
fm
parents: 9541
diff changeset
  2858
5ee38738942e *** empty log message ***
fm
parents: 9541
diff changeset
  2859
    pairs pairsDo:aTwoArgBlock
5ee38738942e *** empty log message ***
fm
parents: 9541
diff changeset
  2860
5ee38738942e *** empty log message ***
fm
parents: 9541
diff changeset
  2861
    "Created: / 16-08-2006 / 18:37:52 / User"
5ee38738942e *** empty log message ***
fm
parents: 9541
diff changeset
  2862
!
5ee38738942e *** empty log message ***
fm
parents: 9541
diff changeset
  2863
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  2864
forEachFileNameAndGeneratorMethodDo:aTwoArgBlock
10864
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2865
    self fileNamesToGenerate keysAndValuesDo:aTwoArgBlock
9831
02b8fd184e2b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9829
diff changeset
  2866
9898
cd3372a2eb84 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9891
diff changeset
  2867
    "Modified: / 14-09-2006 / 21:02:37 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2868
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2869
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2870
generateFile:filename
10864
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2871
    |action|
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2872
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2873
    action := self basicFileNamesToGenerate at:filename ifAbsent:[].
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2874
    action notNil ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2875
        ^ self perform:action
10864
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2876
    ].
512cd79cee0e Use dictionary to hold filename->generatorMethpd mapping
Stefan Vogel <sv@exept.de>
parents: 10849
diff changeset
  2877
    (filename = 'app.rc' or:[filename = 'lib.rc']) ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2878
        ^ self generate_packageName_dot_rc
9607
3cae5cf71c03 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9601
diff changeset
  2879
    ].
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  2880
    (filename = 'loadAll') ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2881
        ^ self generate_loadAll
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  2882
    ].
13177
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2883
    self error:('File "%1" not appropriate (not generated) for this type of project.' bindWith:filename)
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2884
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  2885
    "Modified: / 21-12-2010 / 11:01:10 / cg"
13968
03b79717bd2b comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13959
diff changeset
  2886
    "Modified (format): / 21-01-2012 / 12:31:40 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2887
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2888
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  2889
generateFile:filename in: directory
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  2890
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  2891
    | dir s |
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  2892
    dir := directory asFilename.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  2893
    dir exists ifFalse:[self error:'Directory does not exist'].
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  2894
    [
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2895
        s := ( dir / (filename asFilename baseName) ) writeStream.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2896
        s nextPutAll: (self generateFile: filename).
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  2897
    ] ensure:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2898
        s ifNotNil:[s close]
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  2899
    ]
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  2900
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  2901
    "
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2902
        stx_projects_smalltalk generateFile:'package.deps.rake' in: '/tmp'
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  2903
    "
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  2904
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  2905
    "Created: / 26-02-2011 / 10:42:58 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  2906
    "Modified: / 09-06-2011 / 14:53:01 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  2907
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  2908
11868
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2909
generateRemoveShellScriptOn:aStream
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2910
    "generate a shell script to a cvs remove of broken class filenames.
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2911
     To be called after the output of #generateRenameShellScript: has been performed"
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2912
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2913
    |firstLine|
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2914
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2915
    firstLine := true.
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2916
    self searchForClasses do:[:eachClass|
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2917
        firstLine ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2918
            aStream nextPutAll:'cvs rm -f '.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2919
            firstLine := false.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2920
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2921
        eachClass classFilename ~= (eachClass generateClassFilename, '.st') ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2922
            aStream nextPutAll:eachClass classBaseFilename; space.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2923
        ]
11868
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2924
    ].
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2925
    firstLine ifFalse:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2926
        aStream cr.
11868
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2927
    ].
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2928
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2929
    "
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2930
       stx_goodies_webServer_htmlTree generateRemoveShellScriptOn:Transcript
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2931
    "
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2932
!
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2933
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2934
generateRenameShellScriptOn:aStream
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2935
    "generate a shell script to rename broken class filenames"
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2936
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2937
    self searchForClasses do:[:eachClass|
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2938
        eachClass classFilename ~= (eachClass generateClassFilename, '.st') ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2939
            aStream nextPutAll:'cp ';
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2940
                   nextPutAll:eachClass classBaseFilename; nextPutAll:',v ';
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2941
                   nextPutAll:eachClass generateClassFilename; nextPutAll:'.st,v'; cr.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2942
        ]
11868
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2943
    ].
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2944
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2945
    "
11981
e479249ba36e Fix #generateRenameShellScriptOn:
Stefan Vogel <sv@exept.de>
parents: 11980
diff changeset
  2946
       stx_libdb generateRemoveShellScriptOn:Transcript
11868
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2947
    "
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2948
!
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2949
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  2950
generate_abbrev_dot_stc
13968
03b79717bd2b comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13959
diff changeset
  2951
   "/ for stc: provides abbreviations and namespace information
11868
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  2952
   self checkIfClassesArePresent.
10104
96bce48c03b5 some care for incomplete information bein present when
Claus Gittinger <cg@exept.de>
parents: 10103
diff changeset
  2953
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  2954
    ^ String
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2955
        streamContents:[:s |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2956
            |addEntry|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2957
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2958
            addEntry :=
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2959
                [:eachClassName |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2960
                    |cls fn wasLoaded failedToLoad numClassInstvars|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2961
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2962
                    s nextPutAll:eachClassName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2963
                    s nextPutAll:' '.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2964
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2965
                    cls := Smalltalk classNamed:eachClassName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2966
                    cls isNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2967
                        fn := self filenameForClass:eachClassName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2968
                        s nextPutAll:fn.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2969
                        s nextPutAll:' '; nextPutAll:(self package); nextPutAll:' '.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2970
                        s nextPutAll:' '; nextPutAll:'unknownCategory' storeString; nextPutAll:' '.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2971
                        s nextPutAll:' '; nextPutAll:'0'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2972
                    ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2973
                        wasLoaded := cls isLoaded.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2974
                        wasLoaded ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2975
                            failedToLoad := false.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2976
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2977
                            Error handle:[:ex |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2978
                                failedToLoad := true.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2979
                            ] do:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2980
                                ParserFlags
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2981
                                    withSTCCompilation:#never
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2982
                                    do:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2983
                                        cls autoload.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2984
                                    ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2985
                            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2986
                        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2987
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2988
                        fn := self filenameForClass:cls.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2989
                        (fn includes:Character space) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2990
                            s nextPutAll:fn storeString.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2991
                        ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2992
                            s nextPutAll:fn.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2993
                        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2994
                        s nextPutAll:' '; nextPutAll:(self package); nextPutAll:' '.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2995
                        s nextPutAll: (cls category asString storeString).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2996
                        failedToLoad ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2997
                            s nextPutAll:' 0'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2998
                        ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  2999
                            numClassInstvars := cls theMetaclass instSize - Class instSize.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3000
                            s nextPutAll:' '; nextPutAll:numClassInstvars printString.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3001
                        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3002
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3003
                        wasLoaded ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3004
                            cls unload
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3005
                        ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3006
                    ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3007
                    s cr.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3008
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3009
13968
03b79717bd2b comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13959
diff changeset
  3010
            s nextPutLine:'# automagically generated by the project definition'.
03b79717bd2b comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13959
diff changeset
  3011
            s nextPutLine:'# this file is needed for stc to be able to compile modules independently.'.
03b79717bd2b comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13959
diff changeset
  3012
            s nextPutLine:'# it provides information about a classes filename, category and especially namespace.'.
03b79717bd2b comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13959
diff changeset
  3013
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3014
            self allClassNames do:addEntry.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3015
            self namesAndAttributesIn:(self additionalClassNamesAndAttributes) do: [:nm :attr |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3016
                (attr isEmptyOrNil or:[(attr includes:#autoload) not]) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3017
                    addEntry value:nm
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3018
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3019
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3020
        ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3021
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3022
    "
13968
03b79717bd2b comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13959
diff changeset
  3023
        stx_libbasic generate_abbrev_dot_stc
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3024
        DapasXProject generate_abbrev_dot_stc
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3025
        DapasX_Datenbasis generate_abbrev_dot_stc
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3026
        bosch_dapasx_interactiver_editor generate_abbrev_dot_stc
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3027
    "
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3028
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3029
    "Created: / 09-08-2006 / 11:24:39 / fm"
13968
03b79717bd2b comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13959
diff changeset
  3030
    "Modified: / 21-01-2012 / 12:42:57 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3031
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3032
13177
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3033
generate_autopackage_default_dot_apspec
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3034
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3035
    ^self
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3036
        replaceMappings: self autopackage_default_dot_apspec_mappings
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3037
        in: self autopackage_default_dot_apspec
13177
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3038
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3039
    "
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3040
     stx_projects_smalltalk generate_autopackage_default_dot_apspec
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3041
    "
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3042
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3043
    "Created: / 21-12-2010 / 09:40:04 / cg"
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3044
!
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3045
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3046
generate_bc_dot_mak
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3047
    ^ (self
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3048
        replaceMappings: self bc_dot_mak_mappings
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3049
        in: self bc_dot_mak) asStringCollection withTabs asString
10306
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3050
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3051
    "
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3052
     DapasXProject generate_bc_dot_mak
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3053
     DapasX_Datenbasis generate_bc_dot_mak
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3054
    "
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3055
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3056
    "Modified: / 09-08-2006 / 11:46:14 / fm"
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3057
!
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3058
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3059
generate_bmake_dot_mak
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3060
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3061
    ^self replaceMappings: self bmake_dot_mak_mappings
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3062
            in: self bmake_dot_mak
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  3063
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  3064
    "Created: / 17-08-2006 / 20:03:43 / cg"
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  3065
!
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  3066
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3067
generate_builder_baseline_dot_rbspec
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3068
    ^ self replaceMappings:self builder_baseline_dot_rbspec_mappings
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3069
        in:self builder_baseline_dot_rbspec
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3070
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3071
    "
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3072
     stx_projects_smalltalk generate_builder_baseline_dot_rbspec
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3073
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3074
    "
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3075
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3076
    "Created: / 24-02-2011 / 11:38:47 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3077
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3078
14334
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  3079
generate_lccmake_dot_mak
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3080
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3081
    ^self replaceMappings: self bmake_dot_mak_mappings
14334
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  3082
            in: self lccmake_dot_mak
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  3083
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  3084
    "Created: / 03-09-2012 / 19:49:56 / cg"
11979
d2afd6b5fc01 lcc preps
Claus Gittinger <cg@exept.de>
parents: 11940
diff changeset
  3085
!
d2afd6b5fc01 lcc preps
Claus Gittinger <cg@exept.de>
parents: 11940
diff changeset
  3086
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3087
generate_loadAll
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3088
    ^ String
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3089
        streamContents:[:s |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3090
            |classNames classesLoaded classNamesUnloaded classesSorted classNamesSorted|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3091
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3092
            classNames := self compiled_classNames_common.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3093
            classesLoaded := classNames
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3094
                        collect:[:nm | Smalltalk classNamed:nm]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3095
                        thenSelect:[:cls |  cls notNil and:[cls isLoaded] ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3096
            classNamesUnloaded := classNames
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3097
                        select:[:nm |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3098
                            |cls|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3099
                            cls := Smalltalk classNamed:nm.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3100
                            cls isNil or:[cls isLoaded not]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3101
                        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3102
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3103
            classesSorted := Class classesSortedByLoadOrder:classesLoaded.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3104
            classNamesSorted := classesSorted collect:[:cls | cls name].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3105
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3106
            s nextPutAll:'"/
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3107
"/ $' , 'Header' , '$
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3108
"/
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3109
"/ loadAll-file to fileIn code for: ' , self package , '
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3110
"/
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3111
"/ Automatically generated from the ProjectDefinition.
9911
114cf30d0561 Handle (load) binary class libraryies.
Stefan Vogel <sv@exept.de>
parents: 9909
diff changeset
  3112
"/ DO NOT MODIFY THIS FILE;
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3113
"/
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3114
"/
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3115
"/ Prerequisites:
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3116
"/
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3117
"/ Smalltalk loadPackage:''module:directory''.
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3118
"/ Smalltalk loadPackage:''....''.
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3119
!!
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3120
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3121
"{ package:''' , self package, ''' }"
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3122
!!
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3123
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3124
|files|
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3125
9911
114cf30d0561 Handle (load) binary class libraryies.
Stefan Vogel <sv@exept.de>
parents: 9909
diff changeset
  3126
''loading package ' , self package ,'...'' infoPrint.
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3127
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3128
files := #(
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3129
'.
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3130
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3131
            classesSorted do:[:eachClass |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3132
                s nextPutLine:'  ''' , (self filenameForClass:eachClass), ''''.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3133
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3134
            classNamesUnloaded do:[:nm |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3135
                s nextPutLine:'  ''' , (self filenameForClass:nm), ''''.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3136
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3137
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3138
            self namesAndAttributesIn:(self additionalClassNamesAndAttributes) do:[:nm :attr |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3139
                (attr isEmptyOrNil or:[(attr includes:#autoload) not]) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3140
                    s nextPutLine:'  ''' , (self filenameForClass:nm), ''''.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3141
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3142
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3143
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3144
            self hasExtensionMethods ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3145
                s nextPutLine:'  ''extensions.st'''.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3146
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3147
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3148
            s nextPutAll:'
9911
114cf30d0561 Handle (load) binary class libraryies.
Stefan Vogel <sv@exept.de>
parents: 9909
diff changeset
  3149
).
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3150
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3151
"/ see if there is a classLibrary
9911
114cf30d0561 Handle (load) binary class libraryies.
Stefan Vogel <sv@exept.de>
parents: 9909
diff changeset
  3152
(Smalltalk fileInClassLibrary:''' , (self libraryName) , ''') ifTrue:[
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3153
    |handle loaded|
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3154
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3155
    handle := ObjectFileLoader loadedObjectHandles
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3156
                    detect:[:h | h package = ''' , self package , '''] ifNone:nil.
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3157
    handle ifNotNil:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3158
        loaded := Set new:(handle classes size).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3159
        handle classes do:[:c| c isMeta ifFalse:[loaded add:c classBaseFilename]].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3160
        files := files \ loaded.
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3161
    ].
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3162
].
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3163
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3164
"/ load files which are not in the classLibrary (all if there is none)
9911
114cf30d0561 Handle (load) binary class libraryies.
Stefan Vogel <sv@exept.de>
parents: 9909
diff changeset
  3165
files notEmpty ifTrue:[
114cf30d0561 Handle (load) binary class libraryies.
Stefan Vogel <sv@exept.de>
parents: 9909
diff changeset
  3166
  '''' infoPrintCR.
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3167
  files do:[:f |
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3168
    ''.'' infoPrint.
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3169
    f asFilename exists ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3170
        Smalltalk fileIn:f.
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3171
    ] ifFalse:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3172
        Smalltalk fileIn:(''source/'' , f)
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3173
    ]
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3174
  ].
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3175
  '' '' infoPrintCR.
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3176
].
9911
114cf30d0561 Handle (load) binary class libraryies.
Stefan Vogel <sv@exept.de>
parents: 9909
diff changeset
  3177
''done (' , self package ,').'' infoPrintCR.
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3178
'.
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3179
        ].
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3180
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3181
    "Created: / 14-09-2006 / 14:21:31 / cg"
10080
e7a9912eef18 use classBaseFilename
Claus Gittinger <cg@exept.de>
parents: 10076
diff changeset
  3182
    "Modified: / 12-10-2006 / 15:55:00 / cg"
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3183
!
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  3184
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3185
generate_make_dot_proto
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3186
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3187
    ^ (self
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3188
        replaceMappings: self make_dot_proto_mappings
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3189
        in: self make_dot_proto) asStringCollection withTabs asString
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3190
9733
ce3c5ea1d4d0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9726
diff changeset
  3191
    "
12428
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  3192
     stx_libbasic2 generate_make_dot_proto
9733
ce3c5ea1d4d0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9726
diff changeset
  3193
    "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3194
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3195
    "Modified: / 09-08-2006 / 11:31:01 / fm"
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3196
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3197
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3198
generate_make_dot_spec
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3199
    ^ (self
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3200
        replaceMappings: self make_dot_spec_mappings
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3201
        in: self make_dot_spec) asStringCollection withTabs asString
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3202
9733
ce3c5ea1d4d0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9726
diff changeset
  3203
    "
ce3c5ea1d4d0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9726
diff changeset
  3204
     DapasXProject generate_make_dot_spec
ce3c5ea1d4d0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9726
diff changeset
  3205
     DapasX_Datenbasis generate_make_dot_spec
ce3c5ea1d4d0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9726
diff changeset
  3206
     bosch_dapasx_kernel_Definition generate_make_dot_spec
ce3c5ea1d4d0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9726
diff changeset
  3207
    "
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3208
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3209
    "Modified: / 09-08-2006 / 11:31:09 / fm"
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3210
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3211
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3212
generate_makefile
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3213
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3214
    ^ (self
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3215
        replaceMappings: self makefile_mappings
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3216
        in: self makefile) asStringCollection withTabs asString
12428
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  3217
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  3218
    "
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  3219
     stx_libbasic2 generate_makefile
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  3220
    "
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  3221
!
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  3222
14345
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  3223
generate_mingwmake_dot_mak
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  3224
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  3225
    ^self replaceMappings: self bmake_dot_mak_mappings
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  3226
            in: self mingwmake_dot_mak
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  3227
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  3228
    "Created: / 05-09-2012 / 19:44:07 / cg"
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  3229
!
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  3230
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3231
generate_packageName_dot_rc
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3232
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3233
    ^self replaceMappings: self packageName_dot_rc_mappings
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3234
            in: self packageName_dot_rc
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3235
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3236
"
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3237
  bosch_dapasx_datenbasis generate_packageName_dot_rc
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3238
  bosch_dapasx_hw_schnittstellen  generate_packageName_dot_rc
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  3239
  stx_libbasic3 generate_packageName_dot_rc
9618
adc627ef4702 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9615
diff changeset
  3240
  stx_libwidg3 generate_packageName_dot_rc
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3241
  stx_libwidg3 productVersion
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3242
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3243
"
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3244
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3245
    "Modified: / 09-08-2006 / 11:31:09 / fm"
9618
adc627ef4702 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9615
diff changeset
  3246
    "Modified: / 21-08-2006 / 19:33:21 / cg"
9831
02b8fd184e2b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9829
diff changeset
  3247
!
02b8fd184e2b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9829
diff changeset
  3248
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3249
generate_package_dot_deps_dot_rake
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3250
    ^ (self replaceMappings:self package_dot_deps_dot_rake_mappings
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3251
        in:self package_dot_deps_dot_rake) asStringCollection
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3252
        withTabs asString
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3253
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3254
    "
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3255
     stx_libjava generate_dependencies_dot_rake"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3256
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3257
    "Created: / 24-02-2011 / 22:32:10 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3258
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3259
14334
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  3260
generate_tccmake_dot_mak
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  3261
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  3262
    ^self replaceMappings: self bmake_dot_mak_mappings
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  3263
            in: self tccmake_dot_mak
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  3264
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  3265
    "Created: / 03-09-2012 / 19:50:25 / cg"
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  3266
!
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  3267
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3268
generate_vc_dot_def
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3269
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3270
    ^self replaceMappings: self vc_dot_def_mappings
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3271
            in: self vc_dot_def
10306
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3272
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3273
"
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3274
  DapasXProject generate_vc_dot_def
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3275
  DapasX_Datenbasis generate_vc_dot_def
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3276
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3277
"
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3278
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3279
    "Modified: / 09-08-2006 / 11:31:21 / fm"
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3280
!
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3281
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3282
generate_vcmake_dot_mak
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3283
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3284
    ^self replaceMappings: self bmake_dot_mak_mappings
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3285
            in: self vcmake_dot_mak
11937
622f2641439d vcmake.bat generation
Claus Gittinger <cg@exept.de>
parents: 11869
diff changeset
  3286
!
622f2641439d vcmake.bat generation
Claus Gittinger <cg@exept.de>
parents: 11869
diff changeset
  3287
9852
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
  3288
protectedFileNames
13178
07e3a9bb37c8 changed: #protectedFileNames
Claus Gittinger <cg@exept.de>
parents: 13177
diff changeset
  3289
    "names of files which should NOT be generated (because they are hand-maintained)
12200
7e452033e984 rememberOverwrittenExtensionMethods
Claus Gittinger <cg@exept.de>
parents: 12198
diff changeset
  3290
     - redefine this to protect a hand-written Make.proto or other handwritten support files"
9852
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
  3291
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
  3292
    ^ #()
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
  3293
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
  3294
    "Created: / 14-09-2006 / 14:38:40 / cg"
13178
07e3a9bb37c8 changed: #protectedFileNames
Claus Gittinger <cg@exept.de>
parents: 13177
diff changeset
  3295
    "Modified: / 21-12-2010 / 11:36:46 / cg"
9852
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
  3296
!
bd0aa34cd18f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9850
diff changeset
  3297
9831
02b8fd184e2b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9829
diff changeset
  3298
rcFilename
02b8fd184e2b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9829
diff changeset
  3299
    ^ self packageName,'.rc'.
02b8fd184e2b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9829
diff changeset
  3300
02b8fd184e2b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9829
diff changeset
  3301
    "Created: / 07-09-2006 / 17:07:00 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3302
! !
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3303
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  3304
!ProjectDefinition class methodsFor:'file mappings'!
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3305
13177
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3306
autopackage_default_dot_apspec_mappings
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3307
    |mappings|
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3308
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3309
    mappings := Dictionary new.
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3310
    mappings
14339
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
  3311
        at: 'TOP' put: ( self pathToTop_unix );                 "/ unix here
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
  3312
"/        at: 'MODULE_PATH' put: ( self moduleDirectory );        "/ unix here
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3313
        at: 'DESCRIPTION' put: (self description);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3314
        at: 'PRODUCT_VERSION' put: (self productVersion);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3315
        at: 'PRODUCT_DATE' put: (self productDate);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3316
        at: 'PRODUCT_PUBLISHER' put: (self productPublisher);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3317
        at: 'PRODUCT_WEBSITE' put: (self productWebSite);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3318
        at: 'PRODUCT_INSTALLDIR' put: (self productInstallDir);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3319
        at: 'PRODUCT_TYPE' put: (self productType);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3320
        at: 'PRODUCT_LICENSE' put: (self productLicense);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3321
        at: 'PRODUCT_DESCRIPTION' put: (self productDescription);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3322
        at: 'MAINTAINER' put: (self productMaintainer);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3323
        at: 'PACKAGER' put: (self productPublisher);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3324
        yourself.
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3325
13177
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3326
    ^ mappings
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3327
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3328
    "Created: / 21-12-2010 / 09:00:49 / cg"
14339
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
  3329
    "Modified: / 05-09-2012 / 10:09:06 / cg"
13177
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3330
!
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  3331
10306
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3332
bc_dot_mak_mappings
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3333
    |d|
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3334
14337
8bb68891436c added: #common_mappings
Claus Gittinger <cg@exept.de>
parents: 14336
diff changeset
  3335
    d := self common_mappings.
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3336
    d
14339
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
  3337
        at: 'TOP' put: ( self pathToTop_win32 );                "/ win32 here
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
  3338
        at: 'MODULE_PATH' put: ( self moduleDirectory_win32 );  "/ win32 here
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3339
        at: 'PRIMARY_TARGET' put: (self primaryTarget_bc_dot_mak);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3340
        at: 'ADDITIONAL_BASE_ADDRESS_DEFINITION' put: (self additionalBaseAddressDefinition_bc_dot_mak ? '');
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3341
        at: 'ADDITIONAL_DEFINITIONS' put: (self additionalDefinitions_bc_dot_mak ? '');
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3342
        at: 'ADDITIONAL_HEADERRULES' put: (self additionalHeaderRules_bc_dot_mak);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3343
        at: 'ADDITIONAL_RULES' put: (self additionalRules_bc_dot_mak ? '');
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  3344
        at: 'ADDITIONAL_RULES_HG' put: (self additionalRulesHG_bc_dot_mak ? '');
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3345
        at: 'ADDITIONAL_TARGETS' put: (self additionalTargets_bc_dot_mak ? '');
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3346
        at: 'ADDITIONAL_LINK_LIBRARIES' put: (self additionalLinkLibraries_bc_dot_mak ? '');
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3347
        at: 'LOCAL_INCLUDES' put: (self generateLocalIncludes_win32 ? '');
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3348
        at: 'LOCAL_DEFINES' put: self localDefines_win32 ? '';
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3349
        at: 'GLOBAL_DEFINES' put: self globalDefines_win32 ? '';
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3350
        at: 'MAKE_PREREQUISITES' put: (self generateRequiredMakePrerequisites_bc_dot_mak ? '').
10306
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3351
    ^ d
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3352
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3353
    "Created: / 18-08-2006 / 11:43:39 / cg"
14339
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
  3354
    "Modified: / 05-09-2012 / 10:02:51 / cg"
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  3355
    "Modified: / 28-11-2012 / 10:15:53 / Jan Vrany <jan.vrany@fit.cvut.cz>"
10306
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3356
!
d5a7e62bd20f Rename nt.mak to bc.mak
Stefan Vogel <sv@exept.de>
parents: 10299
diff changeset
  3357
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  3358
bmake_dot_mak_mappings
14337
8bb68891436c added: #common_mappings
Claus Gittinger <cg@exept.de>
parents: 14336
diff changeset
  3359
    ^ self common_mappings
14344
b06bca5c82fa changed: #bmake_dot_mak_mappings
Claus Gittinger <cg@exept.de>
parents: 14339
diff changeset
  3360
        at:'TOP' put: ( self pathToTop_win32 );
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3361
        at:'SUBPROJECT_BMAKE_CALLS' put:(self subProjectBmakeCalls);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3362
        at:'SUBPROJECT_VCMAKE_CALLS' put:(self subProjectVCmakeCalls);
14334
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  3363
        at:'SUBPROJECT_LCCMAKE_CALLS' put:(self subProjectLCCmakeCalls);
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  3364
        at:'SUBPROJECT_TCCMAKE_CALLS' put:(self subProjectTCCmakeCalls);
14345
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  3365
        at:'SUBPROJECT_MINGWMAKE_CALLS' put:(self subProjectMingwmakeCalls);
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3366
        yourself
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  3367
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  3368
    "Created: / 17-08-2006 / 21:41:56 / cg"
14345
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  3369
    "Modified: / 05-09-2012 / 19:45:36 / cg"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  3370
!
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  3371
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3372
builder_baseline_dot_rbspec_mappings
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3373
    |mappings|
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3374
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3375
    mappings := Dictionary new.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3376
    mappings
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3377
        at:'APPLICATION' put:(self perform:#applicationName ifNotUnderstood:[self packageName]);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3378
        at:'APPLICATION_PACKAGE' put:self package printString;
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3379
        at:'PREAMBLE' put:self builder_baseline_dot_rbspec_preamble;
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3380
        at:'POSTAMBLE' put:self builder_baseline_dot_rbspec_postamble;
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3381
        at:'PACKAGES' put:self builder_baseline_dot_rbspec_packages;
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3382
        yourself.
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3383
    ^ mappings
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3384
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3385
    "Modified: / 21-12-2010 / 11:00:22 / cg"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3386
    "Created: / 24-02-2011 / 11:58:06 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3387
    "Modified: / 09-06-2011 / 14:55:31 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3388
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3389
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3390
builder_baseline_dot_rbspec_packages
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3391
    ^ String streamContents:
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3392
            [:s |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3393
            self allPreRequisitesSorted do:
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3394
                    [:packageId |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3395
                    s
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3396
                        nextPutAll:('  package "%1"' bindWith:packageId);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3397
                        cr ] ].
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3398
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3399
    "Created: / 24-02-2011 / 11:59:32 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3400
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3401
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3402
classLine_mappings:aClassName
12545
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3403
    ^ Dictionary new
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3404
        at:'CLASS' put:(self st2c:aClassName);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3405
        yourself
9962
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3406
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3407
    "Modified: / 09-08-2006 / 18:27:07 / fm"
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3408
    "Created: / 19-09-2006 / 22:47:43 / cg"
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3409
!
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3410
14337
8bb68891436c added: #common_mappings
Claus Gittinger <cg@exept.de>
parents: 14336
diff changeset
  3411
common_mappings
10299
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  3412
    ^ Dictionary new
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3413
        at: 'TAB' put: ( Character tab asString );
14339
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
  3414
        at: 'TOP' put: ( 'depends-on-file(unix vs. win32)' );       "/ must be in specific mapping
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3415
        at: 'LIBRARY_NAME' put: ( self libraryName );
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3416
        at: 'SUBDIRECTORIES' put: (self generateSubDirectories);
14337
8bb68891436c added: #common_mappings
Claus Gittinger <cg@exept.de>
parents: 14336
diff changeset
  3417
        at: 'MODULE' put: ( self module );
14339
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
  3418
        at: 'MODULE_DIRECTORY' put: ( self moduleDirectory );           "/ always unix format
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
  3419
        at: 'MODULE_PATH' put: ( 'depends-on-file(unix vs. win32)' );   "/ must be in specific mapping
14337
8bb68891436c added: #common_mappings
Claus Gittinger <cg@exept.de>
parents: 14336
diff changeset
  3420
        yourself
8bb68891436c added: #common_mappings
Claus Gittinger <cg@exept.de>
parents: 14336
diff changeset
  3421
8bb68891436c added: #common_mappings
Claus Gittinger <cg@exept.de>
parents: 14336
diff changeset
  3422
    "Created: / 04-09-2012 / 13:04:26 / cg"
8bb68891436c added: #common_mappings
Claus Gittinger <cg@exept.de>
parents: 14336
diff changeset
  3423
!
8bb68891436c added: #common_mappings
Claus Gittinger <cg@exept.de>
parents: 14336
diff changeset
  3424
8bb68891436c added: #common_mappings
Claus Gittinger <cg@exept.de>
parents: 14336
diff changeset
  3425
make_dot_proto_mappings
8bb68891436c added: #common_mappings
Claus Gittinger <cg@exept.de>
parents: 14336
diff changeset
  3426
    ^ self common_mappings
14339
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
  3427
        at: 'MODULE' put: ( self module );
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
  3428
        at: 'MODULE_DIRECTORY' put: ( self moduleDirectory );
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
  3429
        at: 'MODULE_PATH' put: ( self moduleDirectory );
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
  3430
        at: 'TOP' put: ( self pathToTop_unix );
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
  3431
        at: 'SUBDIRECTORIES' put: (self generateSubDirectories);
14337
8bb68891436c added: #common_mappings
Claus Gittinger <cg@exept.de>
parents: 14336
diff changeset
  3432
        at: 'LIBRARY_NAME' put: ( self libraryName );
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3433
        at: 'LOCAL_INCLUDES' put: (self generateLocalIncludes_unix);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3434
        at: 'LOCAL_DEFINES' put: self localDefines_unix;
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3435
        at: 'GLOBAL_DEFINES' put: self globalDefines_unix;
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3436
        at: 'COMMONSYMFLAG' put: (self commonSymbolsFlag);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3437
        at: 'HEADEROUTPUTARG' put: (self headerFileOutputArg);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3438
        at: 'PRIMARY_TARGET' put: (self primaryTarget_make_dot_proto);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3439
        at: 'ADDITIONAL_DEFINITIONS' put: (self additionalDefinitions_make_dot_proto);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3440
        at: 'ADDITIONAL_HEADERRULES' put: (self additionalHeaderRules_make_dot_proto);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3441
        at: 'ADDITIONAL_RULES' put: (self additionalRules_make_dot_proto);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3442
        at: 'ADDITIONAL_RULES_SVN' put: (self additionalRulesSvn_make_dot_proto);
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  3443
        at: 'ADDITIONAL_RULES_HG' put: (self additionalRulesHG_make_dot_proto);
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3444
        at: 'ADDITIONAL_TARGETS' put: (self additionalTargets_make_dot_proto);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3445
        at: 'ADDITIONAL_TARGETS_SVN' put: (self additionalTargetsSvn_make_dot_proto);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3446
        at: 'ADDITIONAL_LINK_LIBRARIES' put: (self additionalLinkLibraries_make_dot_proto);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3447
        at: 'ADDITIONAL_SHARED_LINK_LIBRARIES' put: (self additionalSharedLinkLibraries_make_dot_proto);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3448
        at: 'DEPENDENCIES' put: (self generateDependencies_unix);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3449
        at: 'MAKE_PREREQUISITES' put: (self generateRequiredMakePrerequisites_make_dot_proto);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3450
        yourself
10299
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  3451
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  3452
    "Created: / 09-08-2006 / 11:20:45 / fm"
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  3453
    "Modified: / 09-08-2006 / 16:44:48 / fm"
12028
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  3454
    "Modified: / 24-06-2009 / 21:50:13 / Jan Vrany <vranyj1@fel.cvut.cz>"
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  3455
    "Modified: / 22-08-2009 / 12:03:25 / Jan Vrany <jan.vrany@fit.cvut.cz>"
14339
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
  3456
    "Modified: / 05-09-2012 / 10:10:40 / cg"
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  3457
    "Modified: / 28-11-2012 / 10:07:42 / Jan Vrany <jan.vrany@fit.cvut.cz>"
10299
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  3458
!
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  3459
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  3460
make_dot_spec_mappings
14337
8bb68891436c added: #common_mappings
Claus Gittinger <cg@exept.de>
parents: 14336
diff changeset
  3461
    ^ self common_mappings
14339
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
  3462
        at: 'MODULE_DIRECTORY' put: ( self moduleDirectory );
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3463
        at: 'STCWARNINGOPTIONS' put: (self stcWarningOptions);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3464
        at: 'STCOPTIMIZATIONOPTIONS' put: (self stcOptimizationOptions);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3465
        at: 'CLASSES' put: [self generateClasses_make_dot_spec];
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3466
        at: 'OBJECTS' put: [self generateObjects_make_dot_spec];
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3467
        yourself
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  3468
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  3469
    "Created: / 18-08-2006 / 11:44:23 / cg"
14339
Claus Gittinger <cg@exept.de>
parents: 14337
diff changeset
  3470
    "Modified: / 05-09-2012 / 10:11:02 / cg"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  3471
!
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  3472
12428
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  3473
makefile_mappings
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  3474
    ^ Dictionary new
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3475
        yourself
12428
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  3476
!
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  3477
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  3478
packageName_dot_rc_mappings
11611
fa06cde6bd11 Allow for additional icon files to be placed in resources
Stefan Vogel <sv@exept.de>
parents: 11580
diff changeset
  3479
    |d s resourceCount|
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  3480
9630
526c4d537a8e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9627
diff changeset
  3481
    d := Dictionary new.
526c4d537a8e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9627
diff changeset
  3482
    d
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3483
        at: 'PRODUCT_NAME' put: (self productName);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3484
        at: 'PRODUCT_VERSION' put: (self productVersion);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3485
        at: 'PRODUCT_DATE' put: (self productDate);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3486
        at: 'FILETYPE' put: ( 'VFT_DLL' );
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3487
        at: 'FILE_VERSION_COMMASEPARATED' put: (self fileVersionCommaSeparated);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3488
        at: 'PRODUCT_VERSION_COMMASEPARATED' put: (self productVersionCommaSeparated);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3489
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3490
        at: 'COMPANY_NAME' put: (self companyName);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3491
        at: 'FILE_DESCRIPTION' put: (self fileDescription);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3492
        at: 'FILE_VERSION' put: (self fileVersion);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3493
        at: 'INTERNAL_NAME' put: (self internalName).
11377
35d261aa5493 splash file definition
Claus Gittinger <cg@exept.de>
parents: 11369
diff changeset
  3494
9630
526c4d537a8e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9627
diff changeset
  3495
    s := self legalCopyright.
526c4d537a8e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9627
diff changeset
  3496
    s notNil ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3497
        d at: 'LEGAL_COPYRIGHT_LINE' put: '      VALUE "LegalCopyright", "',s,'\0"'
9630
526c4d537a8e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9627
diff changeset
  3498
    ].
11611
fa06cde6bd11 Allow for additional icon files to be placed in resources
Stefan Vogel <sv@exept.de>
parents: 11580
diff changeset
  3499
    s := String streamContents:[:stream|
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3500
            |suff|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3501
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3502
            s := self applicationIconFileName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3503
            s notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3504
                s asFilename suffix isEmptyOrNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3505
                    suff := '.ico'
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3506
                ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3507
                    suff := ''
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3508
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3509
                'IDR_MAINFRAME           ICON    DISCARDABLE     "%1%2"'
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3510
                        expandPlaceholdersWith:(Array with:s with:suff) on:stream.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3511
                stream cr.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3512
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3513
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3514
            s := self splashFileName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3515
            s notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3516
                s asFilename suffix isEmptyOrNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3517
                    suff := '.bmp'
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3518
                ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3519
                    suff := ''
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3520
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3521
                'IDR_SPLASH           BITMAP    DISCARDABLE     "%1%2"'
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3522
                        expandPlaceholdersWith:(Array with:s with:suff) on:stream.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3523
                stream cr.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3524
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3525
            resourceCount := 2.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3526
            self applicationAdditionalIconFileNames do:[:eachFilename|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3527
                'IDR_MAINFRAME+%1           ICON    DISCARDABLE     "%2"'
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3528
                        expandPlaceholdersWith:(Array with:resourceCount with:eachFilename) on:stream.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3529
                stream cr.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3530
                resourceCount := resourceCount+1.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3531
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3532
        ].
11611
fa06cde6bd11 Allow for additional icon files to be placed in resources
Stefan Vogel <sv@exept.de>
parents: 11580
diff changeset
  3533
    d at: #'ICONDEFINITION_LINE' put:s.
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  3534
9630
526c4d537a8e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9627
diff changeset
  3535
    ^ d
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  3536
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  3537
    "Created: / 09-08-2006 / 11:21:21 / fm"
13309
27f463f6c0cb changed: #packageName_dot_rc_mappings
Claus Gittinger <cg@exept.de>
parents: 13285
diff changeset
  3538
    "Modified: / 22-02-2011 / 11:30:36 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3539
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3540
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3541
package_dot_deps_dot_rake_mappings
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  3542
    |dependencies|
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  3543
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  3544
    dependencies := String 
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  3545
            streamContents:[:s | 
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  3546
                self allPreRequisites do:[:package | 
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  3547
                    (self preRequisitesFor:package) do:[:prereq | 
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  3548
                        s
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  3549
                            nextPutAll:('task "%1" => "%2"' bindWith:package with:prereq);
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  3550
                            cr
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  3551
                    ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  3552
                    s cr
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  3553
                ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  3554
                self effectivePreRequisites do:[:prereq | 
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  3555
                    s
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  3556
                        nextPutAll:('task "%1" => "%2"' bindWith:self package with:prereq);
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  3557
                        cr
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  3558
                ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  3559
            ].
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3560
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3561
    ^ (Dictionary new)
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3562
        at:'DEPENDENCIES' put:dependencies;
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3563
        yourself
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3564
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3565
    "
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3566
        stx_libjava generate_package_dot_deps_dot_rake
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3567
    "
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3568
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3569
    "Created: / 24-02-2011 / 22:32:08 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3570
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  3571
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  3572
replaceMappings: mappings in: fileTemplate
9733
ce3c5ea1d4d0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9726
diff changeset
  3573
    "Replaces the defined variable mappings found in a file template with the corresponding information"
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  3574
9733
ce3c5ea1d4d0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9726
diff changeset
  3575
    ^ fileTemplate bindWithArguments:mappings.
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  3576
9733
ce3c5ea1d4d0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9726
diff changeset
  3577
    "
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3578
     self replaceMappings: (self nt_dot_def_mappingsFor: self) in: self nt_dot_def
9733
ce3c5ea1d4d0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9726
diff changeset
  3579
    "
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  3580
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  3581
    "Created: / 08-08-2006 / 11:44:27 / fm"
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  3582
    "Modified: / 08-08-2006 / 12:46:13 / fm"
9962
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3583
!
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3584
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3585
st2c:aString
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3586
        ^ (aString asString
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3587
            copyReplaceString:'_' withString:('_',($_ codePoint printStringRadix:8)))
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3588
                replaceAny:':' with:$_
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3589
! !
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  3590
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  3591
!ProjectDefinition class methodsFor:'file mappings support'!
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  3592
12545
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3593
classNamesByCategory
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3594
    "answer a dictionary
13728
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3595
        category -> classNames topological sorted"
12545
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3596
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3597
    |pivateClassesOf sorter classes classNames mapping|
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3598
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3599
    mapping := Dictionary new.
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3600
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3601
    classes := self compiled_classes_common.
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3602
    pivateClassesOf := IdentityDictionary new.
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3603
    classes do:[:each | pivateClassesOf at:each put:(each allPrivateClasses)].
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3604
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3605
    sorter := [:a :b |
13728
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3606
        "/ a must come before b iff:
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3607
        "/    b is a subclass of a
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3608
        "/    b has a private class which is a subclass of a
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3609
        "/    a is a sharedPool, used by b
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3610
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3611
        |mustComeBefore pivateClassesOfB|
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3612
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3613
        mustComeBefore := false.
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3614
        mustComeBefore := (a isSharedPool and:[(b sharedPoolNames includes: a name)]).
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3615
        mustComeBefore := mustComeBefore or:[b isSubclassOf:a].
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3616
        mustComeBefore ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3617
            pivateClassesOfB := pivateClassesOf at:b ifAbsent:[ #() ].
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3618
            pivateClassesOfB do:[:eachClassInB |
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3619
                mustComeBefore := mustComeBefore or:[eachClassInB isSubclassOf:a]
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3620
            ].
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3621
        ].
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3622
        mustComeBefore
12545
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3623
    ].
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3624
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3625
    classes topologicalSort:sorter.
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3626
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3627
    OperatingSystem knownPlatformNames do:[:platformID |
13728
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3628
        |prefix depClasses depClassNames|
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3629
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3630
        prefix := platformID asUppercase.
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3631
        depClasses := self compiled_classesForArchitecture:platformID.
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3632
        depClasses notEmpty ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3633
            (self compiled_classNamesForPlatform:platformID)
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3634
                select:[:nm | (Smalltalk at:nm ifAbsent:nil) isNil]
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3635
                thenDo:[:nm | Transcript showCR:nm].
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3636
            (depClasses includes:nil) ifTrue:[
13836
97abd31bbd13 changed: #classNamesByCategory
Claus Gittinger <cg@exept.de>
parents: 13823
diff changeset
  3637
                (Dialog confirm:'Dependencies (and therefore build-order) might be incorrect\(some classes are not present; see Transcript).\\Continue anyway ?' withCRs)
13728
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3638
                ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3639
                    AbortOperationRequest raise.
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3640
                ].
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3641
                depClassNames := self compiled_classNamesForPlatform:platformID.
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3642
            ] ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3643
                depClasses topologicalSort:sorter.
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3644
                depClassNames := depClasses collect:[:eachClass| eachClass name].
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3645
            ].
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3646
            mapping at:prefix put:depClassNames.
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3647
        ].
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3648
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3649
        classNames := classes collect:[:eachClass| eachClass name].
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3650
        self namesAndAttributesIn:(self additionalClassNamesAndAttributes) do: [:nm :attr |
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3651
            (attr isEmptyOrNil or:[(attr includes:#autoload) not]) ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3652
                classNames add:nm.
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3653
            ].
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3654
        ].
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3655
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  3656
        mapping at:'COMMON' put:classNames.
12545
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3657
    ].
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3658
    ^ mapping
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3659
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3660
    "
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3661
     stx_libbasic classNamesByCategory
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3662
     stx_libbasic3 classNamesByCategory
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3663
     stx_libview classNamesByCategory
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3664
    "
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3665
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3666
    "Created: / 09-08-2006 / 11:24:39 / fm"
13836
97abd31bbd13 changed: #classNamesByCategory
Claus Gittinger <cg@exept.de>
parents: 13823
diff changeset
  3667
    "Modified: / 25-11-2011 / 16:41:47 / cg"
12545
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3668
!
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3669
10299
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  3670
commonSymbolsFlag
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  3671
    "only for libraries"
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  3672
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  3673
    ^ ''
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  3674
!
af27a10749c2 add #additional_link_libraries_nt_dot_mak
Stefan Vogel <sv@exept.de>
parents: 10296
diff changeset
  3675
11868
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3676
filenameForClass:classNameOrClass
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3677
    "answer the base filename of the class without suffix"
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3678
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3679
"/    "enable this code if you want to convert old filenames to new filenames.
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3680
"/     See also: #generateRemoveShellScriptOn: and #generateRenamShellScriptOn:"
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3681
"/    classNameOrClass isBehavior ifTrue:[
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3682
"/        ^ classNameOrClass generateClassFilename.
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3683
"/    ] ifFalse:[
11868
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3684
"/        |cls|
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3685
"/
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3686
"/        cls := Smalltalk classNamed:classNameOrClass.
11868
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3687
"/        cls notNil ifTrue:[
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3688
"/            ^ cls generateClassFilename.
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3689
"/        ].
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3690
"/    ].
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3691
"/    "end special code"
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3692
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3693
    ^ Smalltalk fileNameForClass:classNameOrClass.
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3694
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3695
    "
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3696
        self filenameForClass:HTML::Encoder
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3697
        Smalltalk fileNameForClass:HTML::Encoder
11868
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3698
    "
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3699
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3700
    "Created: / 08-08-2006 / 20:17:28 / fm"
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3701
    "Modified: / 20-10-2006 / 16:22:58 / cg"
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3702
!
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  3703
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3704
generateClassLines:classLineTemplate
12771
878fc210c8e7 add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents: 12749
diff changeset
  3705
    "for the init-file: generate class-init-lines for all classes"
878fc210c8e7 add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents: 12749
diff changeset
  3706
878fc210c8e7 add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents: 12749
diff changeset
  3707
    ^ self generateClassLines:classLineTemplate forClasses:(self compiled_classNames_common)
878fc210c8e7 add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents: 12749
diff changeset
  3708
!
878fc210c8e7 add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents: 12749
diff changeset
  3709
878fc210c8e7 add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents: 12749
diff changeset
  3710
generateClassLines:classLineTemplate forClasses:classNames
878fc210c8e7 add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents: 12749
diff changeset
  3711
    "for the init-file: generate class-init-lines for a collection of classes"
878fc210c8e7 add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents: 12749
diff changeset
  3712
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3713
    ^ self generateClassLines:classLineTemplate forClasses:classNames includeAdditionalClasses:true
12804
079b692e0776 added: #generateClassLines:forClasses:includeAdditionalClasses:
sr
parents: 12771
diff changeset
  3714
!
079b692e0776 added: #generateClassLines:forClasses:includeAdditionalClasses:
sr
parents: 12771
diff changeset
  3715
079b692e0776 added: #generateClassLines:forClasses:includeAdditionalClasses:
sr
parents: 12771
diff changeset
  3716
generateClassLines:classLineTemplate forClasses:classNames includeAdditionalClasses:includeAdditionalClasses
079b692e0776 added: #generateClassLines:forClasses:includeAdditionalClasses:
sr
parents: 12771
diff changeset
  3717
    "for the init-file: generate class-init-lines for a collection of classes"
079b692e0776 added: #generateClassLines:forClasses:includeAdditionalClasses:
sr
parents: 12771
diff changeset
  3718
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3719
    ^ String
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3720
        streamContents:[:s |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3721
            |classesLoaded classNamesUnloaded classNamesSorted putLineForClassName|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3722
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3723
            putLineForClassName := [:className |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3724
                    |newClassLine mappings|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3725
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3726
                    mappings := self classLine_mappings:className.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3727
                    newClassLine := self replaceMappings:mappings in:classLineTemplate.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3728
                    s nextPutLine:newClassLine
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3729
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3730
            classesLoaded := classNames collect:[:eachClassName | Smalltalk classNamed:eachClassName]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3731
                                        thenSelect:[:eachClass | eachClass notNil and:[eachClass isLoaded]].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3732
            classNamesUnloaded := classNames
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3733
                        select:[:nm |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3734
                            |cls|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3735
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3736
                            cls := Smalltalk classNamed:nm.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3737
                            cls isNil or:[ cls isLoaded not ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3738
                        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3739
            classNamesSorted := (Class classesSortedByLoadOrder:classesLoaded) collect:[:cls | cls name].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3740
            classNamesSorted do:putLineForClassName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3741
            classNamesUnloaded do:putLineForClassName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3742
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3743
            includeAdditionalClasses ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3744
                self namesAndAttributesIn:(self additionalClassNamesAndAttributes)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3745
                    do:[:nm :attr |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3746
                        (attr isEmptyOrNil or:[ (attr includes:#autoload) not ]) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3747
                            putLineForClassName value:nm.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3748
                        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3749
                    ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3750
                #( ('UNIX' unix)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3751
                   ('WIN32' win32)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3752
                   ('VMS' vms)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3753
                   ('BEOS' beos) )
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3754
                        pairsDo:[:ifdef :platformName |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3755
                            |archClassNames archClassesLoaded|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3756
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3757
                            archClassNames := self compiled_classNamesForPlatform:platformName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3758
                            archClassNames notEmpty ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3759
                                s nextPutLine:'#ifdef ' , ifdef.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3760
                                archClassNames do:[:clsName |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3761
                                    putLineForClassName value:clsName
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3762
                                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3763
                                s nextPutLine:'#endif /* ' , ifdef , ' */'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3764
                            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3765
                        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3766
            ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3767
        ]
9962
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3768
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3769
    "
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3770
     bosch_dapasx_datenbasis  generateClassLines_libInit_dot_cc
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3771
     bosch_dapasx_kernel  generateClassLines_libInit_dot_cc
10010
69b2dbff964b *** empty log message ***
Stefan Vogel <sv@exept.de>
parents: 10007
diff changeset
  3772
     stx_libbasic3 generateClassLines_libInit_dot_cc
69b2dbff964b *** empty log message ***
Stefan Vogel <sv@exept.de>
parents: 10007
diff changeset
  3773
    "
69b2dbff964b *** empty log message ***
Stefan Vogel <sv@exept.de>
parents: 10007
diff changeset
  3774
9962
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3775
    "Modified: / 16-08-2006 / 18:52:10 / User"
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3776
    "Created: / 19-09-2006 / 22:47:50 / cg"
9979
e2e247d73233 oops - libInit forgot non-loaded, alien-OS files.
Claus Gittinger <cg@exept.de>
parents: 9972
diff changeset
  3777
    "Modified: / 20-09-2006 / 11:47:25 / cg"
9962
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3778
!
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3779
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3780
generateClassLines_libInit_dot_cc
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3781
    ^ self generateClassLines:(self classLine_libInit_dot_cc)
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3782
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3783
    "
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3784
     bosch_dapasx_datenbasis  generateClassLines_libInit_dot_cc
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3785
     bosch_dapasx_kernel  generateClassLines_libInit_dot_cc
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3786
     stx_libbasic3 generateClassLines_libInit_dot_cc
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3787
    "
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3788
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3789
    "Created: / 09-08-2006 / 11:21:48 / fm"
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3790
    "Modified: / 16-08-2006 / 18:52:10 / User"
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3791
    "Modified: / 19-09-2006 / 22:48:14 / cg"
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3792
!
905898cca08c also generate modules.c (precompiled-in init list for app)
Claus Gittinger <cg@exept.de>
parents: 9956
diff changeset
  3793
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3794
generateClasses_make_dot_spec
12545
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3795
    |classNamesDict|
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3796
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3797
    classNamesDict := self classNamesByCategory.
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3798
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3799
    ^ String streamContents:[:s |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3800
        classNamesDict keysAndValuesDo:[:eachCategory :classNames|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3801
            s nextPutLine:eachCategory,'_CLASSES= \'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3802
            classNames do:[:eachClassName|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3803
                s tab; nextPutAll:eachClassName; nextPutLine:' \'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3804
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3805
            s cr.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3806
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  3807
        s cr.
12545
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3808
    ].
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3809
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3810
    "
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3811
     stx_libbasic generateClasses_make_dot_spec
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3812
     stx_libbasic3 generateClasses_make_dot_spec
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3813
     stx_libview generateClasses_make_dot_spec
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3814
     stx_libboss generateClasses_make_dot_spec
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3815
    "
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3816
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3817
    "Created: / 09-08-2006 / 11:24:39 / fm"
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3818
    "Modified: / 20-10-2006 / 16:18:54 / cg"
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3819
!
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  3820
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3821
generateDependencies:whichArchitecture
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  3822
    ^ String
13763
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3823
        streamContents:[:s |
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3824
            |classNames classesPresent classesLoaded clsBaseName putDependencyForClassBlock
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3825
             putDependencyForClassBaseNameBlock
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3826
             archClassNames archClassesPresent archClassesLoaded
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3827
             putSingleClassDependencyEntryBlock putDependencyForExtensionsBlock|
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3828
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3829
            putSingleClassDependencyEntryBlock := [:cls |
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3830
                    |sclsBaseName|
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3831
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3832
                    s nextPutAll:' $(INCLUDE_TOP)'.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3833
                    s nextPutAll:(self pathSeparator:whichArchitecture) asString.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3834
                    sclsBaseName := self filenameForClass:cls.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3835
                    s nextPutAll:(self
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3836
                                topRelativePathTo:sclsBaseName
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3837
                                inPackage:cls package
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3838
                                architecture:whichArchitecture).
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3839
                    s nextPutAll:'.$(H)'.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3840
                ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3841
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3842
            putDependencyForClassBaseNameBlock := [:clsBaseName |
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3843
                    s nextPutAll:'$(OUTDIR)'.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3844
                    s nextPutAll:clsBaseName.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3845
                    s nextPutAll:'.$(O)'.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3846
                    s nextPutAll:' '.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3847
                    s nextPutAll:clsBaseName.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3848
                    s nextPutAll:'.$(H)'.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3849
                    s nextPutAll:': '.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3850
                    s nextPutAll:clsBaseName.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3851
                    s nextPutAll:'.st'.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3852
                ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3853
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3854
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3855
            putDependencyForClassBlock := [:cls |
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3856
                    |clsBaseName already|
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3857
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3858
                    clsBaseName := self filenameForClass:cls.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3859
                    putDependencyForClassBaseNameBlock value:clsBaseName.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3860
                    cls isLoaded ifTrue:[
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3861
                        already := IdentitySet new.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3862
                        cls
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3863
                            sharedPools do:[:poolClass |
13798
894c48237cd5 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13797
diff changeset
  3864
                                poolClass isNil ifTrue:[
894c48237cd5 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13797
diff changeset
  3865
                                    Dialog warn:'At least one pool class is missing.\\Dependencies are incomplete.' withCRs
894c48237cd5 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13797
diff changeset
  3866
                                ] ifFalse:[
894c48237cd5 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13797
diff changeset
  3867
                                    putSingleClassDependencyEntryBlock value:poolClass.
894c48237cd5 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13797
diff changeset
  3868
                                    already add:poolClass.
894c48237cd5 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13797
diff changeset
  3869
                                ]
13763
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3870
                            ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3871
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3872
                        cls
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3873
                            allSuperclassesDo:[:scls |
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3874
                                putSingleClassDependencyEntryBlock value:scls.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3875
                                already add:scls.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3876
                            ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3877
                        cls
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3878
                            allPrivateClassesDo:[:eachPrivateClass |
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3879
                                eachPrivateClass
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3880
                                    allSuperclassesDo:[:scls |
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3881
                                        |sclsBaseName|
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3882
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3883
                                        scls ~~ cls ifTrue:[
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3884
                                            scls isPrivate ifFalse:[
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3885
                                                (already includes:scls) ifFalse:[
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3886
                                                    putSingleClassDependencyEntryBlock value:scls.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3887
                                                    already add:scls.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3888
                                                ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3889
                                            ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3890
                                        ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3891
                                    ]
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3892
                            ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3893
                    ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3894
                    s nextPutLine:' $(STCHDR)'.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3895
                ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3896
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3897
            putDependencyForExtensionsBlock := [
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3898
                    |already|
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3899
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3900
                    s nextPutAll:'$(OUTDIR)extensions.$(O): extensions.st'.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3901
                    already := Set new.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3902
                    self extensionMethodNames pairWiseDo:[:className :selector |
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3903
                            |mthdCls cls|
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3904
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3905
                            ((mthdCls := Smalltalk classNamed:className) notNil
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3906
                              and:[ mthdCls isLoaded ])
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3907
                                    ifTrue:[
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3908
                                        cls := mthdCls theNonMetaclass.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3909
                                        (already includes:cls) ifFalse:[
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3910
                                            cls
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3911
                                                withAllSuperclassesDo:[:scls |
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3912
                                                    (already includes:scls) ifFalse:[
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3913
                                                        putSingleClassDependencyEntryBlock value:scls.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3914
                                                        already add:scls.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3915
                                                    ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3916
                                                ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3917
                                        ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3918
                                    ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3919
                        ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3920
                    s nextPutLine:' $(STCHDR)'.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3921
                ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3922
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3923
            classNames := self compiled_classNames_common.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3924
            classesPresent := classNames
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3925
                collect:[:className | Smalltalk classNamed:className]
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3926
                thenSelect:[:cls | cls notNil].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3927
            classesLoaded := classesPresent
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3928
                select:[:cls | cls isLoaded].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3929
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3930
            (Class classesSortedByLoadOrder:classesLoaded)
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3931
                do:putDependencyForClassBlock.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3932
            (classesPresent select:[:cls | cls isLoaded not])
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3933
                do:putDependencyForClassBlock.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3934
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3935
            self namesAndAttributesIn:(self additionalClassNamesAndAttributes)
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3936
                do:[:className :attr |
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3937
                    |cls|
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3938
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3939
                    (attr isEmptyOrNil or:[ (attr includes:#autoload) not ]) ifTrue:[
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3940
                        ((cls := Smalltalk classNamed:className) notNil) ifTrue:[
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3941
                            putDependencyForClassBlock value:cls.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3942
                        ]
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3943
                    ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3944
                ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3945
            archClassNames := self compiled_classNamesForPlatform:whichArchitecture.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3946
            archClassesPresent := archClassNames
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3947
                collect:[:className | Smalltalk classNamed:className]
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3948
                thenSelect:[:cls | cls notNil].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3949
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3950
            archClassesLoaded := archClassesPresent
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3951
                select:[:cls | cls isLoaded].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3952
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3953
            (Class classesSortedByLoadOrder:archClassesLoaded)
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3954
                do:putDependencyForClassBlock.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3955
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3956
            "some classes are not loaded - probably this is the wrong architecture.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3957
             Sorry, but for these classes, we do not know the superclass chain"
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3958
            archClassesPresent
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3959
                select:[:cls | cls isLoaded not]
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3960
                thenDo:putDependencyForClassBlock.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3961
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3962
            "for the following classes, we do not know the superclass chain
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3963
             and neither the real class file name"
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3964
            archClassNames
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3965
                select:[:eachClassName | (Smalltalk classNamed:eachClassName) isNil]
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3966
                thenDo:[:eachClassName |
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3967
                    putDependencyForClassBaseNameBlock value:(self filenameForClass:eachClassName).
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3968
                    s nextPutLine:' $(STCHDR)'.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3969
                ].
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3970
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3971
            self hasExtensionMethods ifTrue:putDependencyForExtensionsBlock.
560aef322c65 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13734
diff changeset
  3972
        ]
9887
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3973
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3974
    "
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3975
     stx_libbasic3 generateDependencies:#unix
10010
69b2dbff964b *** empty log message ***
Stefan Vogel <sv@exept.de>
parents: 10007
diff changeset
  3976
     stx_libbasic3 generateDependencies:#win32
69b2dbff964b *** empty log message ***
Stefan Vogel <sv@exept.de>
parents: 10007
diff changeset
  3977
    "
69b2dbff964b *** empty log message ***
Stefan Vogel <sv@exept.de>
parents: 10007
diff changeset
  3978
9887
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3979
    "Created: / 14-09-2006 / 12:38:57 / cg"
13798
894c48237cd5 changed: #generateDependencies:
Claus Gittinger <cg@exept.de>
parents: 13797
diff changeset
  3980
    "Modified: / 27-10-2011 / 16:35:59 / cg"
9887
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3981
!
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3982
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3983
generateDependencies_unix
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3984
    ^ self generateDependencies:#unix
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3985
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3986
    "
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3987
     stx_libbasic3 generateDependencies:#unix
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3988
     stx_libbasic3 generateDependencies:#win32
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3989
    "
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3990
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3991
    "Modified: / 14-09-2006 / 13:32:34 / cg"
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3992
!
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3993
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3994
generateDependencies_win32
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3995
    ^ self generateDependencies:#win32
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3996
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3997
    "Created: / 14-09-2006 / 12:39:18 / cg"
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3998
!
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  3999
9956
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  4000
generateLocalIncludes_unix
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  4001
    ^ String streamContents:[:s |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4002
        s nextPutAll:(self localIncludes_unix).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4003
        self searchForProjectsWhichProvideHeaderFiles
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4004
            do:[:includeProject |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4005
                s nextPutAll:' -I$(INCLUDE_TOP)/',(self topRelativePathToPackage_unix: includeProject)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4006
            ]
9956
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  4007
    ]
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  4008
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  4009
    "
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  4010
     bosch_dapasx generateLocalIncludes_unix
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4011
     bosch_dapasx_datenbasis generateLocalIncludes_unix
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4012
     stx_libbasic generateLocalIncludes_unix
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4013
     stx_libview generateLocalIncludes_unix
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4014
     stx_libtool2 generateLocalIncludes_unix
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4015
     stx_libui generateLocalIncludes_unix
9956
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  4016
    "
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  4017
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  4018
    "Created: / 09-08-2006 / 16:46:49 / fm"
10251
653b5d0a7713 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10232
diff changeset
  4019
    "Modified: / 07-12-2006 / 17:47:06 / cg"
9956
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  4020
!
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  4021
9887
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  4022
generateLocalIncludes_win32
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  4023
    ^ String streamContents:[:s |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4024
        s nextPutAll:(self localIncludes_win32).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4025
        self searchForProjectsWhichProvideHeaderFiles
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4026
            do:[:includeProject |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4027
                s nextPutAll:' -I$(INCLUDE_TOP)\',(self topRelativePathToPackage_win32: includeProject)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4028
            ]
9887
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  4029
    ]
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  4030
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  4031
    "
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  4032
     bosch_dapasx_application generateLocalIncludes_win32
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4033
     bosch_dapasx_datenbasis generateLocalIncludes_win32
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4034
     stx_libbasic generateLocalIncludes_win32
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4035
     stx_libview generateLocalIncludes_win32
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4036
     stx_libtool2 generateLocalIncludes_win32
9887
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  4037
    "
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  4038
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  4039
    "Created: / 09-08-2006 / 16:46:49 / fm"
10251
653b5d0a7713 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10232
diff changeset
  4040
    "Modified: / 07-12-2006 / 17:47:10 / cg"
9887
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  4041
!
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  4042
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4043
generateObjects_make_dot_spec
12545
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  4044
    |classNamesDict|
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  4045
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  4046
    classNamesDict := self classNamesByCategory.
9883
c641767d1483 include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents: 9880
diff changeset
  4047
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  4048
    ^ String streamContents:[:s |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4049
        |putLineForClassName|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4050
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4051
        putLineForClassName :=
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4052
            [:eachClassName |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4053
                |mappings newObjectLine|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4054
                mappings := self objectLine_make_dot_spec_mappings: eachClassName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4055
                newObjectLine := self replaceMappings: mappings in: self objectLine_make_dot_spec.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4056
                s nextPutLine:newObjectLine.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4057
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4058
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4059
        classNamesDict keysAndValuesDo:[:eachCategory :classNames|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4060
            s nextPutLine:eachCategory,'_OBJS= \'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4061
            classNames do:putLineForClassName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4062
            (eachCategory = 'COMMON' and:[self hasExtensionMethods]) ifTrue:[
14643
11cc29aea34c class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14642
diff changeset
  4063
                s nextPutLine:'    $(OUTDIR_SLASH)extensions.$(O) \'.
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4064
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4065
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4066
            s cr.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4067
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4068
        s cr.
12545
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  4069
    ].
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  4070
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  4071
    "
12545
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  4072
     stx_libbasic generateObjects_make_dot_spec
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  4073
     stx_libbasic3 generateObjects_make_dot_spec
12545
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  4074
     stx_libview generateObjects_make_dot_spec
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  4075
     stx_libboss generateObjects_make_dot_spec
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  4076
    "
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  4077
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  4078
    "Created: / 09-08-2006 / 11:24:39 / fm"
10103
f63f419f9e27 some care for incomplete information bein present when
Claus Gittinger <cg@exept.de>
parents: 10086
diff changeset
  4079
    "Modified: / 20-10-2006 / 16:18:54 / cg"
9887
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  4080
!
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  4081
11157
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4082
generateRequiredMakePrerequisites_bc_dot_mak
11380
ac50ce4321b5 Fix prerequisite makes (pushd)
Stefan Vogel <sv@exept.de>
parents: 11377
diff changeset
  4083
    |myProjectId|
11157
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4084
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4085
    ^ String streamContents:[:s |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4086
        myProjectId := self package.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4087
        "Note: the trailing blank in 'CFLAGS_LOCAL=$(GLOBALDEFINES) '
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4088
         is required!!
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4089
         Use 'pushd' instead of 'cd', since cd is executed by borland make directly.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4090
         'popd' is not needed, since each line is executed in
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4091
                an own cmd.exe process.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4092
         'popd' is not desireable, since it masks a possible
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4093
                error return from the 'bmake'.
14547
985d895bdb58 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14521
diff changeset
  4094
        "
985d895bdb58 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14521
diff changeset
  4095
985d895bdb58 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14521
diff changeset
  4096
        "cg: changed to not go and remake librun"
985d895bdb58 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14521
diff changeset
  4097
        (self allPreRequisitesSorted "copyWith:'stx:librun'") do:[:eachProjectId |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4098
            s tab; nextPutAll:'pushd ';
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4099
                   nextPutAll:(self msdosPathToPackage:eachProjectId from:myProjectId);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4100
                   nextPutLine:' & $(MAKE_BAT) "CFLAGS_LOCAL=$(GLOBALDEFINES) "'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4101
        ].
11157
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4102
    ].
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4103
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4104
    "
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4105
     exept_expecco_application generateRequiredMakePrerequisites_bc_dot_mak
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4106
     alspa_batch_application generateRequiredMakePrerequisites_bc_dot_mak
11157
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4107
    "
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4108
!
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4109
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4110
generateRequiredMakePrerequisites_make_dot_proto
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4111
    |libPath|
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4112
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4113
    ^ String streamContents:[:s |
14547
985d895bdb58 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14521
diff changeset
  4114
        "cg: changed to not go and remake librun"
985d895bdb58 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14521
diff changeset
  4115
        (self allPreRequisitesSorted "copyWith:'stx:librun'") do:[:projectID |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4116
            libPath := self pathToPackage_unix:projectID.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4117
            s tab; nextPutAll: 'cd ', libPath; nextPutLine:' && $(MAKE) "CFLAGS_LOCAL=$(GLOBALDEFINES)"'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4118
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4119
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4120
        s cr.
11157
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4121
    ].
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4122
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4123
    "
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4124
     exept_expecco_application generateRequiredMakePrerequisites_make_dot_proto
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4125
     alspa_batch_application generateRequiredMakePrerequisites_make_dot_proto
11157
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4126
    "
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4127
!
5bef68f784c7 prereq rule also for libraries
Claus Gittinger <cg@exept.de>
parents: 11152
diff changeset
  4128
10022
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4129
generateSubDirectories
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4130
    ^ String streamContents:[:s |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4131
        self subProjects
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4132
            do:[:eachProjectID |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4133
                s space; nextPutAll:(self unixPathToPackage:eachProjectID from:self package)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4134
            ]
10022
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4135
    ]
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4136
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4137
    "
10380
ff1cfee6130b Fix subproject incluseion in Make.proto
Stefan Vogel <sv@exept.de>
parents: 10369
diff changeset
  4138
     exept_expecco generateSubDirectories
10022
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4139
    "
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4140
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4141
    "Created: / 09-08-2006 / 11:26:59 / fm"
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4142
    "Modified: / 14-09-2006 / 18:46:18 / cg"
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4143
!
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4144
12771
878fc210c8e7 add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents: 12749
diff changeset
  4145
generate_definitionClassLine_libInit_dot_cc
878fc210c8e7 add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents: 12749
diff changeset
  4146
    "for the init-file: generate a single class-init-line for the definition class itself"
878fc210c8e7 add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents: 12749
diff changeset
  4147
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4148
    ^ self
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4149
        generateClassLines:(self classLine_libInit_dot_cc)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4150
        forClasses:(Array with:self name)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4151
        includeAdditionalClasses:false
12804
079b692e0776 added: #generateClassLines:forClasses:includeAdditionalClasses:
sr
parents: 12771
diff changeset
  4152
079b692e0776 added: #generateClassLines:forClasses:includeAdditionalClasses:
sr
parents: 12771
diff changeset
  4153
    "
079b692e0776 added: #generateClassLines:forClasses:includeAdditionalClasses:
sr
parents: 12771
diff changeset
  4154
     stx_libbasic generate_definitionClassLine_libInit_dot_cc
12771
878fc210c8e7 add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents: 12749
diff changeset
  4155
    "
878fc210c8e7 add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents: 12749
diff changeset
  4156
!
878fc210c8e7 add an extra entry to the libInit.cc code:
Claus Gittinger <cg@exept.de>
parents: 12749
diff changeset
  4157
10022
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4158
headerFileOutputArg
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4159
"/    "all stx stuff goes to the common include directory.
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4160
"/     Everything else is left locally"
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4161
"/
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4162
"/    (
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4163
"/        #(
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4164
"/            'stx:libbasic'        'stx:libview'         'stx:libtool'
10022
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4165
"/            'stx:libbasic2'       'stx:libview2'        'stx:libtool2'
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4166
"/            'stx:libbasic3'       'stx:libwidg'         'stx:libhtml'
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4167
"/            'stx:libcomp'         'stx:libwidg2'        'stx:libui'
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4168
"/            'stx:libboss'         'stx:libdb'
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4169
"/        )
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4170
"/    includes:self package) ifTrue:[
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4171
"/        ^ '-H$(INCLUDE)'
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4172
"/    ].
13875
2e01d09fa4c4 -headerDir= instead of --headerDir=
Claus Gittinger <cg@exept.de>
parents: 13873
diff changeset
  4173
    ^ '-headerDir=.'
10022
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4174
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4175
    "Created: / 18-08-2006 / 13:01:52 / cg"
13875
2e01d09fa4c4 -headerDir= instead of --headerDir=
Claus Gittinger <cg@exept.de>
parents: 13873
diff changeset
  4176
    "Modified: / 23-12-2011 / 15:07:27 / cg"
10022
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4177
!
e0df2092b978 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10013
diff changeset
  4178
11868
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4179
objectLine_make_dot_spec_mappings: aClassName
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4180
    ^ Dictionary new
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4181
        at: 'CLASSFILE' put:(self filenameForClass:aClassName);
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4182
        yourself
11868
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4183
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4184
    "Created: / 08-08-2006 / 20:17:28 / fm"
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4185
    "Modified: / 09-08-2006 / 18:26:52 / fm"
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4186
    "Modified: / 20-10-2006 / 16:22:58 / cg"
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4187
!
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4188
9887
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  4189
subProjectBmakeCalls
12439
c0cf51f2bf67 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12438
diff changeset
  4190
    "generate submake-calls for borland bcc"
c0cf51f2bf67 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12438
diff changeset
  4191
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4192
    ^ self subProjectMakeCallsUsing:'call bmake %1 %2'.
12438
26bbeae51816 added: #subProjectMakeCallsUsing:
Claus Gittinger <cg@exept.de>
parents: 12428
diff changeset
  4193
!
26bbeae51816 added: #subProjectMakeCallsUsing:
Claus Gittinger <cg@exept.de>
parents: 12428
diff changeset
  4194
14334
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4195
subProjectLCCmakeCalls
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4196
    "generate submake-calls for lcc"
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4197
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4198
    ^ self subProjectMakeCallsUsing:'call lccmake %1 %2'.
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4199
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4200
    "Created: / 03-09-2012 / 19:49:08 / cg"
12438
26bbeae51816 added: #subProjectMakeCallsUsing:
Claus Gittinger <cg@exept.de>
parents: 12428
diff changeset
  4201
!
26bbeae51816 added: #subProjectMakeCallsUsing:
Claus Gittinger <cg@exept.de>
parents: 12428
diff changeset
  4202
26bbeae51816 added: #subProjectMakeCallsUsing:
Claus Gittinger <cg@exept.de>
parents: 12428
diff changeset
  4203
subProjectMakeCallsUsing:callString
9887
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  4204
    ^ String streamContents:[:s |
13734
e4a151f35857 changed: #bc_dot_mak
Claus Gittinger <cg@exept.de>
parents: 13728
diff changeset
  4205
        self subProjects do:[:packageID |
e4a151f35857 changed: #bc_dot_mak
Claus Gittinger <cg@exept.de>
parents: 13728
diff changeset
  4206
            s nextPutLine:'@echo "***********************************"'.
e4a151f35857 changed: #bc_dot_mak
Claus Gittinger <cg@exept.de>
parents: 13728
diff changeset
  4207
            s nextPutLine:'@echo "Buildung ',(packageID copyReplaceAll:$: with:$/).
e4a151f35857 changed: #bc_dot_mak
Claus Gittinger <cg@exept.de>
parents: 13728
diff changeset
  4208
            s nextPutLine:'@echo "***********************************"'.
e4a151f35857 changed: #bc_dot_mak
Claus Gittinger <cg@exept.de>
parents: 13728
diff changeset
  4209
            s nextPutLine:'@cd ', (self msdosPathToPackage:packageID from:(self package)).
e4a151f35857 changed: #bc_dot_mak
Claus Gittinger <cg@exept.de>
parents: 13728
diff changeset
  4210
            s nextPutAll:'@'; nextPutLine:callString.
e4a151f35857 changed: #bc_dot_mak
Claus Gittinger <cg@exept.de>
parents: 13728
diff changeset
  4211
            s nextPutLine:'@cd ', (self msdosPathToPackage:(self package) from:packageID).
e4a151f35857 changed: #bc_dot_mak
Claus Gittinger <cg@exept.de>
parents: 13728
diff changeset
  4212
            s cr.
e4a151f35857 changed: #bc_dot_mak
Claus Gittinger <cg@exept.de>
parents: 13728
diff changeset
  4213
        ]
9887
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  4214
    ]
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  4215
5c0c2a62ad2d *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9883
diff changeset
  4216
    "Created: / 14-09-2006 / 18:40:09 / cg"
13734
e4a151f35857 changed: #bc_dot_mak
Claus Gittinger <cg@exept.de>
parents: 13728
diff changeset
  4217
    "Modified: / 27-09-2011 / 19:36:12 / cg"
11937
622f2641439d vcmake.bat generation
Claus Gittinger <cg@exept.de>
parents: 11869
diff changeset
  4218
!
622f2641439d vcmake.bat generation
Claus Gittinger <cg@exept.de>
parents: 11869
diff changeset
  4219
14345
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4220
subProjectMingwmakeCalls
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4221
    "generate submake-calls for mingw"
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4222
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4223
    ^ self subProjectMakeCallsUsing:'call mingwmake %1 %2'.
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4224
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4225
    "Created: / 05-09-2012 / 19:45:53 / cg"
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4226
!
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4227
14334
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4228
subProjectTCCmakeCalls
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4229
    "generate submake-calls for tcc"
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4230
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4231
    ^ self subProjectMakeCallsUsing:'call tccmake %1 %2'.
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4232
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4233
    "Created: / 03-09-2012 / 19:50:53 / cg"
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4234
!
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4235
11937
622f2641439d vcmake.bat generation
Claus Gittinger <cg@exept.de>
parents: 11869
diff changeset
  4236
subProjectVCmakeCalls
12439
c0cf51f2bf67 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12438
diff changeset
  4237
    "generate submake-calls for visual-C"
c0cf51f2bf67 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12438
diff changeset
  4238
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4239
    ^ self subProjectMakeCallsUsing:'call vcmake %1 %2'.
9817
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  4240
! !
619b43f937c9 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9803
diff changeset
  4241
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4242
!ProjectDefinition class methodsFor:'file templates'!
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4243
13177
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4244
autopackage_default_dot_apspec
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4245
    "for linux's autopackage"
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4246
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4247
^
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4248
'# -*- shell-script -*-
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4249
[Meta]
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4250
ShortName: %(APPLICATION)
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4251
SoftwareVersion: %(PRODUCT_VERSION)
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4252
DisplayName: %(DESCRIPTION)
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4253
RootName: @exept.de/expecco:$SOFTWAREVERSION
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4254
Summary: %(DESCRIPTION)
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4255
Maintainer: %(MAINTAINER)
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4256
Packager: %(PACKAGER)
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4257
PackageVersion: 1
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4258
CPUArchitectures: x86
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4259
AutopackageTarget: 1.0
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4260
Type: %(PRODUCT_TYPE)
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4261
License: %(PRODUCT_LICENSE)
13177
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4262
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4263
[Description]
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4264
%(PRODUCT_DESCRIPTION)
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4265
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4266
[BuildPrepare]
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4267
# If you''re using autotools, the default should be enough.
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4268
# prepareBuild will set up apbuild and run configure for you. If you
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4269
# need to pass arguments to configure, just add them to prepareBuild:
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4270
# prepareBuild --enable-foo --disable-bar
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4271
#prepareBuild
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4272
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4273
[BuildUnprepare]
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4274
# If you''re using prepareBuild above, there is no need to change this!!
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4275
#unprepareBuild
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4276
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4277
[Globals]
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4278
# Variables declared in this section will be available in all other sections
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4279
export APKG_BUILD_SKIP_CONFIGURE=1
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4280
export APKG_BUILD_SKIP_MAKE=1
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4281
export MYPREFIX=/opt/%(APPLICATION)
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4282
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4283
[Prepare]
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4284
#recommend ''@autopackage.org/autopackage-gtk'' 1
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4285
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4286
[Imports]
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4287
import <<EOF
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4288
$source_dir/%(APPLICATION)
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4289
$source_dir/resources
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4290
$source_dir/keyboard.rc
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4291
$source_dir/display.rc
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4292
$source_dir/../doc
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4293
$source_dir/../testsuites/webedition
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4294
$source_dir/../projects/libraries
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4295
$source_dir/../reportGenerator/tools
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4296
$source_dir/../../pdf/afm
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4297
$source_dir/../plugin/selenium/libexept_expecco_plugin_selenium.so
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4298
$source_dir/../externalTools
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4299
EOF
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4300
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4301
for i in $source_dir/*.so
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4302
do
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4303
    echo $source_dir/$(readlink $i)
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4304
done | import
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4305
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4306
[Install]
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4307
if [ "$PREFIX" !!= "/usr" ]
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4308
then
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4309
    export MYPREFIX=$PREFIX
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4310
fi
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4311
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4312
find . -type d \( -name CVS -or -name ''not_*'' \) -print | xargs rm -rf
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4313
mkdir -p $MYPREFIX
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4314
copyFiles expecco *.rc resources        $MYPREFIX/bin
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4315
copyFiles *.so                          $MYPREFIX/lib
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4316
copyFiles doc externalTools             $MYPREFIX/packages/exept/expecco
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4317
copyFiles webedition/projects libraries $MYPREFIX/testsuites
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4318
copyFiles tools                         $MYPREFIX/packages/exept/expecco/reportGenerator
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4319
copyFiles afm                           $MYPREFIX/packages/exept/pdf
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4320
copyFiles libexept_expecco_plugin_selenium.so   $MYPREFIX/plugin
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4321
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4322
#installExe expecco
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4323
#installLib *.so
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4324
#installData resources
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4325
#installData keyboard.rc
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4326
#installData doc
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4327
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4328
[Uninstall]
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4329
# Leaving this at the default is safe unless you use custom commands in
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4330
# "Install" to create files. All autopackage API functions
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4331
# that installs files are logged.
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4332
uninstallFromLog
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4333
'
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4334
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4335
    "Created: / 21-12-2010 / 09:06:21 / cg"
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4336
!
f7bebd737d65 added:10 methods
Claus Gittinger <cg@exept.de>
parents: 13171
diff changeset
  4337
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4338
bc_dot_mak
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4339
    "answer a template for the bc.mak makefile.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4340
     Any variable definition %(Variable) will be later replaced by the mapping.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4341
     $% characters have to be duplicated.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4342
     Only needed for WIN"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4343
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4344
    ^ self subclassResponsibility
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4345
!
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4346
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4347
bmake_dot_mak
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4348
    "the template code for the bmake.bat file"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4349
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4350
    ^
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4351
'@REM -------
14336
da3a54f80c09 changed:
Claus Gittinger <cg@exept.de>
parents: 14334
diff changeset
  4352
@REM make using Borland bcc32
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4353
@REM type bmake, and wait...
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4354
@REM do not edit - automatically generated from ProjectDefinition
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4355
@REM -------
13797
f191b8d50bd3 changed:
Stefan Vogel <sv@exept.de>
parents: 13789
diff changeset
  4356
make.exe -N -f bc.mak %%*
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4357
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4358
%(SUBPROJECT_BMAKE_CALLS)
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4359
'
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4360
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4361
    "Created: / 17-08-2006 / 20:04:14 / cg"
14336
da3a54f80c09 changed:
Claus Gittinger <cg@exept.de>
parents: 14334
diff changeset
  4362
    "Modified: / 04-09-2012 / 11:46:22 / cg"
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4363
!
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4364
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4365
builder_baseline_dot_rbspec
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4366
    "For rake-base automatic builder"
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4367
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4368
    ^ '
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4369
# generated from project definition
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4370
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4371
# load package dependencies
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4372
load ''package.deps.rake''
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4373
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4374
# kludge: clear some invalid dependencies of libwidg
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4375
# (should be fixed in baseline)
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4376
clear "stx:libwidg" => "stx:libui"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4377
clear "stx:libwidg2" => "stx:libui"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4378
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4379
project :''%(APPLICATION):baseline'' do
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4380
  # preamble
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4381
  %(PREAMBLE)
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4382
  # --------
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4383
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4384
%(PACKAGES)
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4385
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4386
  application "%(APPLICATION_PACKAGE)"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4387
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4388
  # postamble
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4389
  %(POSTABLE)
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4390
  # ---------
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4391
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4392
end
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4393
'
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4394
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4395
    "Created: / 24-02-2011 / 11:39:00 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4396
    "Modified: / 27-02-2011 / 12:42:04 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4397
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4398
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4399
builder_baseline_dot_rbspec_postamble
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4400
    ^ ''
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4401
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4402
    "Created: / 24-02-2011 / 11:58:06 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4403
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4404
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4405
builder_baseline_dot_rbspec_preamble
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4406
    ^ ''
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4407
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4408
    "Created: / 24-02-2011 / 11:58:05 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4409
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4410
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4411
classLine_libInit_dot_cc
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4412
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4413
^'_%(CLASS)_Init(pass,__pRT__,snd);'
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4414
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4415
    "Created: / 08-08-2006 / 12:51:44 / fm"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4416
    "Modified: / 08-08-2006 / 15:46:05 / fm"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4417
!
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4418
14334
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4419
lccmake_dot_mak
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4420
    "the template code for the lccmake.bat file"
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4421
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4422
    ^
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4423
'@REM -------
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4424
@REM make using lcc compiler
14334
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4425
@REM type lccmake, and wait...
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4426
@REM do not edit - automatically generated from ProjectDefinition
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4427
@REM -------
14361
0e832917e039 changed:
Claus Gittinger <cg@exept.de>
parents: 14354
diff changeset
  4428
make.exe -N -f bc.mak -DUSELCC=1 %%*
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4429
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4430
%(SUBPROJECT_LCCMAKE_CALLS)
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4431
'
14334
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4432
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4433
    "Created: / 03-09-2012 / 19:49:23 / cg"
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4434
!
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4435
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4436
make_dot_proto
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4437
    "the template code for the make.proto file"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4438
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4439
    ^ self subclassResponsibility
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4440
!
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4441
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4442
make_dot_spec
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4443
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4444
^
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4445
'# $','Header','$
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4446
#
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4447
# DO NOT EDIT
14248
fe9da09afe27 changed: #make_dot_spec
Claus Gittinger <cg@exept.de>
parents: 14233
diff changeset
  4448
# automagically generated from the projectDefinition: ',self name,"' at ',Timestamp now printString,"'.
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4449
#
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4450
# Warning: once you modify this file, do not rerun
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4451
# stmkmp or projectDefinition-build again - otherwise, your changes are lost.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4452
#
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4453
# This file contains specifications which are common to all platforms.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4454
#
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4455
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4456
# Do NOT CHANGE THESE DEFINITIONS
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4457
# (otherwise, ST/X will have a hard time to find out the packages location from its packageID,
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4458
#  to find the source code of a class and to find the library for a package)
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4459
MODULE=%(MODULE)
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4460
MODULE_DIR=%(MODULE_DIRECTORY)
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4461
PACKAGE=$(MODULE):$(MODULE_DIR)
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4462
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4463
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4464
# Argument(s) to the stc compiler (stc --usage).
13875
2e01d09fa4c4 -headerDir= instead of --headerDir=
Claus Gittinger <cg@exept.de>
parents: 13873
diff changeset
  4465
#  -headerDir=. : create header files locally
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4466
#                (if removed, they will be created as common
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4467
#  -Pxxx       : defines the package
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4468
#  -Zxxx       : a prefix for variables within the classLib
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4469
#  -Dxxx       : defines passed to to CC for inline C-code
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4470
#  -Ixxx       : include path passed to CC for inline C-code
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4471
#  +optspace   : optimized for space
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4472
#  +optspace2  : optimized more for space
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4473
#  +optspace3  : optimized even more for space
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4474
#  +optinline  : generate inline code for some ST constructs
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4475
#  +inlineNew  : additionally inline new
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4476
#  +inlineMath : additionally inline some floatPnt math stuff
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4477
#
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4478
# ********** OPTIONAL: MODIFY the next line(s) ***
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4479
# STCLOCALOPTIMIZATIONS=+optinline +inlineNew
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4480
# STCLOCALOPTIMIZATIONS=+optspace3
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4481
STCLOCALOPTIMIZATIONS=%(STCOPTIMIZATIONOPTIONS)
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4482
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4483
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4484
# Argument(s) to the stc compiler (stc --usage).
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4485
#  -warn            : no warnings
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4486
#  -warnNonStandard : no warnings about ST/X extensions
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4487
#  -warnEOLComments : no warnings about EOL comment extension
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4488
#  -warnPrivacy     : no warnings about privateClass extension
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4489
#
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4490
# ********** OPTIONAL: MODIFY the next line(s) ***
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4491
# STCWARNINGS=-warn
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4492
# STCWARNINGS=-warnNonStandard
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4493
# STCWARNINGS=-warnEOLComments
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4494
STCWARNINGS=%(STCWARNINGOPTIONS)
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4495
12545
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  4496
%(CLASSES)
Stefan Vogel <sv@exept.de>
parents: 12541
diff changeset
  4497
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4498
%(OBJECTS)
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4499
'
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4500
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4501
    "Created: / 08-08-2006 / 19:31:29 / fm"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4502
    "Modified: / 09-08-2006 / 15:10:57 / fm"
14248
fe9da09afe27 changed: #make_dot_spec
Claus Gittinger <cg@exept.de>
parents: 14233
diff changeset
  4503
    "Modified: / 26-07-2012 / 00:56:03 / cg"
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4504
!
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4505
12428
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  4506
makefile
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4507
^
12428
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  4508
'#
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4509
# DO NOT EDIT
12428
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  4510
#
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4511
# make uses this file (Makefile) only, if there is no
12428
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  4512
# file named "makefile" (lower-case m) in the same directory.
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  4513
# My only task is to generate the real makefile and call make again.
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  4514
# Thereafter, I am no longer used and needed.
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  4515
#
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  4516
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  4517
.PHONY: run
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  4518
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  4519
run: makefile
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4520
        $(MAKE) -f makefile
12428
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  4521
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  4522
#only needed for the definition of $(TOP)
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  4523
include Make.proto
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  4524
14665
fe2327c6d20b class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14646
diff changeset
  4525
makefile: mf
fe2327c6d20b class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14646
diff changeset
  4526
fe2327c6d20b class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14646
diff changeset
  4527
mf:
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4528
        $(TOP)/rules/stmkmf
12428
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  4529
'
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  4530
!
Claus Gittinger <cg@exept.de>
parents: 12425
diff changeset
  4531
14345
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4532
mingwmake_dot_mak
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4533
    "the template code for the mingwmake.bat file"
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4534
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4535
    ^
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4536
'@REM -------
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4537
@REM make using mingw gnu compiler
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4538
@REM type mingwmake, and wait...
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4539
@REM do not edit - automatically generated from ProjectDefinition
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4540
@REM -------
14642
415f684f8808 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14586
diff changeset
  4541
14850
fbe2fa085a67 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14843
diff changeset
  4542
@pushd %(TOP)\rules
fbe2fa085a67 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14843
diff changeset
  4543
@call find_mingw.bat
fbe2fa085a67 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14843
diff changeset
  4544
@popd
14748
0e41cb05b3a5 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14738
diff changeset
  4545
make.exe -N -f bc.mak %%USEMINGW_ARG%% %%*
14345
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4546
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4547
%(SUBPROJECT_MINGWMAKE_CALLS)
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4548
'
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4549
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4550
    "Created: / 05-09-2012 / 19:44:51 / cg"
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4551
!
c94f3cfd278a mingw support
Claus Gittinger <cg@exept.de>
parents: 14344
diff changeset
  4552
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4553
objectLine_make_dot_spec
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4554
14643
11cc29aea34c class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14642
diff changeset
  4555
    ^'    $(OUTDIR_SLASH)%(CLASSFILE).$(O) \'
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4556
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4557
    "Created: / 08-08-2006 / 20:16:46 / fm"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4558
    "Modified: / 23-08-2006 / 11:11:38 / cg"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4559
!
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4560
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4561
packageName_dot_rc
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4562
    "the template code for the <libName>.rc file.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4563
     Only used for WIN"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4564
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4565
^
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4566
'//
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4567
// DO NOT EDIT
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4568
// automagically generated from the projectDefinition: ',self name,'.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4569
//
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4570
VS_VERSION_INFO VERSIONINFO
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4571
  FILEVERSION     %(FILE_VERSION_COMMASEPARATED)
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4572
  PRODUCTVERSION  %(PRODUCT_VERSION_COMMASEPARATED)
13769
8259f3bf7fa2 changed: #packageName_dot_rc
Claus Gittinger <cg@exept.de>
parents: 13763
diff changeset
  4573
#if (__BORLANDC__)
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4574
  FILEFLAGSMASK   VS_FF_DEBUG | VS_FF_PRERELEASE
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4575
  FILEFLAGS       VS_FF_PRERELEASE | VS_FF_SPECIALBUILD
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4576
  FILEOS          VOS_NT_WINDOWS32
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4577
  FILETYPE        %(FILETYPE)
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4578
  FILESUBTYPE     VS_USER_DEFINED
13769
8259f3bf7fa2 changed: #packageName_dot_rc
Claus Gittinger <cg@exept.de>
parents: 13763
diff changeset
  4579
#endif
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4580
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4581
BEGIN
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4582
  BLOCK "StringFileInfo"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4583
  BEGIN
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4584
    BLOCK "040904E4"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4585
    BEGIN
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4586
      VALUE "CompanyName", "%(COMPANY_NAME)\0"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4587
      VALUE "FileDescription", "%(FILE_DESCRIPTION)\0"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4588
      VALUE "FileVersion", "%(FILE_VERSION)\0"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4589
      VALUE "InternalName", "%(INTERNAL_NAME)\0"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4590
%(LEGAL_COPYRIGHT_LINE)
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4591
      VALUE "ProductName", "%(PRODUCT_NAME)\0"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4592
      VALUE "ProductVersion", "%(PRODUCT_VERSION)\0"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4593
      VALUE "ProductDate", "%(PRODUCT_DATE)\0"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4594
    END
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4595
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4596
  END
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4597
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4598
  BLOCK "VarFileInfo"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4599
  BEGIN                               //  Language   |    Translation
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4600
    VALUE "Translation", 0x409, 0x4E4 // U.S. English, Windows Multilingual
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4601
  END
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4602
END
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4603
'
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4604
    "
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4605
     stx_libbasic3 packageName_dot_rc
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4606
     stx_libbasic3 generate_packageName_dot_rc
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4607
    "
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4608
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4609
    "Created: / 08-08-2006 / 19:31:29 / fm"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4610
    "Modified: / 09-08-2006 / 15:10:57 / fm"
13769
8259f3bf7fa2 changed: #packageName_dot_rc
Claus Gittinger <cg@exept.de>
parents: 13763
diff changeset
  4611
    "Modified: / 07-10-2011 / 10:51:34 / cg"
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4612
!
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4613
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4614
package_dot_deps_dot_rake
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4615
    ^ '
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4616
# Package dependencies.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4617
# Automatically generated by project defintion.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4618
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4619
%(DEPENDENCIES)
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4620
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4621
'
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4622
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4623
    "Created: / 24-02-2011 / 22:32:10 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4624
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4625
14334
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4626
tccmake_dot_mak
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4627
    "the template code for the tccmake.bat file"
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4628
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4629
    ^
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4630
'@REM -------
14336
da3a54f80c09 changed:
Claus Gittinger <cg@exept.de>
parents: 14334
diff changeset
  4631
@REM make using tcc compiler (Tiny-C)
14334
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4632
@REM type tccmake, and wait...
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4633
@REM do not edit - automatically generated from ProjectDefinition
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4634
@REM -------
14361
0e832917e039 changed:
Claus Gittinger <cg@exept.de>
parents: 14354
diff changeset
  4635
make.exe -N -f bc.mak -DUSETCC=1 %%*
14334
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4636
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4637
%(SUBPROJECT_TCCMAKE_CALLS)
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4638
'
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4639
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4640
    "Created: / 03-09-2012 / 19:50:41 / cg"
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4641
!
654df740c912 tcc preps
Claus Gittinger <cg@exept.de>
parents: 14248
diff changeset
  4642
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4643
vcmake_dot_mak
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4644
    "the template code for the vcmake.bat file"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4645
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4646
    ^
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4647
'@REM -------
14336
da3a54f80c09 changed:
Claus Gittinger <cg@exept.de>
parents: 14334
diff changeset
  4648
@REM make using Microsoft Visual C compiler
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4649
@REM type vcmake, and wait...
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4650
@REM do not edit - automatically generated from ProjectDefinition
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4651
@REM -------
13789
4071cbd4caf8 changed: #vcmake_dot_mak
Claus Gittinger <cg@exept.de>
parents: 13769
diff changeset
  4652
4071cbd4caf8 changed: #vcmake_dot_mak
Claus Gittinger <cg@exept.de>
parents: 13769
diff changeset
  4653
@if not defined VSINSTALLDIR (
14850
fbe2fa085a67 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14843
diff changeset
  4654
    pushd %(TOP)\rules
fbe2fa085a67 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14843
diff changeset
  4655
    call vcsetup.bat
fbe2fa085a67 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14843
diff changeset
  4656
    popd
13789
4071cbd4caf8 changed: #vcmake_dot_mak
Claus Gittinger <cg@exept.de>
parents: 13769
diff changeset
  4657
)
13797
f191b8d50bd3 changed:
Stefan Vogel <sv@exept.de>
parents: 13789
diff changeset
  4658
make.exe -N -f bc.mak -DUSEVC %%*
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4659
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4660
%(SUBPROJECT_VCMAKE_CALLS)
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4661
'
12966
396518f8f526 usevc/usebc handling
Claus Gittinger <cg@exept.de>
parents: 12964
diff changeset
  4662
14336
da3a54f80c09 changed:
Claus Gittinger <cg@exept.de>
parents: 14334
diff changeset
  4663
    "Modified: / 04-09-2012 / 11:45:49 / cg"
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4664
! !
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4665
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4666
!ProjectDefinition class methodsFor:'loading'!
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4667
12397
Claus Gittinger <cg@exept.de>
parents: 12372
diff changeset
  4668
ensureFullyLoaded
Claus Gittinger <cg@exept.de>
parents: 12372
diff changeset
  4669
    "ensure that all classes and extensions are loaded properly.
Claus Gittinger <cg@exept.de>
parents: 12372
diff changeset
  4670
     This is normally no problem for compiled classLibs - however, if a package
Claus Gittinger <cg@exept.de>
parents: 12372
diff changeset
  4671
     has only be installedAsAutoloaded, some classes might want to ensure that
Claus Gittinger <cg@exept.de>
parents: 12372
diff changeset
  4672
     when being loaded themself."
Claus Gittinger <cg@exept.de>
parents: 12372
diff changeset
  4673
Claus Gittinger <cg@exept.de>
parents: 12372
diff changeset
  4674
    self hasAllExtensionsLoaded ifFalse:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4675
        self breakPoint:#cg.
12397
Claus Gittinger <cg@exept.de>
parents: 12372
diff changeset
  4676
    ].
Claus Gittinger <cg@exept.de>
parents: 12372
diff changeset
  4677
    self hasAllClassesFullyLoaded ifFalse:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4678
        self hasAllClassesLoaded ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4679
            self breakPoint:#cg.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4680
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4681
        self installAutoloadedClasses.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4682
        self classes do:[:cls | cls autoload ].
12397
Claus Gittinger <cg@exept.de>
parents: 12372
diff changeset
  4683
    ].
Claus Gittinger <cg@exept.de>
parents: 12372
diff changeset
  4684
Claus Gittinger <cg@exept.de>
parents: 12372
diff changeset
  4685
    "
Claus Gittinger <cg@exept.de>
parents: 12372
diff changeset
  4686
     stx_libbasic ensureFullyLoaded
Claus Gittinger <cg@exept.de>
parents: 12372
diff changeset
  4687
    "
12731
ffec4d9573bc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12705
diff changeset
  4688
    "Verbose := true
ffec4d9573bc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12705
diff changeset
  4689
     stx_libjavascript hasAllExtensionsLoaded
ffec4d9573bc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12705
diff changeset
  4690
    "
12735
215f7514f56b comment/format in: #ensureFullyLoaded
Claus Gittinger <cg@exept.de>
parents: 12731
diff changeset
  4691
    "Verbose := true
215f7514f56b comment/format in: #ensureFullyLoaded
Claus Gittinger <cg@exept.de>
parents: 12731
diff changeset
  4692
     stx_goodies_soap_xe hasAllExtensionsLoaded
215f7514f56b comment/format in: #ensureFullyLoaded
Claus Gittinger <cg@exept.de>
parents: 12731
diff changeset
  4693
    "
13689
9d93d5e56029 changed: #ensureFullyLoaded
Claus Gittinger <cg@exept.de>
parents: 13688
diff changeset
  4694
9d93d5e56029 changed: #ensureFullyLoaded
Claus Gittinger <cg@exept.de>
parents: 13688
diff changeset
  4695
    "Modified: / 12-09-2011 / 16:57:53 / cg"
12397
Claus Gittinger <cg@exept.de>
parents: 12372
diff changeset
  4696
!
Claus Gittinger <cg@exept.de>
parents: 12372
diff changeset
  4697
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4698
load
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4699
    "load the project
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4700
     Answer true, if new classes have been installed for this package,
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4701
     false if the package's classes have been already present."
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4702
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4703
    ^ self loadAsAutoloaded:false.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4704
!
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4705
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4706
loadAsAutoloaded:asAutoloaded
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4707
    "load the project.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4708
     If asAutoloaded == true, install all new classes as autoloaded.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4709
     Answer true, if new classes have been installed for this package,
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4710
     false if the package's classes have been already present."
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4711
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4712
    |newStuffHasBeenLoaded meOrMySecondIncarnation|
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4713
13614
5606bfa8cbec added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13610
diff changeset
  4714
    self projectIsLoaded ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4715
        asAutoloaded ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4716
            "/ to be considered !!
13614
5606bfa8cbec added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13610
diff changeset
  4717
"/            self isFullyLoaded ifFalse:[
5606bfa8cbec added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13610
diff changeset
  4718
"/                self hasAllExtensionsLoaded ifFalse:[
5606bfa8cbec added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13610
diff changeset
  4719
"/                    self loadExtensions.
5606bfa8cbec added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13610
diff changeset
  4720
"/                ].
5606bfa8cbec added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13610
diff changeset
  4721
"/                self loadAllAutoloadedClasses
5606bfa8cbec added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13610
diff changeset
  4722
"/            ].
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4723
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4724
        ^ false
13614
5606bfa8cbec added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13610
diff changeset
  4725
    ].
12749
160f7b56e426 oops: leftover halts.
Claus Gittinger <cg@exept.de>
parents: 12748
diff changeset
  4726
    thisContext isRecursive ifTrue:[self breakPoint:#cg. ^ false].    "/ avoid endless loops
14851
7be11ef3d914 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14850
diff changeset
  4727
    (PackagesBeingLoaded notNil and:[PackagesBeingLoaded includes:self package]) ifTrue:[
7be11ef3d914 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14850
diff changeset
  4728
        "/ seems to be a recursive call
7be11ef3d914 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14850
diff changeset
  4729
        ^ false
7be11ef3d914 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14850
diff changeset
  4730
    ].
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4731
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4732
    newStuffHasBeenLoaded := false.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4733
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4734
    (self infoPrinting and:[Smalltalk silentLoading not]) ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4735
        "/ thisContext fullPrintAll.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4736
        Transcript showCR:('loading %1%2...'
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4737
                            bindWith:(asAutoloaded ifTrue:['as autoloaded '] ifFalse:[''])
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4738
                            with:self name).
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4739
    ].
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4740
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4741
    self rememberOverwrittenExtensionMethods.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4742
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4743
    self activityNotification:'Executing pre-load action'.
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  4744
    self executeHooks: #preLoad.
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4745
    self preLoadAction.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4746
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4747
    meOrMySecondIncarnation := self.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4748
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4749
    Class withoutUpdatingChangesDo:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4750
        self activityNotification:'Loading prerequisities'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4751
        self loadPreRequisitesAsAutoloaded:asAutoloaded.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4752
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4753
        self checkPrerequisitesForLoading.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4754
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4755
        asAutoloaded ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4756
            self loadClassLibrary.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4757
            "/ could have overloaded my first incarnation
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4758
            meOrMySecondIncarnation := (Smalltalk at:(self name)) ? self.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4759
            meOrMySecondIncarnation ~~ self ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4760
                meOrMySecondIncarnation fetchSlotsFrom:self.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4761
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4762
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4763
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4764
        self hasAllExtensionsLoaded ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4765
            self activityNotification:'Loading extensions'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4766
            newStuffHasBeenLoaded := newStuffHasBeenLoaded | meOrMySecondIncarnation loadExtensions.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4767
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4768
        self hasAllClassesLoaded ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4769
            self activityNotification:'Loading classes'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4770
            newStuffHasBeenLoaded := newStuffHasBeenLoaded | (meOrMySecondIncarnation loadAllClassesAsAutoloaded:asAutoloaded).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4771
        ].
12743
c39a4553e1ed changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12742
diff changeset
  4772
"/ no, don't load subProjects here - will lead to a recursion, which leads
c39a4553e1ed changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12742
diff changeset
  4773
"/ to some classes being loaded from source (soap)
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4774
        self activityNotification:'Loading sub projects'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4775
        meOrMySecondIncarnation loadSubProjectsAsAutoloaded:asAutoloaded.
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4776
    ].
13194
8e451f8ff654 changed: #loadAsAutoloaded:
Claus Gittinger <cg@exept.de>
parents: 13178
diff changeset
  4777
    self activityNotification:('Executing post-load action for %1' bindWith:self package).
12372
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  4778
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  4779
    "/ mhmh - already done for dll-loaded packages
f2e1ae83b5a4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 12371
diff changeset
  4780
    "/ meOrMySecondIncarnation initializeAllClasses.
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4781
    meOrMySecondIncarnation postLoadAction.
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  4782
    meOrMySecondIncarnation executeHooks: #postLoad.
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4783
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4784
    meOrMySecondIncarnation projectIsLoaded:true.
12736
e18f8f352186 changed: #loadAsAutoloaded:
Claus Gittinger <cg@exept.de>
parents: 12735
diff changeset
  4785
    meOrMySecondIncarnation ~~ self ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4786
        self projectIsLoaded:true.
12736
e18f8f352186 changed: #loadAsAutoloaded:
Claus Gittinger <cg@exept.de>
parents: 12735
diff changeset
  4787
    ].
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4788
13194
8e451f8ff654 changed: #loadAsAutoloaded:
Claus Gittinger <cg@exept.de>
parents: 13178
diff changeset
  4789
    self activityNotification:('Done (%1).' bindWith:self package).
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4790
    ^ newStuffHasBeenLoaded
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4791
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4792
    "Created: / 17-08-2006 / 01:01:41 / cg"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4793
    "Modified: / 30-10-2008 / 08:16:21 / Jan Vrany <vranyj1@fel.cvut.cz>"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4794
    "Modified: / 22-08-2009 / 12:02:14 / Jan Vrany <jan.vrany@fit.cvut.cz>"
13623
46625f58d8ee changed: #loadAsAutoloaded:
Claus Gittinger <cg@exept.de>
parents: 13614
diff changeset
  4795
    "Modified: / 04-09-2011 / 10:01:53 / cg"
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  4796
    "Modified: / 20-11-2012 / 23:06:32 / Jan Vrany <jan.vrany@fit.cvut.cz>"
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4797
!
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4798
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4799
unloadPackage
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4800
    "unload the project.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4801
     Fails if there are still instances of any of my classes in the system"
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4802
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4803
    self projectIsLoaded ifFalse:[^ false].
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4804
    thisContext isRecursive ifTrue:[^ false].
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4805
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4806
    (self infoPrinting and:[Smalltalk silentLoading not]) ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4807
        "/ thisContext fullPrintAll.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4808
        Transcript show:'unloading '; showCR:self name.
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4809
    ].
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4810
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4811
    self activityNotification:'Executing pre-unload action'.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4812
    self preUnloadAction.
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  4813
    self executeHooks: #preUnload.
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4814
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4815
    self activityNotification:'Restoring original methods'.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4816
    self restoreOverwrittenExtensionMethods.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4817
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4818
    Class withoutUpdatingChangesDo:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4819
        self activityNotification:'Unloading sunprojects'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4820
        self unloadSubProjects.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4821
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4822
        self activityNotification:'Unloading classes'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4823
        self unloadClassLibrary.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4824
        self unloadAllClasses.
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4825
    ].
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4826
    self projectIsLoaded:false.
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4827
    ^ true
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  4828
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  4829
    "Modified: / 20-11-2012 / 23:06:47 / Jan Vrany <jan.vrany@fit.cvut.cz>"
12364
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4830
! !
f39b6791e557 category of:26 methods
Claus Gittinger <cg@exept.de>
parents: 12360
diff changeset
  4831
12086
9db1452d0645 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12039
diff changeset
  4832
!ProjectDefinition class methodsFor:'misc ui support'!
9db1452d0645 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12039
diff changeset
  4833
9db1452d0645 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12039
diff changeset
  4834
iconInBrowserSymbol
9db1452d0645 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12039
diff changeset
  4835
    <resource: #programImage>
9db1452d0645 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12039
diff changeset
  4836
9db1452d0645 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12039
diff changeset
  4837
    self theNonMetaclass isApplicationDefinition ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4838
        self theNonMetaclass isGUIApplication ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4839
            ^ #guiApplicationDefinitionClassIcon
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4840
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4841
        ^ #applicationDefinitionClassIcon
12086
9db1452d0645 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12039
diff changeset
  4842
    ].
9db1452d0645 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12039
diff changeset
  4843
    ^ super iconInBrowserSymbol
9db1452d0645 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12039
diff changeset
  4844
! !
9db1452d0645 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12039
diff changeset
  4845
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  4846
!ProjectDefinition class methodsFor:'private'!
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  4847
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4848
abbrevs
13592
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  4849
    "return a dictionary containing my abbreviations;
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  4850
     this dictionary is read from my project-directory's abbrev.stc file,
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  4851
     and cached for future use"
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  4852
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  4853
    |abbrevs|
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  4854
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  4855
    AccessLock critical:[
13959
a2fd3561bb67 changed: #abbrevs
Claus Gittinger <cg@exept.de>
parents: 13950
diff changeset
  4856
        |mustRead file myPackageDirectory|
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4857
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4858
        AbbrevDictionary isNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4859
            AbbrevDictionary := WeakIdentityDictionary new.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4860
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4861
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4862
        mustRead := false.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4863
        abbrevs := AbbrevDictionary at:self ifAbsent:[ mustRead := true. Dictionary new ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4864
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4865
        mustRead ifTrue:[
13959
a2fd3561bb67 changed: #abbrevs
Claus Gittinger <cg@exept.de>
parents: 13950
diff changeset
  4866
            myPackageDirectory := self packageDirectory.
a2fd3561bb67 changed: #abbrevs
Claus Gittinger <cg@exept.de>
parents: 13950
diff changeset
  4867
            myPackageDirectory isNil ifTrue:[
a2fd3561bb67 changed: #abbrevs
Claus Gittinger <cg@exept.de>
parents: 13950
diff changeset
  4868
            ] ifFalse:[
a2fd3561bb67 changed: #abbrevs
Claus Gittinger <cg@exept.de>
parents: 13950
diff changeset
  4869
                file := myPackageDirectory / 'abbrev.stc'.
a2fd3561bb67 changed: #abbrevs
Claus Gittinger <cg@exept.de>
parents: 13950
diff changeset
  4870
                file exists ifTrue: [
a2fd3561bb67 changed: #abbrevs
Claus Gittinger <cg@exept.de>
parents: 13950
diff changeset
  4871
                    file readingFileDo:[:stream |
a2fd3561bb67 changed: #abbrevs
Claus Gittinger <cg@exept.de>
parents: 13950
diff changeset
  4872
                        Smalltalk
a2fd3561bb67 changed: #abbrevs
Claus Gittinger <cg@exept.de>
parents: 13950
diff changeset
  4873
                            withAbbreviationsFromStream:stream
a2fd3561bb67 changed: #abbrevs
Claus Gittinger <cg@exept.de>
parents: 13950
diff changeset
  4874
                            do:[:nm :fn :pkg :cat :sz|
a2fd3561bb67 changed: #abbrevs
Claus Gittinger <cg@exept.de>
parents: 13950
diff changeset
  4875
                                abbrevs at: nm put: (AbbrevEntry new className:nm fileName:fn category:cat numClassInstVars:sz)
a2fd3561bb67 changed: #abbrevs
Claus Gittinger <cg@exept.de>
parents: 13950
diff changeset
  4876
                            ]
a2fd3561bb67 changed: #abbrevs
Claus Gittinger <cg@exept.de>
parents: 13950
diff changeset
  4877
                    ]
a2fd3561bb67 changed: #abbrevs
Claus Gittinger <cg@exept.de>
parents: 13950
diff changeset
  4878
                ].
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4879
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4880
        ].
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4881
    ].
13695
Claus Gittinger <cg@exept.de>
parents: 13694
diff changeset
  4882
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4883
    ^abbrevs
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4884
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4885
    "Created: / 06-03-2011 / 18:25:49 / Jan Vrany <jan.vrany@fit.cvut.cz>"
13959
a2fd3561bb67 changed: #abbrevs
Claus Gittinger <cg@exept.de>
parents: 13950
diff changeset
  4886
    "Modified: / 20-01-2012 / 15:42:47 / cg"
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4887
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  4888
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4889
additionalClassAttributesFor: aClass
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4890
    "Answers additional set of class attributes for given class
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4891
     Individual project definitions may override this method, but
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4892
     overriding method should always merge its attributes with result
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4893
     of 'super additionalClassAttributesFor: aClass'.
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4894
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4895
     Here, we add #autoload attributes to all test cases and
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4896
     test resources, as they are not neccessary for the package
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4897
     and should not be compiled (because of unwanted dependency
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4898
     on stx:goodies/sunit package)
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4899
    "
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4900
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4901
    (aClass inheritsFrom: TestCase) ifTrue:[^#(autoload)].
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4902
    (aClass inheritsFrom: TestResource) ifTrue:[^#(autoload)].
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4903
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4904
    "No additional attributes"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4905
    ^#()
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4906
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4907
    "
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4908
        stx_libbasic additionalClassAttributesFor: Object
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4909
        stx_libtool additionalClassAttributesFor: Tools::NavigationHistoryTests
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4910
        stx_goodies_sunit additionalClassAttributesFor: TestCase
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4911
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4912
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4913
        stx_libtool classNamesAndAttributes_code_ignoreOldEntries:true ignoreOldDefinition: true
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4914
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4915
    "
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4916
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4917
    "Created: / 26-10-2009 / 12:54:38 / Jan Vrany <jan.vrany@fit.cvut.cz>"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4918
!
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4919
11868
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4920
checkIfClassesArePresent
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4921
    "check if all classes defined by this project are present and
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4922
     offer a dialog to abort the current operation if not"
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4923
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4924
    |check nonExistantClasses|
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4925
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4926
    nonExistantClasses := Set new.
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4927
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4928
    check :=
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4929
            [:eachClassName |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4930
                |cls fn wasLoaded failedToLoad numClassInstvars|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4931
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4932
                cls := Smalltalk classNamed:eachClassName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4933
                cls isNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4934
                    Transcript showCR:eachClassName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4935
                    nonExistantClasses add:eachClassName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4936
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4937
            ].
11868
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4938
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4939
    self allClassNames do:check.
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4940
    self namesAndAttributesIn:(self additionalClassNamesAndAttributes) do:[:nm :attr |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4941
        (attr isEmptyOrNil or:[(attr includes:#autoload) not]) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4942
            check value:nm
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4943
        ].
11868
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4944
    ].
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4945
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4946
    nonExistantClasses notEmpty ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4947
        (Dialog confirm:(Dialog classResources
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4948
                            stringWithCRs:'"%1" and possibly more classes are missing.\Cannot generate a correct "abbrev.stc" file.\\Continue anyway?'
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4949
                            with:nonExistantClasses anElement allBold))
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4950
        ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4951
            AbortOperationRequest raise.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4952
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4953
        ^ false.
11868
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4954
    ].
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4955
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4956
    ^ true
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4957
!
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  4958
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4959
classNamesAndAttributesAsSpecArray
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  4960
    "given a classNamesAndAttributes array, make this a spec array (array of arrays).
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4961
     This decompresses class-name entries into a one-element array for easier processing"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4962
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4963
    ^ self classNamesAndAttributes
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4964
        collect:[:entry |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4965
            entry isArray ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4966
                entry first isSymbol ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4967
                    entry
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4968
                ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4969
                    (Array with:entry first asSymbol) , (entry copyFrom:2)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4970
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4971
            ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4972
                Array with:entry asSymbol.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4973
            ]].
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4974
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4975
    "Created: / 19-02-2007 / 16:11:53 / cg"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4976
!
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4977
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  4978
classNamesAndAttributesDo: aBlock
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  4979
    self namesAndAttributesIn:(self classNamesAndAttributes) do: aBlock
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  4980
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  4981
    "Modified: / 22-08-2006 / 18:20:21 / cg"
9607
3cae5cf71c03 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9601
diff changeset
  4982
!
3cae5cf71c03 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9601
diff changeset
  4983
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4984
classNamesAndAttributesFromSpecArray:aSpecArray
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4985
    "given a spec array (array of arrays), make this a classNamesAndAttributes array
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4986
     as stored literally in the method.
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4987
     This compresses single element array-elements into plain names
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4988
     (to save code in the compiled binaries)"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4989
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4990
    ^ aSpecArray
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4991
        collect:[:entry |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4992
            (entry isArray and:[entry size == 1]) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4993
                entry first
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4994
            ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4995
                entry
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  4996
            ]].
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4997
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4998
    "Created: / 19-02-2007 / 16:12:32 / cg"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  4999
!
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  5000
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5001
compile:someCode categorized:category
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5002
    Class packageQuerySignal
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5003
        answer:self package
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5004
        do:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5005
            self theMetaclass compilerClass
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5006
                compile:someCode
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5007
                forClass:self theMetaclass
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5008
                inCategory:category
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5009
                notifying:nil
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5010
                install:true
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5011
                skipIfSame:true
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5012
                silent:true.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5013
        ]
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5014
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5015
    "Created: / 23-08-2006 / 14:36:53 / cg"
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5016
!
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5017
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5018
compiled_classes
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5019
    ^ self compiled_classNames
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5020
        collect:
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5021
            [:eachName|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5022
                |cls|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5023
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5024
                cls := (Smalltalk at:eachName asSymbol).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5025
                (cls isNil or:[cls isBehavior not]) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5026
                    Transcript showCR:('ProjectDefinition: missing/invalid class: ', eachName).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5027
                    cls := nil.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5028
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5029
                cls.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5030
            ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5031
        thenSelect:[:cls | cls notNil]
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5032
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5033
    "Created: / 09-08-2006 / 16:28:15 / fm"
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5034
    "Modified: / 09-08-2006 / 18:02:28 / fm"
10251
653b5d0a7713 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10232
diff changeset
  5035
    "Modified: / 07-12-2006 / 17:48:11 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  5036
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  5037
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5038
compiled_classesDo:aBlock
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5039
    self compiled_classes do:aBlock.
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5040
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5041
    "Created: / 09-08-2006 / 16:28:15 / fm"
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5042
    "Modified: / 09-08-2006 / 18:02:28 / fm"
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5043
!
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5044
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5045
compiled_classesForArchitecture:arch
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5046
    ^ (self compiled_classNamesForPlatform:arch)
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5047
        collect:[:eachName | (Smalltalk at:eachName asSymbol) ]
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5048
10251
653b5d0a7713 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10232
diff changeset
  5049
    "
653b5d0a7713 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10232
diff changeset
  5050
     stx_libbasic compiled_classesForArchitecture:#win32
653b5d0a7713 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10232
diff changeset
  5051
     stx_libbasic compiled_classesForArchitecture:#macos
653b5d0a7713 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10232
diff changeset
  5052
     stx_libbasic compiled_classesForArchitecture:#unix
653b5d0a7713 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10232
diff changeset
  5053
    "
653b5d0a7713 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10232
diff changeset
  5054
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5055
    "Created: / 09-08-2006 / 16:28:15 / fm"
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5056
    "Modified: / 09-08-2006 / 18:02:28 / fm"
10251
653b5d0a7713 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10232
diff changeset
  5057
    "Modified: / 07-12-2006 / 17:43:17 / cg"
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5058
!
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5059
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5060
compiled_classes_common
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5061
    ^ self
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5062
        compiled_classNames_common
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5063
            collect:[:eachName |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5064
                |cls|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5065
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5066
                cls := (Smalltalk at:eachName asSymbol).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5067
                cls isBehavior ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5068
                    self warn:('Missing/invalid class: %1\\%2'
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5069
                                bindWith:eachName
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5070
                                with:('Warning: The class is skipped in the list of compiled classes.' allBold)) withCRs.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5071
                    cls := nil.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5072
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5073
                cls
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5074
            ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5075
            thenSelect:[:cls| cls notNil "isBehavior"]
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5076
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5077
    "Created: / 09-08-2006 / 16:28:15 / fm"
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5078
    "Modified: / 09-08-2006 / 18:02:28 / fm"
13090
827d5322948f changed: #compiled_classes_common
Claus Gittinger <cg@exept.de>
parents: 13088
diff changeset
  5079
    "Modified: / 11-10-2010 / 12:11:06 / cg"
9607
3cae5cf71c03 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9601
diff changeset
  5080
!
3cae5cf71c03 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9601
diff changeset
  5081
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5082
cvsRevision
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5083
    |rev|
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5084
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5085
    rev := self revision.
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5086
    rev isNil ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5087
        "not yet pubplished"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5088
        ^ #( '0' '1' )
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5089
    ].
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5090
    ^ rev asCollectionOfSubstringsSeparatedBy:$. .
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5091
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5092
    "
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5093
     self cvsRevision
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5094
     stx_libbasic3 cvsRevision
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5095
    "
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5096
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5097
    "Created: / 17-08-2006 / 20:19:03 / cg"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  5098
!
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  5099
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5100
defaultClassAttributesFor: aClass
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5101
    "Answers default set of class attributes for given class.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5102
     This is internal method only, to per-project customization
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5103
     please override either #additionalClassAttributes or
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5104
     #additional classAttributesFor:"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5105
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5106
    | attrs |
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5107
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5108
    "JV @ 2010-06-19
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5109
     Add a programming language attribute for non-smalltalk classes.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5110
     Used by multi-lang enabled loading mechanism"
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5111
    attrs := aClass programmingLanguage isSmalltalk
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5112
                ifTrue:[#()]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5113
                ifFalse:[Array with: (Array with: #lang with: aClass programmingLanguage name asSymbol)].
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5114
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5115
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5116
    "JV @ 2009-10-26
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5117
     Give a project definition to specify additional attributes for given class."
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5118
    attrs := attrs , (self additionalClassAttributesFor: aClass).
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5119
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5120
    ^attrs
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5121
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5122
    "Created: / 19-06-2010 / 10:44:13 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5123
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5124
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5125
inconsistency:message
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5126
    Dialog warn:message
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  5127
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5128
"
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5129
    self searchForNeverCompiledSuperclasses
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5130
    DapasX_Datenbasis searchForNeverCompiledSuperclasses
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5131
"
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5132
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5133
    "Created: / 09-08-2006 / 16:32:31 / fm"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  5134
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  5135
9826
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5136
makeOSIncludesWith:fileSeparator from:aString
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5137
    ^ aString copy replaceAny:'/\' with:fileSeparator
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5138
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5139
    "
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5140
     self makeOSIncludesWith:$/ from:'-I$(TOP)/foo/bar'
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5141
     self makeOSIncludesWith:$\ from:'-I$(TOP)/foo/bar'
9826
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5142
    "
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5143
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5144
    "Created: / 06-09-2006 / 18:17:03 / cg"
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5145
!
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5146
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5147
makeUnixIncludes:aString
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5148
    ^ self makeOSIncludesWith:$/ from:aString
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5149
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5150
    "Created: / 06-09-2006 / 18:16:19 / cg"
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5151
!
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5152
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5153
makeWin32Includes:aString
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5154
    ^ self makeOSIncludesWith:$\ from:aString
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5155
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5156
    "Created: / 06-09-2006 / 18:16:13 / cg"
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5157
!
8d5fe8462720 common localIncludes for all oses
Claus Gittinger <cg@exept.de>
parents: 9825
diff changeset
  5158
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5159
mergeClassAttributes: attr1 with: attr2
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5160
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5161
    ^attr1 , (attr2 reject:[:each|attr1 includes: each])
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5162
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5163
    "Created: / 19-06-2010 / 10:50:02 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5164
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5165
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5166
mergeDefaultClassAttributesFor: aClass with: attributes
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5167
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5168
    ^self mergeClassAttributes: attributes with: (self defaultClassAttributesFor: aClass)
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5169
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5170
    "Created: / 19-06-2010 / 10:51:49 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5171
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5172
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5173
namesAndAttributesIn:aCollection do: aBlock
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5174
    aCollection do:[:entry |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5175
        |className attributes|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5176
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5177
        entry isArray ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5178
            className := entry.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5179
            attributes := #().
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5180
        ] ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5181
            className := entry first.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5182
            attributes := entry copyFrom:2.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5183
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5184
        aBlock value: className value: attributes
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5185
     ].
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5186
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5187
    "Created: / 22-08-2006 / 18:20:09 / cg"
9621
1d07872787b0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9618
diff changeset
  5188
!
1d07872787b0 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9618
diff changeset
  5189
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5190
searchForClasses
10010
69b2dbff964b *** empty log message ***
Stefan Vogel <sv@exept.de>
parents: 10007
diff changeset
  5191
    "answer all non-private classes that belong to this project.
10005
407485f2a6e0 fix loading:
Stefan Vogel <sv@exept.de>
parents: 9998
diff changeset
  5192
     They are sorted in load order"
407485f2a6e0 fix loading:
Stefan Vogel <sv@exept.de>
parents: 9998
diff changeset
  5193
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5194
    ^ Class classesSortedByLoadOrder:(self searchForClassesWithProject: self package)
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5195
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5196
    "
10010
69b2dbff964b *** empty log message ***
Stefan Vogel <sv@exept.de>
parents: 10007
diff changeset
  5197
     stx_libbasic3 searchForClasses
11868
59e160ca3419 First support for cleanup of class filenames
Stefan Vogel <sv@exept.de>
parents: 11829
diff changeset
  5198
     stx_goodies_webServer_htmlTree searchForClasses
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5199
    "
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5200
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5201
    "Modified: / 07-08-2006 / 21:56:25 / fm"
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5202
    "Created: / 17-08-2006 / 21:18:30 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  5203
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  5204
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5205
searchForClassesWithProject: aProjectID
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5206
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5207
    ^ Smalltalk allClasses
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5208
        select:[:cls | (cls package = aProjectID) ].
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5209
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5210
"
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5211
    self searchForClassesWithProject: #'bosch:dapasx'
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5212
    self searchForClassesWithProject: #'bosch:dapasx/datenbasis'
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5213
    self searchForClassesWithProject: #'bosch:dapasx/kernel'
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5214
"
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5215
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5216
    "Created: / 07-08-2006 / 20:42:39 / fm"
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5217
    "Modified: / 07-08-2006 / 21:56:25 / fm"
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5218
    "Modified: / 16-08-2006 / 18:50:48 / User"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  5219
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  5220
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5221
searchForExtensions
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5222
    ^ self searchForExtensionsWithProject:self package
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5223
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5224
"
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5225
    self searchForExtensions
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5226
    DapasXProject searchForExtensions
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5227
    DapasX_Datenbasis searchForExtensions
10106
c26879b72dfe extensionlist generator was buggy
Claus Gittinger <cg@exept.de>
parents: 10104
diff changeset
  5228
    stx_libtool searchForExtensions
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5229
"
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5230
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5231
    "Modified: / 09-08-2006 / 13:01:26 / fm"
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5232
    "Created: / 17-08-2006 / 21:17:46 / cg"
10106
c26879b72dfe extensionlist generator was buggy
Claus Gittinger <cg@exept.de>
parents: 10104
diff changeset
  5233
    "Modified: / 23-10-2006 / 11:03:07 / cg"
9575
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  5234
!
353ef8cc798f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9569
diff changeset
  5235
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5236
searchForExtensionsWithProject:aProjectID
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5237
    "search for any class which has extensions from aProjectID.
10086
024ea420d1a6 extension method stuff refactored
Claus Gittinger <cg@exept.de>
parents: 10080
diff changeset
  5238
     Return the extension-methods sorted by classname-selector"
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5239
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5240
    |methods|
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5241
11152
92ef5422f17a code reuse
Claus Gittinger <cg@exept.de>
parents: 11149
diff changeset
  5242
    methods := Smalltalk allExtensionsForPackage:aProjectID.
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5243
    methods
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5244
        sort:[:m1 :m2 |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5245
            |c1 c2|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5246
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5247
            c1 := m1 mclass.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5248
            c2 := m2 mclass.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5249
            c1 == c2 ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5250
                m1 selector < m2 selector
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5251
            ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5252
                (c2 isMeta and:[c1 isMeta not]) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5253
                    true
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5254
                ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5255
                    (c1 isMeta and:[c2 isMeta not]) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5256
                        false
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5257
                    ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5258
                        c1 name < c2 name
9908
eede5b535b1e extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents: 9906
diff changeset
  5259
"/                        (c2 isSubclassOf:c1) ifTrue:[
eede5b535b1e extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents: 9906
diff changeset
  5260
"/                            true
eede5b535b1e extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents: 9906
diff changeset
  5261
"/                        ] ifFalse:[
eede5b535b1e extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents: 9906
diff changeset
  5262
"/                            (c1 isSubclassOf:c2) ifTrue:[
eede5b535b1e extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents: 9906
diff changeset
  5263
"/                                false
eede5b535b1e extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents: 9906
diff changeset
  5264
"/                            ] ifFalse:[
eede5b535b1e extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents: 9906
diff changeset
  5265
"/                                "/ leave as is
eede5b535b1e extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents: 9906
diff changeset
  5266
"/                                true
eede5b535b1e extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents: 9906
diff changeset
  5267
"/                            ].
eede5b535b1e extensions sorted by name (to avoid confusing cvs-diff)
Claus Gittinger <cg@exept.de>
parents: 9906
diff changeset
  5268
"/                        ].
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5269
                    ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5270
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5271
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5272
        ].
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5273
    ^ methods
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5274
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5275
    "
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5276
     self searchForExtensionsWithProject:#'bosch:dapasx'
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5277
     self searchForExtensionsWithProject:#'cg:oyster'
10086
024ea420d1a6 extension method stuff refactored
Claus Gittinger <cg@exept.de>
parents: 10080
diff changeset
  5278
     self searchForExtensionsWithProject:#'stx:libboss'
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5279
    "
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5280
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5281
    "Created: / 17-08-2006 / 21:19:04 / cg"
10086
024ea420d1a6 extension method stuff refactored
Claus Gittinger <cg@exept.de>
parents: 10080
diff changeset
  5282
    "Modified: / 12-10-2006 / 20:45:39 / cg"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  5283
!
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  5284
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5285
searchForProjectsWhichProvideHeaderFiles
9883
c641767d1483 include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents: 9880
diff changeset
  5286
    |addPackage myPackageID requiredPackages|
c641767d1483 include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents: 9880
diff changeset
  5287
c641767d1483 include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents: 9880
diff changeset
  5288
    myPackageID := self package.
c641767d1483 include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents: 9880
diff changeset
  5289
    requiredPackages := Set new.
c641767d1483 include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents: 9880
diff changeset
  5290
c641767d1483 include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents: 9880
diff changeset
  5291
    addPackage :=
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5292
        [:package |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5293
            (package ~= myPackageID) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5294
                true "(package startsWith:'stx:') not" ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5295
                    package ~= PackageId noProjectID ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5296
                        requiredPackages add:package.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5297
                    ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5298
                ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5299
            ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5300
        ].
9883
c641767d1483 include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents: 9880
diff changeset
  5301
12555
9924562388ed changed: #searchForProjectsWhichProvideHeaderFiles
Claus Gittinger <cg@exept.de>
parents: 12554
diff changeset
  5302
    "/ need them also...
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  5303
    self effectivePreRequisites do:[:eachPreRequisitePackage |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5304
        addPackage value:eachPreRequisitePackage
12555
9924562388ed changed: #searchForProjectsWhichProvideHeaderFiles
Claus Gittinger <cg@exept.de>
parents: 12554
diff changeset
  5305
    ].
9924562388ed changed: #searchForProjectsWhichProvideHeaderFiles
Claus Gittinger <cg@exept.de>
parents: 12554
diff changeset
  5306
10788
f2ff69add7e1 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10785
diff changeset
  5307
    self compiled_classesDo:[:cls |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5308
        cls allSuperclassesDo:[:eachSuperClass |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5309
            addPackage value:(eachSuperClass package)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5310
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5311
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5312
        cls allPrivateClassesDo:[:eachPrivateClass |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5313
            eachPrivateClass allSuperclassesDo:[:eachSuperClass |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5314
                eachSuperClass isPrivate ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5315
                    addPackage value:(eachSuperClass package)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5316
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5317
            ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5318
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5319
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5320
        cls sharedPoolNames do:[:eachPoolName |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5321
            |eachPoolClass|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5322
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5323
            eachPoolClass := Smalltalk classNamed:eachPoolName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5324
            eachPoolClass isNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5325
                Transcript showCR:('Warning: missing pool: %1 (required by %2)' bindWith:eachPoolName with:cls name)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5326
            ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5327
                eachPoolClass withAllSuperclassesDo:[:eachPoolSuperClass |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5328
                    addPackage value:(eachPoolSuperClass package)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5329
                ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5330
            ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5331
        ].
9883
c641767d1483 include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents: 9880
diff changeset
  5332
    ].
c641767d1483 include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents: 9880
diff changeset
  5333
c641767d1483 include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents: 9880
diff changeset
  5334
    self extensionMethodNames pairWiseDo:[:className :selector |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5335
        |cls|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5336
        ((cls := Smalltalk classNamed:className) notNil and:[cls isLoaded]) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5337
            cls withAllSuperclassesDo:[:eachSuperClass |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5338
                addPackage value:(eachSuperClass package)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5339
            ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5340
        ]
9883
c641767d1483 include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents: 9880
diff changeset
  5341
    ].
c641767d1483 include and dependency generation fixed
Claus Gittinger <cg@exept.de>
parents: 9880
diff changeset
  5342
    ^ requiredPackages
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5343
9880
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
  5344
    "
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5345
     stx_libtool searchForProjectsWhichProvideHeaderFiles
9880
378bf1f5afa1 local headers
Claus Gittinger <cg@exept.de>
parents: 9852
diff changeset
  5346
    "
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  5347
10251
653b5d0a7713 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10232
diff changeset
  5348
    "Created: / 07-12-2006 / 17:46:38 / cg"
13216
ef64e67606c5 changed:
Claus Gittinger <cg@exept.de>
parents: 13194
diff changeset
  5349
    "Modified: / 18-01-2011 / 17:58:33 / cg"
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5350
!
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5351
9667
90b25ca6d10e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9664
diff changeset
  5352
searchForSiblingProjects
10132
e2afb1e0363a Add some documentation
Stefan Vogel <sv@exept.de>
parents: 10129
diff changeset
  5353
    "answer all the packages (package names) having the my parent package"
e2afb1e0363a Add some documentation
Stefan Vogel <sv@exept.de>
parents: 10129
diff changeset
  5354
9667
90b25ca6d10e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9664
diff changeset
  5355
    |myPackage myParentPackage|
90b25ca6d10e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9664
diff changeset
  5356
90b25ca6d10e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9664
diff changeset
  5357
    myPackage := self package asPackageId.
90b25ca6d10e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9664
diff changeset
  5358
    myParentPackage := myPackage parentPackage.
90b25ca6d10e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9664
diff changeset
  5359
    myParentPackage isNil ifTrue:[^ #() ].
90b25ca6d10e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9664
diff changeset
  5360
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5361
    ^ Smalltalk allProjectIDs
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5362
        select:[:projectID |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5363
            |thisPackage|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5364
            thisPackage := projectID asPackageId.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5365
            (thisPackage parentPackage = myParentPackage)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5366
            and:[ thisPackage ~= myPackage ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5367
        ]
9667
90b25ca6d10e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9664
diff changeset
  5368
90b25ca6d10e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9664
diff changeset
  5369
    "
90b25ca6d10e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9664
diff changeset
  5370
     self searchForSiblingProjects
90b25ca6d10e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9664
diff changeset
  5371
     bosch_dapasx_Application searchForSiblingProjects
90b25ca6d10e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9664
diff changeset
  5372
     stx_goodies_refactoryBrowser_changes searchForSiblingProjects
90b25ca6d10e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9664
diff changeset
  5373
    "
90b25ca6d10e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9664
diff changeset
  5374
90b25ca6d10e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9664
diff changeset
  5375
    "Modified: / 07-08-2006 / 21:56:25 / fm"
90b25ca6d10e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9664
diff changeset
  5376
    "Created: / 23-08-2006 / 15:06:12 / cg"
90b25ca6d10e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9664
diff changeset
  5377
!
90b25ca6d10e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9664
diff changeset
  5378
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5379
searchForSubProjects
10132
e2afb1e0363a Add some documentation
Stefan Vogel <sv@exept.de>
parents: 10129
diff changeset
  5380
    "answer all packages (package names), that are my subProjects"
e2afb1e0363a Add some documentation
Stefan Vogel <sv@exept.de>
parents: 10129
diff changeset
  5381
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5382
    |myPackage|
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5383
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5384
    myPackage := self package.
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5385
    ^ Smalltalk allProjectIDs
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5386
        select:[:projectID |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5387
            projectID ~= PackageId noProjectID
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5388
            and:[ (projectID asPackageId parentPackage) = myPackage ]].
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5389
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5390
    "
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5391
     self searchForSubProjects
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5392
     bosch_dapasx_Application searchForSubProjects
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5393
     stx_goodies_refactoryBrowser_changes searchForSubProjects
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5394
    "
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5395
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5396
    "Created: / 07-08-2006 / 20:42:39 / fm"
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5397
    "Modified: / 07-08-2006 / 21:56:25 / fm"
10215
2d5aaeab5718 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10212
diff changeset
  5398
    "Modified: / 05-12-2006 / 18:04:27 / cg"
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5399
!
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5400
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5401
setupForType:typeOrNil
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  5402
    typeOrNil = GUIApplicationType ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5403
        self compile:
12425
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  5404
'isGUIApplication
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  5405
    "return true, if this is a GUI application.
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  5406
     (these need more libraries and use a different startup procedure)"
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  5407
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  5408
    ^ true
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  5409
'
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5410
             categorized:'description'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5411
        self superclass: ApplicationDefinition.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5412
        ^ self
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5413
    ].
12856
1651184275a2 comment/format in: #setupForType:
Claus Gittinger <cg@exept.de>
parents: 12804
diff changeset
  5414
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  5415
    typeOrNil = NonGUIApplicationType ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5416
        self compile:
12425
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  5417
'isGUIApplication
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  5418
    "return true, if this is a GUI application.
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  5419
     (these need more libraries and use a different startup procedure)"
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  5420
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  5421
    ^ false
a4062def8125 changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12421
diff changeset
  5422
'
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5423
             categorized:'description'.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5424
        self superclass: ApplicationDefinition.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5425
        ^ self
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5426
    ].
12856
1651184275a2 comment/format in: #setupForType:
Claus Gittinger <cg@exept.de>
parents: 12804
diff changeset
  5427
12349
6493b6124da3 changed:
fm
parents: 12339
diff changeset
  5428
    self theMetaclass removeSelector: #isGUIApplication.
12353
01416e7f9c92 changed: #setupForType:
fm
parents: 12349
diff changeset
  5429
    self superclass: LibraryDefinition.
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5430
    ^ self.
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5431
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  5432
    "Created: / 23-08-2006 / 14:26:10 / cg"
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5433
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5434
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5435
shouldExcludeTest: test
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5436
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5437
    self excludedFromTestSuite do:
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5438
        [:spec|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5439
        (spec isSymbol and:[test class name == spec])
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5440
            ifTrue:[^true].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5441
        (spec isArray and:[test class name == spec first and:[test selector == spec second]])
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5442
            ifTrue:[^true].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5443
        ].
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5444
    ^false
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5445
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5446
    "Created: / 03-06-2011 / 17:01:14 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  5447
! !
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  5448
12210
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5449
!ProjectDefinition class methodsFor:'private-extension handling'!
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5450
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5451
hasSavedOverwrittenMethods
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5452
    "true, if any of my methods was overwritten by another loaded package.
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5453
     These methods are now in my safe"
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5454
12208
0b65ddcb68f2 added: #hasSafedOverwrittenMethods
Michael Beyl <mb@exept.de>
parents: 12202
diff changeset
  5455
    ^ safeForOverwrittenMethods notEmptyOrNil
0b65ddcb68f2 added: #hasSafedOverwrittenMethods
Michael Beyl <mb@exept.de>
parents: 12202
diff changeset
  5456
!
0b65ddcb68f2 added: #hasSafedOverwrittenMethods
Michael Beyl <mb@exept.de>
parents: 12202
diff changeset
  5457
12213
73371949b807 overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents: 12210
diff changeset
  5458
methodOverwrittenBy:aMethod
73371949b807 overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents: 12210
diff changeset
  5459
    "return the (hidden) original method, which was located in another package
73371949b807 overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents: 12210
diff changeset
  5460
     and which got overwritten by one of my extension methods. Nil if there is none."
73371949b807 overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents: 12210
diff changeset
  5461
73371949b807 overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents: 12210
diff changeset
  5462
    |mclass selector oldPackage|
73371949b807 overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents: 12210
diff changeset
  5463
12218
a3662ecd1438 changed: #methodOverwrittenBy:
Claus Gittinger <cg@exept.de>
parents: 12213
diff changeset
  5464
    extensionOverwriteInfo isNil ifTrue:[^ nil].
a3662ecd1438 changed: #methodOverwrittenBy:
Claus Gittinger <cg@exept.de>
parents: 12213
diff changeset
  5465
12213
73371949b807 overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents: 12210
diff changeset
  5466
    mclass := aMethod mclass.
73371949b807 overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents: 12210
diff changeset
  5467
    selector := aMethod selector.
73371949b807 overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents: 12210
diff changeset
  5468
    oldPackage := extensionOverwriteInfo at:(mclass name,'>>',selector) ifAbsent:nil.
73371949b807 overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents: 12210
diff changeset
  5469
    oldPackage isNil ifTrue:[^ nil].
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5470
    ^ oldPackage asPackageId projectDefinitionClass
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5471
        savedOverwrittenMethodForClass:mclass selector:selector.
12213
73371949b807 overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents: 12210
diff changeset
  5472
!
73371949b807 overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents: 12210
diff changeset
  5473
12210
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5474
rememberOverwrittenExtensionMethods
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5475
    "before loading, tell other packages to keep a safe reference to any method
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5476
     which gets overloaded by me, and also remember here, whome I have overloaded.
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5477
     This allows for two things:
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5478
        a) correct fileout of the other base-package (for example, when checking in any of its class)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5479
        b) correct unloading of myself"
12210
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5480
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5481
    self extensionMethodNames pairWiseDo:[:className :selector |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5482
        |class oldMethod oldPackage defClass|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5483
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5484
        class := Smalltalk classNamed:className.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5485
        class notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5486
            oldMethod := class compiledMethodAt:selector.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5487
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5488
        oldMethod notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5489
            oldPackage := oldMethod package.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5490
            oldPackage ~= PackageId noProjectID ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5491
                defClass := oldPackage asPackageId projectDefinitionClass.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5492
                defClass notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5493
                    defClass rememberOverwrittenMethod:oldMethod inClass:class.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5494
                    extensionOverwriteInfo isNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5495
                        extensionOverwriteInfo := Dictionary new.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5496
                    ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5497
                    extensionOverwriteInfo at:(className,'>>',selector) put:oldPackage.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5498
                ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5499
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5500
        ].
12210
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5501
    ].
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5502
!
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5503
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5504
rememberOverwrittenMethod:oldMethod inClass:aClass
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5505
    "invoked from another projectDefinition, when that package is about to be loaded
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5506
     and about to overwrite one of my methods.
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5507
     I will save the method locally, to allow for correct fileout of this class/project or
12210
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5508
     to correctly reestablish my methods when the other package is unloaded later."
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5509
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5510
    |thisIsOneOfMyMethods selector|
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5511
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5512
    selector := oldMethod selector.
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5513
12293
983b9555f6e8 changed: #rememberOverwrittenMethod:inClass:
Claus Gittinger <cg@exept.de>
parents: 12286
diff changeset
  5514
    thisIsOneOfMyMethods := (self classNames includes:aClass theNonMetaclass name)
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5515
                            or:[ aClass isPrivate and:[ self classNames includes: aClass topOwningClass theNonMetaclass name ]].
12210
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5516
    thisIsOneOfMyMethods ifFalse:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5517
        self extensionMethodNames pairWiseDo:[:extClassName :extSelector |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5518
            extClassName = aClass name ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5519
                selector = extSelector ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5520
                    thisIsOneOfMyMethods := true
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5521
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5522
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5523
        ]
12210
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5524
    ].
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5525
    thisIsOneOfMyMethods ifFalse:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5526
        self error:'oops - this is not one of my methods' mayProceed:true.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5527
        ^ self
12210
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5528
    ].
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5529
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5530
    safeForOverwrittenMethods isNil ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5531
        safeForOverwrittenMethods := Dictionary new.
12210
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5532
    ].
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5533
    safeForOverwrittenMethods at:(aClass name -> selector) put:oldMethod.
12213
73371949b807 overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents: 12210
diff changeset
  5534
!
73371949b807 overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents: 12210
diff changeset
  5535
12624
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  5536
restoreOverwrittenExtensionMethods
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  5537
    "after unloading, tell other packages to restore any safed reference to any method
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  5538
     which got overloaded by me."
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  5539
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  5540
    self extensionMethodNames pairWiseDo:[:className :selector |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5541
        |class oldMethod oldPackage|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5542
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5543
        oldPackage := extensionOverwriteInfo at:(className,'>>',selector).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5544
        oldPackage notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5545
            class := Smalltalk classNamed:className.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5546
            class notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5547
                oldMethod := oldPackage savedOverwrittenMethodForClass:class selector:selector.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5548
                oldMethod notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5549
                    self breakPoint:#cg.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5550
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5551
            ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5552
        ].
12624
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  5553
    ].
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  5554
!
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  5555
12213
73371949b807 overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents: 12210
diff changeset
  5556
savedOverwrittenMethodForClass:aClass selector:aSelector
73371949b807 overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents: 12210
diff changeset
  5557
    "return one of my saved original methods"
73371949b807 overwrittenExtensionMethods handling
Claus Gittinger <cg@exept.de>
parents: 12210
diff changeset
  5558
13692
2dffef08a4ac changed: #savedOverwrittenMethodForClass:selector:
Stefan Vogel <sv@exept.de>
parents: 13689
diff changeset
  5559
    safeForOverwrittenMethods isNil ifTrue:[^ nil].
12274
a8ef1edeca71 changed:
Claus Gittinger <cg@exept.de>
parents: 12271
diff changeset
  5560
    ^ safeForOverwrittenMethods at:(aClass name,'>>',aSelector) ifAbsent:nil
12210
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5561
! !
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5562
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5563
!ProjectDefinition class methodsFor:'private-loading'!
48e154dad1a5 documentation;
Claus Gittinger <cg@exept.de>
parents: 12208
diff changeset
  5564
12262
24861bbf25fc added: #checkPrerequisitesForLoading
Claus Gittinger <cg@exept.de>
parents: 12251
diff changeset
  5565
checkPrerequisitesForLoading
12264
67d427702122 changed:
Claus Gittinger <cg@exept.de>
parents: 12263
diff changeset
  5566
    |classesAlreadyWarned|
67d427702122 changed:
Claus Gittinger <cg@exept.de>
parents: 12263
diff changeset
  5567
67d427702122 changed:
Claus Gittinger <cg@exept.de>
parents: 12263
diff changeset
  5568
    classesAlreadyWarned := Set new.
67d427702122 changed:
Claus Gittinger <cg@exept.de>
parents: 12263
diff changeset
  5569
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5570
    self extensionMethodNames
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5571
        pairWiseDo:[:className :selector |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5572
            |class |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5573
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5574
            class := Smalltalk classNamed:className.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5575
            class isNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5576
                (classesAlreadyWarned includes:className) ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5577
                    self error:'missing class for extension: ', className mayProceed:true.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5578
                    classesAlreadyWarned add:className.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5579
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5580
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5581
        ]
12263
c6d50824fbba comment/format in: #checkPrerequisitesForLoading
Claus Gittinger <cg@exept.de>
parents: 12262
diff changeset
  5582
c6d50824fbba comment/format in: #checkPrerequisitesForLoading
Claus Gittinger <cg@exept.de>
parents: 12262
diff changeset
  5583
    "/ todo: more needed here...
12731
ffec4d9573bc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12705
diff changeset
  5584
ffec4d9573bc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12705
diff changeset
  5585
    "
ffec4d9573bc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12705
diff changeset
  5586
     stx_libjavascript checkPrerequisitesForLoading
ffec4d9573bc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12705
diff changeset
  5587
    "
12262
24861bbf25fc added: #checkPrerequisitesForLoading
Claus Gittinger <cg@exept.de>
parents: 12251
diff changeset
  5588
!
24861bbf25fc added: #checkPrerequisitesForLoading
Claus Gittinger <cg@exept.de>
parents: 12251
diff changeset
  5589
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5590
executeHooks: hook
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5591
    "Execute all hooks annotate by given symbol. Currently supported
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5592
     hooks are: #preLoad, #postLoad, #preUnload."
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5593
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5594
    | cls |
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5595
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5596
    cls := self.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5597
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5598
    [ cls notNil ] whileTrue:[
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5599
        cls class selectorsAndMethodsDo:[:selector :method|
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5600
            (method annotationAt: hook) notNil ifTrue:[
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5601
                method numArgs == 0 ifTrue:[
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5602
                    self perform: selector
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5603
                ] ifFalse:[
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5604
                    self error:'Hook for %1 must have no arguments' mayProceed: true.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5605
                ]
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5606
            ]
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5607
        ].
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5608
        cls := cls superclass.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5609
    ].
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5610
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5611
    "Created: / 20-11-2012 / 23:00:13 / Jan Vrany <jan.vrany@fit.cvut.cz>"
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5612
    "Modified: / 27-11-2012 / 16:15:41 / Jan Vrany <jan.vrany@fit.cvut.cz>"
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5613
!
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  5614
12294
c46be62dee24 when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents: 12293
diff changeset
  5615
extensionOverwriteInfo
c46be62dee24 when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents: 12293
diff changeset
  5616
    ^ extensionOverwriteInfo
c46be62dee24 when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents: 12293
diff changeset
  5617
!
c46be62dee24 when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents: 12293
diff changeset
  5618
c46be62dee24 when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents: 12293
diff changeset
  5619
fetchSlotsFrom:myFirstIncarnation
c46be62dee24 when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents: 12293
diff changeset
  5620
    "this is invoked in a just loaded instance of myself,
c46be62dee24 when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents: 12293
diff changeset
  5621
     to fetch the safe and extensionInfo from my first incarnation"
c46be62dee24 when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents: 12293
diff changeset
  5622
c46be62dee24 when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents: 12293
diff changeset
  5623
    safeForOverwrittenMethods := myFirstIncarnation safeForOverwrittenMethods.
c46be62dee24 when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents: 12293
diff changeset
  5624
    extensionOverwriteInfo := myFirstIncarnation extensionOverwriteInfo.
c46be62dee24 when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents: 12293
diff changeset
  5625
!
c46be62dee24 when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents: 12293
diff changeset
  5626
13614
5606bfa8cbec added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13610
diff changeset
  5627
loadAllAutoloadedClasses
5606bfa8cbec added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13610
diff changeset
  5628
    self allClasses do:[:cls | cls autoload]
5606bfa8cbec added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13610
diff changeset
  5629
5606bfa8cbec added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13610
diff changeset
  5630
    "Created: / 21-08-2011 / 17:24:13 / cg"
5606bfa8cbec added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13610
diff changeset
  5631
!
5606bfa8cbec added: #loadAllAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13610
diff changeset
  5632
10399
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5633
loadAllClassesAsAutoloaded:asAutoloaded
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5634
    "load (fileIn) classes that should be present -
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5635
     install as autoloaded classes marked to be autoloaded.
10401
6682d28d2ec5 *** empty log message ***
Stefan Vogel <sv@exept.de>
parents: 10399
diff changeset
  5636
     If asAutoloaded == true, all classes will be installed as autoloaded, even if not marked.
6682d28d2ec5 *** empty log message ***
Stefan Vogel <sv@exept.de>
parents: 10399
diff changeset
  5637
6682d28d2ec5 *** empty log message ***
Stefan Vogel <sv@exept.de>
parents: 10399
diff changeset
  5638
     Answer true, if classes have been loaded"
12028
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  5639
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5640
    ^self loadAllClassesAsAutoloaded:asAutoloaded languages: ProgrammingLanguage all
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5641
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5642
    "Created: / 17-08-2006 / 01:01:14 / cg"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5643
    "Modified: / 26-10-2006 / 12:30:01 / cg"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5644
    "Modified: / 16-08-2009 / 13:31:40 / Jan Vrany <vranyj1@fel.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5645
    "Modified: / 19-06-2010 / 11:37:47 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5646
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5647
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5648
loadAllClassesAsAutoloaded:asAutoloaded languages: langs
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5649
    "load (fileIn) classes in given languages that should be present -
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5650
     install as autoloaded classes marked to be autoloaded.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5651
     If asAutoloaded == true, all classes will be installed as autoloaded, even if not marked.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5652
     langs should be collection of ProgrammingLanguage available in the system.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5653
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5654
     Answer true, if classes have been loaded"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5655
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5656
    |classNamesToLoad classNamesToAutoload classNamesToLangs hasClassesToLoad loadedClasses platformName
10399
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5657
     classesWhichFailedToLoad|
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5658
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5659
    platformName := OperatingSystem platformName.
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5660
    classNamesToLoad := OrderedCollection new.
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5661
    classNamesToAutoload := OrderedCollection new.
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5662
    classNamesToLangs := Dictionary new.
10399
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5663
12315
71599fb91dcf comment/format in: #packageDirectory
Claus Gittinger <cg@exept.de>
parents: 12314
diff changeset
  5664
    hasClassesToLoad := false.
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5665
    self classNamesAndAttributesDo:[:eachClassname :eachAttributes |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5666
        |eachClassnameSym isAutoload clsLangAttr clsLang cls |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5667
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5668
        eachClassnameSym := eachClassname asSymbol.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5669
        isAutoload := asAutoloaded or:[eachAttributes includes:#autoload].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5670
        clsLangAttr := eachAttributes detect:[:a|a isArray and: [a size == 2 and:[a first == #lang]]] ifNone:[nil].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5671
        clsLang := clsLangAttr
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5672
                    ifNil:[SmalltalkLanguage instance]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5673
                    ifNotNil:[ProgrammingLanguage named: clsLangAttr second ifNone:[nil]].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5674
        classNamesToLangs at: eachClassname put: clsLang.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5675
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5676
        "no need to (re-)load an existing class, but install if should be loaded"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5677
        cls := Smalltalk loadedClassNamed:eachClassnameSym.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5678
        ((cls isNil or:[cls isLoaded not and:[isAutoload not]]) and:[clsLang notNil and:[langs includes: clsLang]]) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5679
            (eachAttributes isEmpty
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5680
             or:[(eachAttributes size == 1 and:[isAutoload])
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5681
             or:[(eachAttributes includes:platformName)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5682
             or:[eachAttributes contains:[:a|a isArray]]]]) "/FIXME: Hack."
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5683
                ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5684
                    hasClassesToLoad := true.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5685
                    isAutoload ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5686
                        classNamesToAutoload add:eachClassnameSym.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5687
                    ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5688
                        classNamesToLoad add:eachClassnameSym.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5689
                    ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5690
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5691
        ].
10399
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5692
    ].
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5693
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5694
    hasClassesToLoad ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5695
        loadedClasses := OrderedCollection new.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5696
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5697
        self packageDirectory isNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5698
            classNamesToLoad notEmpty ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5699
                "required classes are missing.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5700
                 Autoloaded classes are considered as optional..."
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5701
                self
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5702
                    error:(self name,'[error] cannot install because packageDirectory is unknown for missing classes: ', classNamesToLoad printString)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5703
                    mayProceed:true.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5704
                ^ false.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5705
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5706
            (self name,'[info] cannot install autoloaded classes because packageDirectory is unknown') infoPrintCR.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5707
            ^ true.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5708
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5709
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5710
        "we need the abbreviations, since sometimes there is no 1-to-1 mapping
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5711
         of class name to file name"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5712
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5713
        Smalltalk recursiveReadAllAbbreviationsFrom:self packageDirectory maxLevels:1.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5714
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5715
        "install autoloaded classes first,
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5716
         some others may depend on them"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5717
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5718
        classNamesToAutoload withIndexDo:[:eachClassName :index|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5719
            ActivityNotification
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5720
                raiseRequestWith: ((100 / classNamesToAutoload size ) * index) rounded
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5721
                errorString: 'Autoloading class ', eachClassName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5722
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5723
            self loadClass: eachClassName asAutoloaded: true language: (classNamesToLangs at: eachClassName) .
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5724
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5725
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5726
        classesWhichFailedToLoad := OrderedCollection new.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5727
        classNamesToLoad notEmpty ifTrue:[
14021
11d015697e44 changed:8 methods
Stefan Vogel <sv@exept.de>
parents: 13968
diff changeset
  5728
            Verbose ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5729
                Transcript showCR:('  %1: filing in missing classes (%2) individually...'
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5730
                                    bindWith:self name with:classNamesToLoad size).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5731
            ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5732
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5733
        classNamesToLoad withIndexDo:[:eachClassName :index|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5734
            |cls|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5735
            ActivityNotification
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5736
                raiseRequestWith: ((100 / classNamesToLoad size) * index) rounded
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5737
                errorString: 'Loading class ', eachClassName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5738
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5739
            Error handle:[:ex |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5740
                "maybe, fileIn failed, because the load order is wrong.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5741
                 Work around this by installing the class as autoloaded and
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5742
                 loading it"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5743
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5744
                classesWhichFailedToLoad add:eachClassName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5745
                self loadClass: eachClassName asAutoloaded: true language: (classNamesToLangs at: eachClassName).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5746
            ] do:[
14021
11d015697e44 changed:8 methods
Stefan Vogel <sv@exept.de>
parents: 13968
diff changeset
  5747
                Verbose ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5748
                    Transcript showCR:('  %1: filing in %2...' bindWith:self name with:eachClassName).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5749
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5750
                cls := self loadClass: eachClassName asAutoloaded: false language: (classNamesToLangs at: eachClassName).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5751
                cls notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5752
                    loadedClasses add:cls
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5753
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5754
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5755
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5756
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5757
        classesWhichFailedToLoad do:[:eachClassName |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5758
            (Smalltalk at:eachClassName) autoload.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5759
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5760
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5761
        loadedClasses do:[:eachLoadedClass |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5762
            "do not initialize, if initialize method is inherited"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5763
            (eachLoadedClass theMetaclass includesSelector:#initialize) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5764
                eachLoadedClass initialize
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5765
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5766
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5767
        ^ true.
10399
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5768
    ].
10401
6682d28d2ec5 *** empty log message ***
Stefan Vogel <sv@exept.de>
parents: 10399
diff changeset
  5769
    ^ false.
10399
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5770
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5771
    "Modified: / 26-10-2006 / 12:30:01 / cg"
12028
211dd98cec4e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 11982
diff changeset
  5772
    "Modified: / 16-08-2009 / 13:31:40 / Jan Vrany <vranyj1@fel.cvut.cz>"
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5773
    "Created: / 19-06-2010 / 11:35:49 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5774
    "Modified: / 19-06-2010 / 15:06:20 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5775
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5776
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5777
loadClass: className asAutoloaded: asAutoloaded language: lang
13592
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  5778
    | packageDir classFile entry category numClassInstVars cls|
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  5779
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  5780
    "Handle smalltalk classes specially to provide backward compatibility"
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5781
    lang isSmalltalk ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5782
        entry := self abbrevs at: className ifAbsent:[nil].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5783
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5784
        asAutoloaded ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5785
            category := entry isNil ifTrue:[#autoloaded] ifFalse:[entry category].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5786
            numClassInstVars := entry isNil ifTrue:[0] ifFalse:[entry numClassInstVars].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5787
            cls := Smalltalk
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5788
                installAutoloadedClassNamed: className
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5789
                category: category
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5790
                package: self package
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5791
                revision: nil
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5792
                numClassInstVars:numClassInstVars.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5793
            entry notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5794
                cls setClassFilename:(entry fileName,'.st').
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5795
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5796
            ^ cls.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5797
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5798
        ^ Smalltalk
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5799
            fileInClass:className
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5800
            package:self package
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5801
            initialize:false
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5802
            lazy:false
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5803
            silent:true
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5804
    ].
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5805
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5806
    "For non-smalltalk language do"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5807
    asAutoloaded ifTrue:[^self error:'Only Smalltalk classes may be autoloaded (yet)'].
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5808
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5809
    packageDir := self packageDirectory asFilename.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5810
    classFile := packageDir / ((Smalltalk fileNameForClass: className) , '.' , lang sourceFileSuffix).
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5811
    classFile exists ifFalse:[^nil].
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5812
    lang fileIn: classFile.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5813
    ^nil "FIXME: should return the class"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5814
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5815
    "Created: / 19-06-2010 / 09:11:41 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5816
    "Modified: / 06-03-2011 / 18:29:08 / Jan Vrany <jan.vrany@fit.cvut.cz>"
13592
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  5817
    "Modified: / 18-08-2011 / 14:22:15 / cg"
10399
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5818
!
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5819
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5820
loadClassLibrary
10430
fc34b59eca00 Don not try to load a class library already linked to the executable
Stefan Vogel <sv@exept.de>
parents: 10426
diff changeset
  5821
    "try to load a binary class library
fc34b59eca00 Don not try to load a class library already linked to the executable
Stefan Vogel <sv@exept.de>
parents: 10426
diff changeset
  5822
     Return true if ok, false if not."
fc34b59eca00 Don not try to load a class library already linked to the executable
Stefan Vogel <sv@exept.de>
parents: 10426
diff changeset
  5823
12295
fbd977f707de *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12294
diff changeset
  5824
    |libraryName|
10430
fc34b59eca00 Don not try to load a class library already linked to the executable
Stefan Vogel <sv@exept.de>
parents: 10426
diff changeset
  5825
fc34b59eca00 Don not try to load a class library already linked to the executable
Stefan Vogel <sv@exept.de>
parents: 10426
diff changeset
  5826
    libraryName := self libraryName.
fc34b59eca00 Don not try to load a class library already linked to the executable
Stefan Vogel <sv@exept.de>
parents: 10426
diff changeset
  5827
fc34b59eca00 Don not try to load a class library already linked to the executable
Stefan Vogel <sv@exept.de>
parents: 10426
diff changeset
  5828
    (Smalltalk isClassLibraryLoaded:libraryName) ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5829
        "already loaded"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5830
        ^ true
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5831
    ].
14021
11d015697e44 changed:8 methods
Stefan Vogel <sv@exept.de>
parents: 13968
diff changeset
  5832
    Verbose ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5833
        Transcript showCR:('  %1: loading classLibrary...' bindWith:self name).
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5834
    ].
12743
c39a4553e1ed changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12742
diff changeset
  5835
    self activityNotification:'Loading classLibrary'.
c39a4553e1ed changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12742
diff changeset
  5836
12295
fbd977f707de *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12294
diff changeset
  5837
    ^ Smalltalk fileInClassLibrary:libraryName inPackage:self package.
10399
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5838
!
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5839
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5840
loadExtensions
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5841
    "load extension methods - do not load if they are already present"
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5842
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5843
    self hasAllExtensionsLoaded ifFalse:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5844
        self breakPoint:#cg.
14021
11d015697e44 changed:8 methods
Stefan Vogel <sv@exept.de>
parents: 13968
diff changeset
  5845
        Verbose ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5846
            Transcript showCR:('  %1: filing in extensions...' bindWith:self name).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5847
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5848
        Smalltalk loadExtensionsForPackage:self package.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5849
        ^ true.
10399
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5850
    ].
10401
6682d28d2ec5 *** empty log message ***
Stefan Vogel <sv@exept.de>
parents: 10399
diff changeset
  5851
    ^ false.
10399
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5852
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5853
    "Created: / 17-08-2006 / 00:21:39 / cg"
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5854
!
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5855
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5856
loadPackages:aListOfPackages asAutoloaded:asAutoloaded
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5857
    "load some packages (at least the projectDefinitions and their extensions).
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5858
     If asAutoloaded == true, classes will be only installed as autoloaded."
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5859
12558
1c30499cb772 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12555
diff changeset
  5860
    PackagesBeingLoaded isNil ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5861
        PackagesBeingLoaded := Set new
12558
1c30499cb772 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12555
diff changeset
  5862
    ].
14764
2497dc2ff1ab tuned prereq-package loading
Claus Gittinger <cg@exept.de>
parents: 14748
diff changeset
  5863
    Class withoutUpdatingChangesDo:[
14790
28d875953487 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14789
diff changeset
  5864
        aListOfPackages do:[:eachPackageID |
14764
2497dc2ff1ab tuned prereq-package loading
Claus Gittinger <cg@exept.de>
parents: 14748
diff changeset
  5865
            |cls|
2497dc2ff1ab tuned prereq-package loading
Claus Gittinger <cg@exept.de>
parents: 14748
diff changeset
  5866
14812
bdbf34a42482 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14809
diff changeset
  5867
            cls := self definitionClassForPackage:eachPackageID.
bdbf34a42482 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14809
diff changeset
  5868
            (cls isNil or:[cls isLoaded not or:[cls projectIsLoaded not]]) ifTrue:[                        
14764
2497dc2ff1ab tuned prereq-package loading
Claus Gittinger <cg@exept.de>
parents: 14748
diff changeset
  5869
                (PackagesBeingLoaded includes:eachPackageID) ifFalse:[
2497dc2ff1ab tuned prereq-package loading
Claus Gittinger <cg@exept.de>
parents: 14748
diff changeset
  5870
                    PackagesBeingLoaded add:eachPackageID.
2497dc2ff1ab tuned prereq-package loading
Claus Gittinger <cg@exept.de>
parents: 14748
diff changeset
  5871
                    [
14521
bfca62eee2ea class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14510
diff changeset
  5872
                        Smalltalk loadPackage:eachPackageID asAutoloaded:asAutoloaded.
14764
2497dc2ff1ab tuned prereq-package loading
Claus Gittinger <cg@exept.de>
parents: 14748
diff changeset
  5873
                    ] ensure:[
2497dc2ff1ab tuned prereq-package loading
Claus Gittinger <cg@exept.de>
parents: 14748
diff changeset
  5874
                        PackagesBeingLoaded remove:eachPackageID ifAbsent:[].
14521
bfca62eee2ea class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14510
diff changeset
  5875
                    ]
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5876
                ]
14764
2497dc2ff1ab tuned prereq-package loading
Claus Gittinger <cg@exept.de>
parents: 14748
diff changeset
  5877
            ]
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5878
        ].
10399
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5879
    ].
13166
aa93e348e5d3 changed: #loadPackages:asAutoloaded:
Claus Gittinger <cg@exept.de>
parents: 13154
diff changeset
  5880
13167
658fc3b51af4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13166
diff changeset
  5881
    "Modified: / 09-12-2010 / 12:36:17 / cg"
10399
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5882
!
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5883
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5884
loadPreRequisitesAsAutoloaded:asAutoloaded
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5885
    "load other packages (at least the projectDefinitions and their extensions)"
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5886
12743
c39a4553e1ed changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12742
diff changeset
  5887
    |prereq|
c39a4553e1ed changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12742
diff changeset
  5888
c39a4553e1ed changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12742
diff changeset
  5889
    prereq := self effectivePreRequisites.
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  5890
    prereq notEmpty ifTrue:[
14021
11d015697e44 changed:8 methods
Stefan Vogel <sv@exept.de>
parents: 13968
diff changeset
  5891
        Verbose ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5892
            Transcript showCR:('  %1 loading prerequisites...' bindWith:self name).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5893
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5894
        self loadPackages:prereq asAutoloaded:asAutoloaded
12743
c39a4553e1ed changed:5 methods
Claus Gittinger <cg@exept.de>
parents: 12742
diff changeset
  5895
    ].
10399
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5896
!
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5897
12596
5ed54f811010 added: #loadSubProjects
Claus Gittinger <cg@exept.de>
parents: 12575
diff changeset
  5898
loadSubProjects
5ed54f811010 added: #loadSubProjects
Claus Gittinger <cg@exept.de>
parents: 12575
diff changeset
  5899
    "load other packages (at least the projectDefinitions and their extensions)"
5ed54f811010 added: #loadSubProjects
Claus Gittinger <cg@exept.de>
parents: 12575
diff changeset
  5900
5ed54f811010 added: #loadSubProjects
Claus Gittinger <cg@exept.de>
parents: 12575
diff changeset
  5901
    self loadSubProjectsAsAutoloaded:false.
5ed54f811010 added: #loadSubProjects
Claus Gittinger <cg@exept.de>
parents: 12575
diff changeset
  5902
    self subProjects do:[:p |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5903
        |subDef|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5904
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5905
        subDef := self definitionClassForPackage:p.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5906
        subDef notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5907
            subDef loadSubProjects
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5908
        ].
12596
5ed54f811010 added: #loadSubProjects
Claus Gittinger <cg@exept.de>
parents: 12575
diff changeset
  5909
    ].
5ed54f811010 added: #loadSubProjects
Claus Gittinger <cg@exept.de>
parents: 12575
diff changeset
  5910
!
5ed54f811010 added: #loadSubProjects
Claus Gittinger <cg@exept.de>
parents: 12575
diff changeset
  5911
10399
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5912
loadSubProjectsAsAutoloaded:asAutoloaded
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5913
    "load other packages (at least the projectDefinitions and their extensions)"
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5914
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5915
    self loadPackages:(self subProjects) asAutoloaded:asAutoloaded
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5916
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  5917
    "Modified: / 25-10-2006 / 17:51:58 / cg"
10434
25f76184bf81 project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents: 10433
diff changeset
  5918
!
25f76184bf81 project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents: 10433
diff changeset
  5919
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5920
old_loadAllClassesAsAutoloaded:asAutoloaded
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5921
    "load (fileIn) classes that should be present -
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5922
     install as autoloaded classes marked to be autoloaded.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5923
     If asAutoloaded == true, all classes will be installed as autoloaded, even if not marked.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5924
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5925
     Answer true, if classes have been loaded"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5926
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5927
    |classNamesToLoad classNamesToAutoload hasClassesToLoad loadedClasses platformName
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5928
     classesWhichFailedToLoad|
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5929
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5930
    platformName := OperatingSystem platformName.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5931
    classNamesToLoad := OrderedCollection new.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5932
    classNamesToAutoload := OrderedCollection new.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5933
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5934
    hasClassesToLoad := false.
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  5935
    self classNamesAndAttributesDo:[:eachClassname :eachAttributes |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5936
        |eachClassnameSym isAutoload cls|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5937
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5938
        eachClassnameSym := eachClassname asSymbol.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5939
        isAutoload := asAutoloaded or:[eachAttributes includes:#autoload].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5940
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5941
        "no need to (re-)load an existing class, but install if should be loaded"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5942
        cls := Smalltalk loadedClassNamed:eachClassnameSym.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5943
        (cls isNil or:[cls isLoaded not and:[isAutoload not]]) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5944
            (eachAttributes isEmpty
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5945
             or:[(eachAttributes size == 1 and:[isAutoload])
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5946
             or:[eachAttributes includes:platformName]]) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5947
                hasClassesToLoad := true.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5948
                isAutoload ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5949
                    classNamesToAutoload add:eachClassnameSym.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5950
                ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5951
                    classNamesToLoad add:eachClassnameSym.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5952
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5953
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5954
        ].
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5955
    ].
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5956
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  5957
    hasClassesToLoad ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5958
        loadedClasses := OrderedCollection new.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5959
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5960
        self packageDirectory isNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5961
            self
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5962
                error:(self name,'[error] cannot install because packageDirectory is unknown')
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5963
                mayProceed:true.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5964
            ^ false.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5965
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5966
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5967
        "we need the abbreviations, since sometimes there is no 1-to-1 mapping
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5968
         of class name to file name"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5969
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5970
        Smalltalk recursiveReadAllAbbreviationsFrom:self packageDirectory maxLevels:1.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5971
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5972
        "install autoloaded classes first,
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5973
         some others may depend on them"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5974
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5975
        classNamesToAutoload withIndexDo:[:eachClassName :index|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5976
            ActivityNotification
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5977
                raiseRequestWith: ((100 / classNamesToAutoload size ) * index) rounded
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5978
                errorString: 'Autoloading class ', eachClassName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5979
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5980
            Smalltalk
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5981
                installAutoloadedClassNamed:eachClassName
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5982
                category:#autoloaded    "FIXME"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5983
                package:self package
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5984
                revision:nil
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5985
                numClassInstVars:0.     "FIXME"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5986
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5987
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5988
        classesWhichFailedToLoad := OrderedCollection new.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5989
        classNamesToLoad notEmpty ifTrue:[
14021
11d015697e44 changed:8 methods
Stefan Vogel <sv@exept.de>
parents: 13968
diff changeset
  5990
            Verbose ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5991
                Transcript showCR:('  %1: filing in missing classes (%2) individually...'
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5992
                                    bindWith:self name with:classNamesToLoad size).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5993
            ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5994
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5995
        classNamesToLoad withIndexDo:[:eachClassName :index|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5996
            |cls|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5997
            ActivityNotification
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5998
                raiseRequestWith: ((100 / classNamesToLoad size) * index) rounded
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  5999
                errorString: 'Loading class ', eachClassName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6000
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6001
            Error handle:[:ex |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6002
                "maybe, fileIn failed, because the load order is wrong.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6003
                 Work around this by installing the class as autoloaded and
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6004
                 loading it"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6005
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6006
                classesWhichFailedToLoad add:eachClassName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6007
                Smalltalk
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6008
                    installAutoloadedClassNamed:eachClassName
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6009
                    category:#autoloaded    "FIXME"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6010
                    package:self package
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6011
                    revision:nil
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6012
                    numClassInstVars:0.     "FIXME"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6013
            ] do:[
14021
11d015697e44 changed:8 methods
Stefan Vogel <sv@exept.de>
parents: 13968
diff changeset
  6014
                Verbose ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6015
                    Transcript showCR:('  %1: filing in %2...' bindWith:self name with:eachClassName).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6016
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6017
                cls := Smalltalk
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6018
                            fileInClass:eachClassName
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6019
                            package:self package
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6020
                            initialize:false
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6021
                            lazy:false
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6022
                            silent:true.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6023
                cls notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6024
                    loadedClasses add:cls
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6025
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6026
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6027
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6028
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6029
        classesWhichFailedToLoad do:[:eachClassName |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6030
            (Smalltalk at:eachClassName) autoload.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6031
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6032
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6033
        loadedClasses do:[:eachLoadedClass |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6034
            "do not initialize, if initialize method is inherited"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6035
            (eachLoadedClass theMetaclass includesSelector:#initialize) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6036
                eachLoadedClass initialize
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6037
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6038
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6039
        ^ true.
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6040
    ].
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6041
    ^ false.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6042
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6043
    "Modified: / 26-10-2006 / 12:30:01 / cg"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6044
    "Modified: / 16-08-2009 / 13:31:40 / Jan Vrany <vranyj1@fel.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6045
    "Created: / 19-06-2010 / 11:36:06 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6046
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6047
12294
c46be62dee24 when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents: 12293
diff changeset
  6048
safeForOverwrittenMethods
c46be62dee24 when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents: 12293
diff changeset
  6049
    ^ safeForOverwrittenMethods
c46be62dee24 when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents: 12293
diff changeset
  6050
!
c46be62dee24 when loading a class, the original definition's state is lost; move it over
Claus Gittinger <cg@exept.de>
parents: 12293
diff changeset
  6051
12624
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  6052
unloadAllClasses
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  6053
    Transcript showCR:'unloading not yet fully supported'
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  6054
!
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  6055
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  6056
unloadClassLibrary
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  6057
    Transcript showCR:'unloading not yet fully supported'
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  6058
!
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  6059
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  6060
unloadSubProjects
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  6061
    "unload other packages"
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  6062
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  6063
    self subProjects do:[:p |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6064
        |subDef|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6065
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6066
        subDef := self definitionClassForPackage:p.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6067
        subDef notNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6068
            subDef unloadSubProjects.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6069
            subDef unloadPackage.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6070
        ].
12624
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  6071
    ].
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  6072
!
Claus Gittinger <cg@exept.de>
parents: 12596
diff changeset
  6073
10434
25f76184bf81 project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents: 10433
diff changeset
  6074
update:anAspectSymbol with:argument from:changedObject
25f76184bf81 project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents: 10433
diff changeset
  6075
    "when any of my class methods is changed, we mark the project as unloaded.
12926
620ef12f673c comment/format in: #update:with:from:
Stefan Vogel <sv@exept.de>
parents: 12856
diff changeset
  6076
     May be some more classes have to be loaded"
10434
25f76184bf81 project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents: 10433
diff changeset
  6077
25f76184bf81 project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents: 10433
diff changeset
  6078
    (changedObject == self class and:[anAspectSymbol == #methodDictionary]) ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6079
        self projectIsLoaded:false.
10434
25f76184bf81 project definition change marks project as unloaded
Stefan Vogel <sv@exept.de>
parents: 10433
diff changeset
  6080
    ]
10399
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  6081
! !
6c16947a05ca Allow to load all classes of a project as autoloaded
Stefan Vogel <sv@exept.de>
parents: 10397
diff changeset
  6082
11147
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6083
!ProjectDefinition class methodsFor:'private-prerequisites'!
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6084
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6085
addReferencesToClassesFromGlobalsIn:aSetOfClasses to:usedClassReasons
12371
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
  6086
    "helper for searchForPreRequisites"
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
  6087
11147
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6088
    aSetOfClasses
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6089
        do:[:aClass |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6090
            self
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6091
                addReferencesToClassesFromGlobalsInMethods:
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6092
                    (aClass theNonMetaclass methodDictionary values
14510
5274ba4185d8 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14361
diff changeset
  6093
                        select:[:m | m isExtension not])
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6094
                to:usedClassReasons.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6095
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6096
            self
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6097
                addReferencesToClassesFromGlobalsInMethods:
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6098
                    (aClass theMetaclass methodDictionary values
14510
5274ba4185d8 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14361
diff changeset
  6099
                        select:[:m | m isExtension not])
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6100
                to:usedClassReasons.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6101
        ].
11147
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6102
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6103
    "Modified: / 10-10-2006 / 23:03:45 / cg"
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6104
!
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6105
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6106
addReferencesToClassesFromGlobalsInMethods:someMethods to:usedClassReasons
12371
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
  6107
    "helper for searchForPreRequisites"
Claus Gittinger <cg@exept.de>
parents: 12370
diff changeset
  6108
11147
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6109
    someMethods do:[:method |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6110
        |resources|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6111
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6112
        resources := method resources.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6113
        (resources isNil
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6114
        or:[ ((resources includesKey:#'ignoreInPrerequisites') not
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6115
              and:[(resources includesKey:#'example') not])])
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6116
        ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6117
            method usedGlobals
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6118
                do:[:global |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6119
                    |globalsName usedClass|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6120
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6121
                    globalsName := global asSymbol.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6122
                    usedClass := Smalltalk at:globalsName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6123
                    (usedClass notNil and:[usedClass isClass and:[usedClass isNameSpace not]]) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6124
                        usedClass name == globalsName ifTrue:[ "/ skip aliases
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6125
                            (usedClassReasons at:usedClass ifAbsentPut:[Set new])
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6126
                                add:(usedClass name, ' - referenced by ', method mclass name,'>>',method selector)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6127
                        ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6128
                    ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6129
                ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6130
            ]
11147
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6131
    ]
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6132
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6133
    "Created: / 10-10-2006 / 23:00:07 / cg"
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6134
    "Modified: / 30-05-2007 / 12:48:30 / cg"
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6135
!
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6136
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6137
allPreRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6138
    "answer all (recursive) prerequisite project ids of myself - in random order."
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6139
    
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6140
    ^ self 
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6141
        allPreRequisitesWithParentDo:[:parent :prereq | 
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6142
            prereq = self package ifTrue:[
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6143
                Transcript showCR:('oops: %1 depends on itself' bindWith:prereq)
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6144
            ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6145
        ]
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6146
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6147
    "
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6148
     stx_libbasic allPreRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6149
     stx_libbasic2 allPreRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6150
     stx_libview2 allPreRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6151
     ubs_application allPreRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6152
     ubs_application allPreRequisitesSorted
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6153
     exept_expecco_application allPreRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6154
     exept_expeccoNET_application allPreRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6155
     alspa_batch_application allPreRequisites"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6156
    "Modified: / 13-04-2011 / 15:30:45 / sr"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6157
    "Modified (comment): / 06-09-2011 / 08:26:06 / cg"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6158
!
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6159
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6160
allPreRequisitesSorted
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6161
    "answer all the prerequisites of this projects sorted in
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6162
     the order they are needed.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6163
     Use this to e.g. compile packages in the dependency order"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6164
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6165
    |allPreRequisites orderedTuples effective sortedPackages|
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6166
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6167
    orderedTuples := OrderedCollection new.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6168
    allPreRequisites := self allPreRequisites.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6169
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  6170
    "/JV@2013-03-13: Added asSortedCollection to make the order of packages
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  6171
    "/as stable as possible. Makes merging of makefiles a lot easier.
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  6172
    allPreRequisites asSortedCollection do:[:eachPackageID |
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6173
        |def|
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6174
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6175
        self assert:(eachPackageID ~= self package).
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6176
        orderedTuples add:(Array with:eachPackageID with:self package).
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6177
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6178
        def := self definitionClassForPackage:eachPackageID.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6179
        def isNil ifTrue:[
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6180
            Transcript showCR:'Warning: no definition class for package: ', eachPackageID.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6181
            effective := (self searchForPreRequisites: eachPackageID) keys.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6182
        ] ifFalse:[
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6183
            "extensionPackages should alread be in the #mandatoryPreRequisites"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6184
            effective := def effectivePreRequisites union:def extensionPackages.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6185
            effective do:[:eachPrerequisitePackageID|
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6186
                self assert:(eachPrerequisitePackageID ~= eachPackageID).
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6187
                orderedTuples add:(Array with:eachPrerequisitePackageID with:eachPackageID).
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6188
            ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6189
        ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6190
    ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6191
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6192
    (orderedTuples detect:[:el | el first = el second] ifNone:nil) notNil ifTrue:[self halt].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6193
    sortedPackages := orderedTuples topologicalSort.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6194
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6195
    "packages which only result from extension methods are used for computing the sort order,
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6196
     but they are not added, if not present in the first place"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6197
    ^ sortedPackages select:[:eachProject| allPreRequisites includes:eachProject]
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6198
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6199
    "
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6200
     stx_libbasic allPreRequisitesSorted
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6201
     stx_libbasic2 allPreRequisitesSorted
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6202
     stx_libwidg2 allPreRequisitesSorted
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  6203
     exept_expecco allPreRequisitesSorted
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6204
     alspa_batch_application allPreRequisitesSorted
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6205
     ubs_application allPreRequisitesSorted
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6206
    "
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6207
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6208
    "Modified: / 13-04-2011 / 15:19:13 / sr"
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  6209
    "Modified (comment): / 13-03-2013 / 00:40:55 / Jan Vrany <jan.vrany@fit.cvut.cz>"
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6210
!
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6211
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6212
allPreRequisitesWithParentDo:aBlock
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6213
    "answer all (recursive) prerequisite project ids of myself - in random order.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6214
     If we exclude a project, but one of our prerequisite projects depends on it,
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6215
     then what ????"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6216
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6217
    |setOfAllPreRequisites toAdd|
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6218
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6219
    setOfAllPreRequisites := Set new.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6220
    toAdd := Set withAll:self effectivePreRequisites.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6221
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6222
    "is a subproject really a prerequisite??
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6223
     No, it works the other way: parent projects are prerequisites of sub projects,
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6224
     so the following line has been deleted.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6225
     Unfortunately the meaning of 'subproject' has never been well defined. SV."
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6226
"/    toAdd addAll:self effectiveSubProjects.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6227
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6228
    [toAdd notEmpty] whileTrue:[
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6229
        |aPreRequisiteProjectID def|
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6230
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6231
        aPreRequisiteProjectID := toAdd removeFirst.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6232
        (setOfAllPreRequisites includes:aPreRequisiteProjectID) ifFalse:[
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6233
            setOfAllPreRequisites add:aPreRequisiteProjectID.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6234
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6235
            def := self definitionClassForPackage:aPreRequisiteProjectID.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6236
            def isNil ifTrue:[
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6237
                Transcript showCR:'ProjectDefinition ', aPreRequisiteProjectID, ' is missing - cannot find its preRequisites.'.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6238
            ] ifFalse:[
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6239
                def effectivePreRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6240
                    select:[:eachSubPreRequisite | (setOfAllPreRequisites includes:eachSubPreRequisite) not]
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6241
                    thenDo:[:eachSubPreRequisite |
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6242
                                Verbose == true ifTrue:[
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6243
                                    Transcript show:'ProjectDefinition preRequisites: '; showCR:(aPreRequisiteProjectID, ' requires ', eachSubPreRequisite).
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6244
                                ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6245
                                aBlock value:def value:eachSubPreRequisite.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6246
                                toAdd add:eachSubPreRequisite
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6247
                           ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6248
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6249
                "but subprojects of our prerequisites are also prerequisites"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6250
                def effectiveSubProjects
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6251
                    select:[:eachSubSubRequisite | eachSubSubRequisite ~= self package and:[ (setOfAllPreRequisites includes:eachSubSubRequisite) not ]]
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6252
                    thenDo:[:eachSubSubRequisite |
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6253
                                Verbose == true ifTrue:[
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6254
                                    Transcript show:'ProjectDefinition preRequisites: '; showCR:(aPreRequisiteProjectID, ' hasSub ', eachSubSubRequisite).
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6255
                                ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6256
                                aBlock value:def value:eachSubSubRequisite.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6257
                                toAdd add:eachSubSubRequisite
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6258
                           ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6259
            ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6260
        ]
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6261
    ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6262
    ^ setOfAllPreRequisites.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6263
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6264
    "
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6265
     stx_libbasic allPreRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6266
     stx_libbasic2 allPreRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6267
     stx_libview2 allPreRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6268
     ubs_application allPreRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6269
     ubs_application allPreRequisitesSorted
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6270
     exept_expecco_application allPreRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6271
     exept_expeccoNET_application allPreRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6272
     alspa_batch_application allPreRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6273
    "
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6274
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6275
    "Created: / 13-04-2011 / 15:23:21 / sr"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6276
    "Modified: / 20-07-2012 / 18:29:31 / cg"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6277
!
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6278
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6279
effectivePreRequisites
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6280
    "get the preRequisites, that are not excluded.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6281
     This method appears to be obsolete, because its functionality
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6282
     is now included in #preRequisites.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6283
     But is hat to be kept for backward compatibilty with old
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6284
     existant subclasses."
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6285
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6286
    self mandatoryPreRequisites notEmpty ifTrue:[
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6287
        "this is a new subclass - avoid overhead"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6288
        ^ self preRequisites.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6289
    ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6290
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6291
    "I am an old sublclass, where #preRequisites returns a plain array"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6292
    ^ Set new
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6293
        addAll:self preRequisites;
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6294
        addAll:self includedInPreRequisites;
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6295
        removeAllFoundIn:self excludedFromPreRequisites;
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6296
        remove:self package ifAbsent:[];
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6297
        yourself.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6298
!
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6299
11147
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6300
searchForPreRequisites
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6301
    "answer a Dictionary where the keys are the prerequisite package for this package
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6302
     and the values are a Set of reasons, why each package is required"
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6303
13635
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6304
    ^ self searchForPreRequisites:self package withSubProjects:true
11147
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6305
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6306
    "
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6307
     self searchForPreRequisites
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6308
     stx_libbasic3 searchForPreRequisites
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6309
     bosch_dapasx_Application searchForPreRequisites
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6310
     bosch_dapasx_pav_browser searchForPreRequisites
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6311
    "
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6312
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6313
    "Created: / 07-08-2006 / 20:42:39 / fm"
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6314
    "Modified: / 07-08-2006 / 21:56:25 / fm"
13635
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6315
    "Modified: / 06-09-2011 / 08:30:43 / cg"
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6316
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6317
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6318
searchForPreRequisites: packageId
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6319
    "answer a Dictionary where the keys are the prerequisite package for this package
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6320
     and the values are a Set of reasons, why each package is required"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6321
13635
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6322
    ^ self searchForPreRequisites: packageId withSubProjects:false
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6323
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6324
    "
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6325
     self searchForPreRequisites
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6326
     self searchForPreRequisites:#'stx:libwidg3'
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6327
     bosch_dapasx_Application searchForPreRequisites
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6328
     bosch_dapasx_pav_browser searchForPreRequisites
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6329
    "
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6330
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6331
    "Modified: / 07-08-2006 / 21:56:25 / fm"
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6332
    "Created: / 17-11-2010 / 18:27:42 / Jan Vrany <jan.vrany@fit.cvut.cz>"
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6333
    "Modified: / 06-09-2011 / 08:30:20 / cg"
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6334
!
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6335
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6336
searchForPreRequisites:packageId withSubProjects:withSubProjectsBoolean
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6337
    "answer a Dictionary where the keys are the prerequisite package for this package
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6338
     and the values are a Set of reasons, why each package is required"
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6339
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6340
    |requiredClasses mandatoryClassesForLoadingWithReasons referencedClassesWithReasons ignoredPackages packageExtractionBlock|
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6341
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6342
    mandatoryClassesForLoadingWithReasons := Dictionary new.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6343
    referencedClassesWithReasons := Dictionary new.
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6344
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6345
    "my classes are required"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6346
    requiredClasses := (self searchForClassesWithProject: packageId) asSet.
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6347
13635
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6348
    withSubProjectsBoolean ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6349
        "my subproject's classes are required"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6350
        self subProjects do:[:eachProjectName |
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6351
            requiredClasses addAll:(self searchForClassesWithProject:eachProjectName asSymbol)
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6352
        ].
13635
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6353
    ].
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6354
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6355
    "all superclasses of my classes and my subProject's classes are mandatory"
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  6356
    requiredClasses do:[:cls |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6357
        cls allSuperclassesDo:[:eachSuperclass |
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6358
            (mandatoryClassesForLoadingWithReasons at: eachSuperclass ifAbsentPut:[OrderedSet new])
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6359
                add: (eachSuperclass name, ' - superclass of ', cls name).
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6360
        ]
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6361
    ].
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6362
    "all classes for which I define extensions are mandatory"
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6363
    self allExtensionClasses do:[:eachExtendedClass |
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6364
        (mandatoryClassesForLoadingWithReasons at:eachExtendedClass ifAbsentPut:[OrderedSet new])
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6365
            add: (eachExtendedClass name, ' - extended').
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6366
        eachExtendedClass allSuperclassesDo:[:eachSuperclass |
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6367
            (mandatoryClassesForLoadingWithReasons at: eachSuperclass ifAbsentPut:[OrderedSet new])
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6368
                add: (eachSuperclass name, ' - superclass of extended ', eachExtendedClass name).
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6369
        ]
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6370
    ].
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6371
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6372
    "all classes referenced by my classes or my subproject's classes
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6373
     are required. But:
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6374
         only search for locals refered to by my methods (assuming that superclasses'
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6375
         prerequisites are specified in their package)."
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6376
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6377
    self addReferencesToClassesFromGlobalsIn:requiredClasses to:referencedClassesWithReasons.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6378
    self addReferencesToClassesFromGlobalsInMethods:(self searchForExtensionsWithProject:self package) to:referencedClassesWithReasons.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6379
13635
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6380
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6381
    "don't put classes from subProjects into the required list"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6382
    ignoredPackages := (self siblingsAreSubProjects
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6383
                                ifTrue:[ self searchForSiblingProjects ]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6384
                                ifFalse:[ self searchForSubProjects ]) asSet.
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6385
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6386
    ignoredPackages 
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6387
        add:packageId;
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6388
        add:PackageId noProjectID.
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6389
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6390
    "now map classes to packages and collect the reasons"
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6391
    packageExtractionBlock := [:classesWithReasons|
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6392
            |requiredPackageReasons|
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6393
            requiredPackageReasons := Dictionary new.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6394
            classesWithReasons keysAndValuesDo:[:usedClass :reasonsPerClass| 
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6395
                |usedClassPackage|
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6396
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6397
                usedClassPackage := usedClass package.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6398
                (ignoredPackages includes:usedClassPackage) ifFalse:[
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6399
                    (requiredPackageReasons at:usedClassPackage ifAbsentPut:[OrderedSet new])
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6400
                                    addAll:reasonsPerClass.
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6401
                ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6402
            ].
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6403
            requiredPackageReasons
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6404
        ].
14843
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6405
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6406
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6407
    ^ Array 
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6408
        with:(packageExtractionBlock value:mandatoryClassesForLoadingWithReasons)
93eb3b7e0db1 class: ProjectDefinition
Stefan Vogel <sv@exept.de>
parents: 14834
diff changeset
  6409
        with:(packageExtractionBlock value:referencedClassesWithReasons)
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6410
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6411
    "
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6412
     self searchForPreRequisites
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6413
     self searchForPreRequisites:#'stx:libwidg3'
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6414
     bosch_dapasx_Application searchForPreRequisites
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6415
     bosch_dapasx_pav_browser searchForPreRequisites
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6416
    "
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6417
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6418
    "Modified: / 07-08-2006 / 21:56:25 / fm"
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  6419
    "Created: / 17-11-2010 / 18:27:42 / Jan Vrany <jan.vrany@fit.cvut.cz>"
13635
b07e00f94949 searchForPreRequisites:withSubProjects:
Claus Gittinger <cg@exept.de>
parents: 13623
diff changeset
  6420
    "Created: / 06-09-2011 / 08:29:37 / cg"
11147
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6421
! !
ea616118c5b6 if method is marked as example- or ignoreInPreRequisite
Claus Gittinger <cg@exept.de>
parents: 11100
diff changeset
  6422
9585
b26c46ba7c2e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9584
diff changeset
  6423
!ProjectDefinition class methodsFor:'queries'!
b26c46ba7c2e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9584
diff changeset
  6424
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  6425
allClassNames
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6426
    ^ self classNamesForWhich:[:nm :attr | true ].
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6427
!
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6428
13559
9f9023caaf50 added: #allClasses
Claus Gittinger <cg@exept.de>
parents: 13544
diff changeset
  6429
allClasses
13950
a997dd517a4c changed: #allClasses
Claus Gittinger <cg@exept.de>
parents: 13899
diff changeset
  6430
    ^ self allClassNames 
a997dd517a4c changed: #allClasses
Claus Gittinger <cg@exept.de>
parents: 13899
diff changeset
  6431
        collect:[:nm | 
a997dd517a4c changed: #allClasses
Claus Gittinger <cg@exept.de>
parents: 13899
diff changeset
  6432
            |cls|
a997dd517a4c changed: #allClasses
Claus Gittinger <cg@exept.de>
parents: 13899
diff changeset
  6433
a997dd517a4c changed: #allClasses
Claus Gittinger <cg@exept.de>
parents: 13899
diff changeset
  6434
            cls := Smalltalk classNamed:nm.
a997dd517a4c changed: #allClasses
Claus Gittinger <cg@exept.de>
parents: 13899
diff changeset
  6435
            cls isNil ifTrue:[
a997dd517a4c changed: #allClasses
Claus Gittinger <cg@exept.de>
parents: 13899
diff changeset
  6436
                Transcript showCR:('%1: failed to autoload class %2' bindWith:self name with:nm)
a997dd517a4c changed: #allClasses
Claus Gittinger <cg@exept.de>
parents: 13899
diff changeset
  6437
            ].
a997dd517a4c changed: #allClasses
Claus Gittinger <cg@exept.de>
parents: 13899
diff changeset
  6438
            cls
a997dd517a4c changed: #allClasses
Claus Gittinger <cg@exept.de>
parents: 13899
diff changeset
  6439
        ]
a997dd517a4c changed: #allClasses
Claus Gittinger <cg@exept.de>
parents: 13899
diff changeset
  6440
        thenSelect:[:cls | cls notNil ].
13559
9f9023caaf50 added: #allClasses
Claus Gittinger <cg@exept.de>
parents: 13544
diff changeset
  6441
9f9023caaf50 added: #allClasses
Claus Gittinger <cg@exept.de>
parents: 13544
diff changeset
  6442
    "Created: / 06-08-2011 / 15:47:36 / cg"
9f9023caaf50 added: #allClasses
Claus Gittinger <cg@exept.de>
parents: 13544
diff changeset
  6443
!
9f9023caaf50 added: #allClasses
Claus Gittinger <cg@exept.de>
parents: 13544
diff changeset
  6444
13636
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6445
allExtensionClasses
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6446
    "answer the set of classes, which are extended by the package.
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6447
     includes all superclasses of the extended classes"
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6448
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6449
    ^ self extensionClassesWithSuperclasses:true
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6450
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6451
    "
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6452
     stx_libboss allExtensionClasses
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6453
    "
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6454
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6455
    "Created: / 06-09-2011 / 10:15:54 / cg"
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6456
!
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6457
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  6458
autoloaded_classNames
14042
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6459
    "the opposite of compiled class names"
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6460
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6461
    ^ self classNamesForWhich:[:nm :attr | attr notEmptyOrNil and:[attr includes:#autoload]].
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6462
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6463
    "Modified: / 07-08-2006 / 21:25:25 / fm"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6464
    "Created: / 30-08-2007 / 18:48:09 / cg"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6465
!
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6466
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  6467
classNames
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6468
    "answer an array containing all the class names of the project's classes"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6469
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6470
    ^ self classNamesAndAttributesAsSpecArray collect:[:entry | entry first].
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6471
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6472
    "
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6473
     stx_libhtml classNames
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6474
     stx_libhtml classNamesAndAttributesAsSpecArray
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6475
    "
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6476
!
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6477
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  6478
classNamesForWhich:aBlock
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6479
    "a correponding method with real names is generated in my subclasses"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6480
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6481
    |coll|
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6482
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6483
    coll := OrderedCollection new.
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6484
    self classNamesAndAttributesDo:[:nm :attributes |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6485
        (aBlock value:nm value:attributes) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6486
            coll add:nm.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6487
        ].
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6488
    ].
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6489
    ^ coll
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6490
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6491
    "Created: / 07-08-2006 / 19:02:57 / fm"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6492
    "Modified: / 07-08-2006 / 21:25:25 / fm"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6493
    "Modified: / 17-08-2006 / 20:47:20 / cg"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6494
!
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6495
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6496
classes
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6497
    "list my classes.
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6498
     Project must be loaded - otherwise an error is reported here.
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6499
     Use #classNames if you are only interested in the names"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6500
13728
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  6501
    ^ self classNames collect:[:nm | Smalltalk at:nm ifAbsent:[self error:'Missing class: ',nm]]
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6502
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6503
    "
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6504
     stx_libbasic3 classNames
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6505
     stx_libbasic3 classes
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6506
    "
13728
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  6507
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  6508
    "Modified: / 27-09-2011 / 18:12:33 / cg"
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6509
!
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6510
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  6511
compiled_classNames
14042
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6512
    "the opposite of autoloaded class names"
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6513
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6514
    ^ self classNamesForWhich:[:nm :attr | attr isEmptyOrNil or:[(attr includes:#autoload) not]].
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6515
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6516
    "Created: / 07-08-2006 / 19:02:57 / fm"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6517
    "Modified: / 07-08-2006 / 21:25:25 / fm"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6518
    "Modified: / 21-08-2006 / 18:48:31 / cg"
14042
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6519
    "Modified (comment): / 05-03-2012 / 12:21:23 / cg"
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6520
!
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6521
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6522
compiled_classNamesForPlatform
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6523
    "answer the classes to be compiled only for the current platformName"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6524
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6525
    ^ self compiled_classNamesForPlatform:OperatingSystem platformName
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6526
!
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6527
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6528
compiled_classNamesForPlatform:platformName
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6529
    "answer the classes to be compiled only for platformName
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6530
     platformName is one of #unix, #win32 (OperatingSystem platformName)"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6531
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  6532
    ^ self
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6533
        classNamesForWhich:[:nm :attr |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6534
            (attr includes:#autoload) not and:[attr includes:platformName]
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6535
        ].
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6536
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6537
    "Created: / 07-08-2006 / 19:02:57 / fm"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6538
    "Modified: / 07-08-2006 / 21:25:25 / fm"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6539
    "Modified: / 09-10-2006 / 13:30:08 / cg"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6540
!
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6541
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6542
compiled_classNames_common
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6543
    "classes to be compiled for any platform"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6544
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  6545
    ^ self
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6546
        classNamesForWhich:[:nm :attr |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6547
            attr isEmptyOrNil
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6548
        ].
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6549
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6550
    "Created: / 18-08-2006 / 13:37:51 / cg"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6551
!
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6552
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6553
compiled_classNames_unix
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6554
    "class, only to be compiled under unix"
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  6555
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6556
    ^ self compiled_classNamesForPlatform:#unix.
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6557
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6558
    "Created: / 18-08-2006 / 13:37:51 / cg"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6559
!
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6560
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6561
compiled_classNames_windows
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6562
    "class, only to be compiled under windows"
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  6563
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6564
    ^ self compiled_classNamesForPlatform:#win32.
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6565
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6566
    "Created: / 18-08-2006 / 13:37:56 / cg"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6567
!
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6568
13081
Stefan Vogel <sv@exept.de>
parents: 12994
diff changeset
  6569
extensionClasses
Stefan Vogel <sv@exept.de>
parents: 12994
diff changeset
  6570
    "answer the set of classes, which are extended by the package"
Stefan Vogel <sv@exept.de>
parents: 12994
diff changeset
  6571
13636
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6572
    ^ self extensionClassesWithSuperclasses:false
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6573
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6574
    "
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6575
     stx_libboss extensionClasses
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6576
    "
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6577
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6578
    "Modified: / 06-09-2011 / 10:21:44 / cg"
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6579
!
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6580
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6581
extensionClassesWithSuperclasses:withSuperclassesBoolean
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6582
    "answer the set of classes, which are extended by the package"
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6583
13081
Stefan Vogel <sv@exept.de>
parents: 12994
diff changeset
  6584
    |classes|
Stefan Vogel <sv@exept.de>
parents: 12994
diff changeset
  6585
Stefan Vogel <sv@exept.de>
parents: 12994
diff changeset
  6586
    classes := IdentitySet new.
Stefan Vogel <sv@exept.de>
parents: 12994
diff changeset
  6587
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  6588
    self extensionMethodNames pairWiseDo:[:className :selector |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6589
        |mthdCls extendedClass|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6590
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6591
        mthdCls := Smalltalk classNamed:className.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6592
        (mthdCls notNil and:[mthdCls isLoaded]) ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6593
            extendedClass := mthdCls theNonMetaclass.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6594
            (classes includes:extendedClass) ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6595
                withSuperclassesBoolean ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6596
                    extendedClass withAllSuperclassesDo:[:eachClass |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6597
                        classes add:eachClass.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6598
                    ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6599
                ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6600
                    classes add:extendedClass.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6601
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6602
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6603
        ].
13081
Stefan Vogel <sv@exept.de>
parents: 12994
diff changeset
  6604
    ].
Stefan Vogel <sv@exept.de>
parents: 12994
diff changeset
  6605
    ^ classes.
Stefan Vogel <sv@exept.de>
parents: 12994
diff changeset
  6606
Stefan Vogel <sv@exept.de>
parents: 12994
diff changeset
  6607
    "
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6608
        stx_libboss extensionClasses
13636
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6609
    "
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6610
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6611
    "Created: / 06-09-2011 / 10:17:06 / cg"
13081
Stefan Vogel <sv@exept.de>
parents: 12994
diff changeset
  6612
!
Stefan Vogel <sv@exept.de>
parents: 12994
diff changeset
  6613
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6614
extensionMethods
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6615
    "list my extension methods.
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6616
     Project must be loaded - otherwise an error is reported here.
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6617
     Use #extensionMethodsNames if you are only interested in the names"
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6618
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  6619
    ^ self extensionMethodNames
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6620
        pairWiseCollect:[:className :selector |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6621
            (Smalltalk classNamed:className) compiledMethodAt:selector.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6622
        ].
12368
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6623
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6624
    "
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6625
     stx_libbasic2 extensionMethodNames
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6626
     stx_libbasic2 extensionMethods
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6627
    "
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6628
!
Claus Gittinger <cg@exept.de>
parents: 12364
diff changeset
  6629
13081
Stefan Vogel <sv@exept.de>
parents: 12994
diff changeset
  6630
extensionPackages
Stefan Vogel <sv@exept.de>
parents: 12994
diff changeset
  6631
    "answer the set of packages, which are extended by this package"
Stefan Vogel <sv@exept.de>
parents: 12994
diff changeset
  6632
13636
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6633
    ^ self allExtensionClasses collect:[:eachClass| eachClass package]
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6634
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6635
    "
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6636
        stx_libboss extensionPackages
13636
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6637
    "
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6638
Claus Gittinger <cg@exept.de>
parents: 13635
diff changeset
  6639
    "Modified: / 06-09-2011 / 10:20:47 / cg"
13081
Stefan Vogel <sv@exept.de>
parents: 12994
diff changeset
  6640
!
Stefan Vogel <sv@exept.de>
parents: 12994
diff changeset
  6641
10144
89b932dbdacc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10140
diff changeset
  6642
hasAllClassesFullyLoaded
89b932dbdacc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10140
diff changeset
  6643
    "return true, if all classes are present and loaded"
89b932dbdacc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10140
diff changeset
  6644
89b932dbdacc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10140
diff changeset
  6645
    ^ self hasAllClassesLoaded:true
89b932dbdacc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10140
diff changeset
  6646
89b932dbdacc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10140
diff changeset
  6647
    "Created: / 25-10-2006 / 16:08:25 / cg"
89b932dbdacc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10140
diff changeset
  6648
!
89b932dbdacc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10140
diff changeset
  6649
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  6650
hasAllClassesLoaded
10205
33fadd7b4fd1 *** empty log message ***
Stefan Vogel <sv@exept.de>
parents: 10203
diff changeset
  6651
    "return true, if all classes are present (although, some might be autoloaded)"
10144
89b932dbdacc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10140
diff changeset
  6652
89b932dbdacc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10140
diff changeset
  6653
    ^ self hasAllClassesLoaded:false
89b932dbdacc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10140
diff changeset
  6654
89b932dbdacc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10140
diff changeset
  6655
    "Modified: / 25-10-2006 / 16:08:11 / cg"
89b932dbdacc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10140
diff changeset
  6656
!
89b932dbdacc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10140
diff changeset
  6657
89b932dbdacc *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10140
diff changeset
  6658
hasAllClassesLoaded:checkIfFullyLoaded
10366
8990764f8911 #compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents: 10350
diff changeset
  6659
    "check if all classes for this platform are present.
12421
67898c88eceb comment/format in: #hasAllClassesLoaded:
Claus Gittinger <cg@exept.de>
parents: 12416
diff changeset
  6660
     If checkIfFullyLoaded is true, they must be fully loaded; that means: not autoloaded"
10366
8990764f8911 #compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents: 10350
diff changeset
  6661
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  6662
    ^ (self
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6663
            hasClasses:(self classNamesForWhich:[:nm :attr | attr isEmptyOrNil or:[ attr includes:#autoload]])
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6664
            loaded:checkIfFullyLoaded)
10154
abf2c5f9ba8c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10149
diff changeset
  6665
    and:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6666
        self
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6667
            hasClasses:(self compiled_classNamesForPlatform:OperatingSystem platformName)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6668
            loaded:checkIfFullyLoaded ]
10154
abf2c5f9ba8c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10149
diff changeset
  6669
abf2c5f9ba8c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10149
diff changeset
  6670
    "Modified: / 07-11-2006 / 11:47:30 / cg"
abf2c5f9ba8c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10149
diff changeset
  6671
!
abf2c5f9ba8c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10149
diff changeset
  6672
abf2c5f9ba8c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10149
diff changeset
  6673
hasAllCompiledClassesFullyLoaded
abf2c5f9ba8c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10149
diff changeset
  6674
    "return true, if all compiled classes are present and loaded"
abf2c5f9ba8c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10149
diff changeset
  6675
abf2c5f9ba8c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10149
diff changeset
  6676
    ^ self hasAllCompiledClassesLoaded:true
abf2c5f9ba8c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10149
diff changeset
  6677
abf2c5f9ba8c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10149
diff changeset
  6678
    "Created: / 07-11-2006 / 11:48:02 / cg"
abf2c5f9ba8c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10149
diff changeset
  6679
!
abf2c5f9ba8c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10149
diff changeset
  6680
abf2c5f9ba8c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10149
diff changeset
  6681
hasAllCompiledClassesLoaded:checkIfFullyLoaded
10366
8990764f8911 #compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents: 10350
diff changeset
  6682
    "check if all compiled classes for this platform are present.
8990764f8911 #compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents: 10350
diff changeset
  6683
     If checkIfFullyLoaded is true, they must be fully loaded, that is not autoloaded"
8990764f8911 #compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents: 10350
diff changeset
  6684
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  6685
    ^ (self
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6686
            hasClasses:(self classNamesForWhich:[:nm :attr | attr isEmptyOrNil])
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6687
            loaded:checkIfFullyLoaded)
10154
abf2c5f9ba8c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10149
diff changeset
  6688
    and:[
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  6689
       self
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6690
            hasClasses:(self compiled_classNamesForPlatform:OperatingSystem platformName)
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6691
            loaded:checkIfFullyLoaded
10366
8990764f8911 #compiled_classNamesForPlatform: does not return classes names,
Stefan Vogel <sv@exept.de>
parents: 10350
diff changeset
  6692
    ]
9585
b26c46ba7c2e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9584
diff changeset
  6693
!
b26c46ba7c2e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9584
diff changeset
  6694
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  6695
hasAllExtensionsLoaded
10203
b210e7832fe1 Do not autoload when checking for extensions
Stefan Vogel <sv@exept.de>
parents: 10200
diff changeset
  6696
    "answer true, if all extensions of this package have been loaded.
b210e7832fe1 Do not autoload when checking for extensions
Stefan Vogel <sv@exept.de>
parents: 10200
diff changeset
  6697
     This is a query - so no side effects please"
b210e7832fe1 Do not autoload when checking for extensions
Stefan Vogel <sv@exept.de>
parents: 10200
diff changeset
  6698
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  6699
    self extensionMethodNames pairWiseDo:[:className :selector |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6700
        |cls|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6701
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6702
        cls := Smalltalk loadedClassNamed:className.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6703
        cls isNil ifTrue:[
14021
11d015697e44 changed:8 methods
Stefan Vogel <sv@exept.de>
parents: 13968
diff changeset
  6704
            Verbose ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6705
                Transcript showCR:(self name,' missing extension class "',className,'".').
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6706
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6707
            ^ false
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6708
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6709
        "there is no possibility that we installed an extension method in an unloaded class"
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6710
        (cls isLoaded not or:[(cls compiledMethodAt:selector) isNil]) ifTrue:[
14021
11d015697e44 changed:8 methods
Stefan Vogel <sv@exept.de>
parents: 13968
diff changeset
  6711
            Verbose ifTrue:[
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6712
                Transcript showCR:(self name,' missing extension method "',className,'>>',selector,'".').
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6713
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6714
            ^ false
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6715
        ].
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  6716
    ].
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  6717
    ^ true.
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  6718
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  6719
    "Created: / 17-08-2006 / 00:50:01 / cg"
10140
154f52dd6821 isLoaded queries fixed
Claus Gittinger <cg@exept.de>
parents: 10132
diff changeset
  6720
    "Modified: / 25-10-2006 / 00:01:10 / cg"
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  6721
!
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  6722
10369
14baf6dc8ba6 No diag message about "unloaded classes" when loading packages
Stefan Vogel <sv@exept.de>
parents: 10368
diff changeset
  6723
hasClasses:classNames loaded:checkIfFullyLoaded
14baf6dc8ba6 No diag message about "unloaded classes" when loading packages
Stefan Vogel <sv@exept.de>
parents: 10368
diff changeset
  6724
    "answer true, if all classes referenced by classNames have been loaded
14baf6dc8ba6 No diag message about "unloaded classes" when loading packages
Stefan Vogel <sv@exept.de>
parents: 10368
diff changeset
  6725
     into the image. If checkIfFullyLoaded, classes installed as autoloaded
14baf6dc8ba6 No diag message about "unloaded classes" when loading packages
Stefan Vogel <sv@exept.de>
parents: 10368
diff changeset
  6726
     are not considered"
14baf6dc8ba6 No diag message about "unloaded classes" when loading packages
Stefan Vogel <sv@exept.de>
parents: 10368
diff changeset
  6727
14baf6dc8ba6 No diag message about "unloaded classes" when loading packages
Stefan Vogel <sv@exept.de>
parents: 10368
diff changeset
  6728
    classNames do:[:eachClassName |
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6729
        |cls|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6730
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6731
        cls := Smalltalk loadedClassNamed:eachClassName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6732
        cls isNil ifTrue:[
14021
11d015697e44 changed:8 methods
Stefan Vogel <sv@exept.de>
parents: 13968
diff changeset
  6733
            Verbose ifTrue:[
11d015697e44 changed:8 methods
Stefan Vogel <sv@exept.de>
parents: 13968
diff changeset
  6734
               (self name, ' [info]: missing class: ', eachClassName) infoPrintCR.
11d015697e44 changed:8 methods
Stefan Vogel <sv@exept.de>
parents: 13968
diff changeset
  6735
            ].
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6736
            ^ false
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6737
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6738
        (checkIfFullyLoaded and:[cls isLoaded not]) ifTrue:[
14021
11d015697e44 changed:8 methods
Stefan Vogel <sv@exept.de>
parents: 13968
diff changeset
  6739
            Verbose ifTrue:[
11d015697e44 changed:8 methods
Stefan Vogel <sv@exept.de>
parents: 13968
diff changeset
  6740
                (self name,' [info]: unloaded class: ', eachClassName) infoPrintCR.
11d015697e44 changed:8 methods
Stefan Vogel <sv@exept.de>
parents: 13968
diff changeset
  6741
            ].
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6742
            ^ false.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6743
        ].
10369
14baf6dc8ba6 No diag message about "unloaded classes" when loading packages
Stefan Vogel <sv@exept.de>
parents: 10368
diff changeset
  6744
    ].
14baf6dc8ba6 No diag message about "unloaded classes" when loading packages
Stefan Vogel <sv@exept.de>
parents: 10368
diff changeset
  6745
14baf6dc8ba6 No diag message about "unloaded classes" when loading packages
Stefan Vogel <sv@exept.de>
parents: 10368
diff changeset
  6746
    ^ true
10154
abf2c5f9ba8c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10149
diff changeset
  6747
!
abf2c5f9ba8c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 10149
diff changeset
  6748
9906
9efd21c9b1b6 hasExtensions is a bad name (conflicts with the other query)
Claus Gittinger <cg@exept.de>
parents: 9904
diff changeset
  6749
hasExtensionMethods
9850
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  6750
    ^ self extensionMethodNames notEmpty
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  6751
178f4c0ce2fd dependencies
Claus Gittinger <cg@exept.de>
parents: 9848
diff changeset
  6752
    "Created: / 14-09-2006 / 14:19:35 / cg"
10005
407485f2a6e0 fix loading:
Stefan Vogel <sv@exept.de>
parents: 9998
diff changeset
  6753
!
407485f2a6e0 fix loading:
Stefan Vogel <sv@exept.de>
parents: 9998
diff changeset
  6754
12369
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6755
hasPostLoadAction
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6756
    "/ true if postLoadAction has been redefined
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6757
    ^ (self class whichClassIncludesSelector:#postLoadAction) theNonMetaclass isAbstract not
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6758
!
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6759
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6760
hasPostUnloadAction
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6761
    "/ true if postUnloadAction has been redefined
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6762
    ^ (self class whichClassIncludesSelector:#postUnloadAction) theNonMetaclass isAbstract not
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6763
!
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6764
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6765
hasPreLoadAction
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6766
    "/ true if preLoadAction has been redefined
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6767
    ^ (self class whichClassIncludesSelector:#preLoadAction) theNonMetaclass isAbstract not
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6768
!
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6769
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6770
hasPreUnloadAction
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6771
    "/ true if preUnloadAction has been redefined
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6772
    ^ (self class whichClassIncludesSelector:#preUnloadAction) theNonMetaclass isAbstract not
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6773
!
a369c34ec34e added:5 methods
Claus Gittinger <cg@exept.de>
parents: 12368
diff changeset
  6774
13609
b46f07e8e7a3 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13592
diff changeset
  6775
isAbstract
b46f07e8e7a3 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13592
diff changeset
  6776
    ^ self == ProjectDefinition
b46f07e8e7a3 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13592
diff changeset
  6777
b46f07e8e7a3 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13592
diff changeset
  6778
    "Modified (format): / 20-08-2011 / 22:47:46 / cg"
b46f07e8e7a3 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13592
diff changeset
  6779
!
b46f07e8e7a3 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13592
diff changeset
  6780
10140
154f52dd6821 isLoaded queries fixed
Claus Gittinger <cg@exept.de>
parents: 10132
diff changeset
  6781
isFullyLoaded
13419
Claus Gittinger <cg@exept.de>
parents: 13411
diff changeset
  6782
    ^ self hasAllCompiledClassesFullyLoaded
13167
658fc3b51af4 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13166
diff changeset
  6783
    and:[self hasAllClassesLoaded and:[self hasAllExtensionsLoaded]]
10140
154f52dd6821 isLoaded queries fixed
Claus Gittinger <cg@exept.de>
parents: 10132
diff changeset
  6784
154f52dd6821 isLoaded queries fixed
Claus Gittinger <cg@exept.de>
parents: 10132
diff changeset
  6785
    "Created: / 24-10-2006 / 23:52:23 / cg"
13609
b46f07e8e7a3 comment/format in:
Claus Gittinger <cg@exept.de>
parents: 13592
diff changeset
  6786
    "Modified: / 20-08-2011 / 22:47:16 / cg"
12331
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  6787
!
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  6788
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  6789
projectType
02c0437d7817 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12315
diff changeset
  6790
    ^ self subclassResponsibility
9585
b26c46ba7c2e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9584
diff changeset
  6791
! !
b26c46ba7c2e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9584
diff changeset
  6792
10774
c99a6da52fe4 html-doc privacy
Claus Gittinger <cg@exept.de>
parents: 10745
diff changeset
  6793
!ProjectDefinition class methodsFor:'queries-privacy'!
c99a6da52fe4 html-doc privacy
Claus Gittinger <cg@exept.de>
parents: 10745
diff changeset
  6794
c99a6da52fe4 html-doc privacy
Claus Gittinger <cg@exept.de>
parents: 10745
diff changeset
  6795
showClassDocumentationOf:aClass
12198
f3f15cc6a32e changed: #showClassDocumentationOf:
Claus Gittinger <cg@exept.de>
parents: 12192
diff changeset
  6796
    "used by the HTMLDoc-generator to ask if a classes' protocol is to be documented
f3f15cc6a32e changed: #showClassDocumentationOf:
Claus Gittinger <cg@exept.de>
parents: 12192
diff changeset
  6797
     or hidden.
f3f15cc6a32e changed: #showClassDocumentationOf:
Claus Gittinger <cg@exept.de>
parents: 12192
diff changeset
  6798
     (used for expecco, to suppress documentation of workflow- and expecco classes
f3f15cc6a32e changed: #showClassDocumentationOf:
Claus Gittinger <cg@exept.de>
parents: 12192
diff changeset
  6799
     in the expecco-class browser)"
10774
c99a6da52fe4 html-doc privacy
Claus Gittinger <cg@exept.de>
parents: 10745
diff changeset
  6800
c99a6da52fe4 html-doc privacy
Claus Gittinger <cg@exept.de>
parents: 10745
diff changeset
  6801
    ^ true
c99a6da52fe4 html-doc privacy
Claus Gittinger <cg@exept.de>
parents: 10745
diff changeset
  6802
c99a6da52fe4 html-doc privacy
Claus Gittinger <cg@exept.de>
parents: 10745
diff changeset
  6803
    "Created: / 05-11-2007 / 16:44:16 / cg"
c99a6da52fe4 html-doc privacy
Claus Gittinger <cg@exept.de>
parents: 10745
diff changeset
  6804
! !
c99a6da52fe4 html-doc privacy
Claus Gittinger <cg@exept.de>
parents: 10745
diff changeset
  6805
9726
305dc3397c51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9714
diff changeset
  6806
!ProjectDefinition class methodsFor:'sanity checks'!
305dc3397c51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9714
diff changeset
  6807
305dc3397c51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9714
diff changeset
  6808
validateDescription
13808
0f696e30344a comment
Claus Gittinger <cg@exept.de>
parents: 13798
diff changeset
  6809
    "perform some consistency checks (set of classes in project same as those listed in description);
0f696e30344a comment
Claus Gittinger <cg@exept.de>
parents: 13798
diff changeset
  6810
     called before checking in build support files"
0f696e30344a comment
Claus Gittinger <cg@exept.de>
parents: 13798
diff changeset
  6811
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6812
    |emptyProjects nonProjects emptyOrNonProjects classesInImage 
14510
5274ba4185d8 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14361
diff changeset
  6813
     classesInDescription onlyInImage onlyInDescription missingPools myPackage|
9956
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  6814
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  6815
    emptyProjects := Set withAll:self subProjects.
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  6816
    Smalltalk allClassesDo:[:cls |
13711
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6817
        emptyProjects remove:(cls package) ifAbsent:[].
9956
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  6818
    ].
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  6819
    nonProjects := self subProjects select:[:p |
13711
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6820
                    (ProjectDefinition definitionClassForPackage: p) isNil
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6821
                   ].
9956
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  6822
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  6823
    emptyOrNonProjects := Set withAll:emptyProjects.
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  6824
    emptyOrNonProjects addAll:nonProjects.
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  6825
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  6826
    emptyOrNonProjects notEmpty ifTrue:[
13711
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6827
        (Dialog
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6828
            confirm:('The following projects are non-existent, empty or without description:\\    '
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6829
                    , ((emptyOrNonProjects
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6830
                            asSortedCollection
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6831
                                collect:[:p | p allBold])
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6832
                                asStringWith:'\    ')
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6833
                    , '\\Continue ?') withCRs
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6834
            yesLabel:'OK' noLabel:'Cancel')
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6835
        ifFalse:[
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6836
            AbortSignal raise
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6837
        ].
9956
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  6838
    ].
7c5d9f3ae8ea *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9946
diff changeset
  6839
14510
5274ba4185d8 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14361
diff changeset
  6840
    myPackage := self package.
5274ba4185d8 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14361
diff changeset
  6841
    classesInImage := Smalltalk allClasses select:[:cls | (cls package == myPackage) and:[cls isPrivate not]].
13728
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  6842
    "/ classesInDescription := self classes asIdentitySet.
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  6843
    classesInDescription := IdentitySet new.
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  6844
    ((self compiled_classNamesForPlatform:(OperatingSystem platformName))
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  6845
    , (self compiled_classNames_common)
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  6846
    , (self autoloaded_classNames)) do:[:nm |
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  6847
        |cls|
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  6848
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  6849
        cls := Smalltalk at:nm asSymbol.
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  6850
        cls isNil ifTrue:[
14834
d54330e59dcd class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14817
diff changeset
  6851
            (self autoloaded_classNames includes:nm) ifTrue:[
d54330e59dcd class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14817
diff changeset
  6852
                Transcript showCR:'missing autoloaded class: ',nm.
d54330e59dcd class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14817
diff changeset
  6853
            ] ifFalse:[
d54330e59dcd class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14817
diff changeset
  6854
                self error:('missing class: ',nm) mayProceed:true.
d54330e59dcd class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14817
diff changeset
  6855
            ]
d54330e59dcd class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14817
diff changeset
  6856
        ] ifFalse:[
d54330e59dcd class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14817
diff changeset
  6857
            classesInDescription add:cls.
d54330e59dcd class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14817
diff changeset
  6858
        ]
13728
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  6859
    ].
Claus Gittinger <cg@exept.de>
parents: 13723
diff changeset
  6860
13809
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6861
    missingPools := Set new.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6862
    classesInDescription do:[:eachClass |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6863
        eachClass sharedPoolNames do:[:eachPoolName |
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6864
            |pool|
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6865
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6866
            pool := eachClass nameSpace classNamed:eachPoolName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6867
            pool isNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6868
                eachClass nameSpace ~~ Smalltalk ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6869
                    pool := Smalltalk classNamed:eachPoolName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6870
                ] 
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6871
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6872
            pool isNil ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6873
                Transcript showCR:'missing pool: ',eachPoolName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6874
                missingPools add:eachPoolName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6875
            ] ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6876
                pool isSharedPool ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6877
                    Transcript showCR:'not a shared pool: ',eachPoolName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6878
                    missingPools add:eachPoolName.
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6879
                ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6880
            ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6881
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6882
    ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6883
    missingPools notEmpty ifTrue:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6884
        (Dialog
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6885
            confirm:('The following sharedpools are non-existent, or not pools:\\    '
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6886
                    , ((missingPools
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6887
                            asSortedCollection
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6888
                                collect:[:p | p allBold])
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6889
                                asStringWith:'\    ')
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6890
                    , '\\Continue ?') withCRs
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6891
            yesLabel:'OK' noLabel:'Cancel')
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6892
        ifFalse:[
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6893
            AbortSignal raise
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6894
        ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6895
    ].
da77d6869c9c changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13808
diff changeset
  6896
13694
ff3118874df3 changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13692
diff changeset
  6897
    classesInImage ~= classesInDescription ifTrue:[
13711
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6898
        onlyInImage := (classesInImage reject:[:cls | classesInDescription includes:cls]).
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6899
        onlyInImage notEmpty ifTrue:[
13899
d769ad2935e6 changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13875
diff changeset
  6900
            Transcript show:self name; show:': only in image: '; showCR:onlyInImage
13711
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6901
        ].
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6902
        onlyInDescription := (classesInDescription reject:[:cls | classesInImage includes:cls]).
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6903
        onlyInDescription notEmpty ifTrue:[
13899
d769ad2935e6 changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13875
diff changeset
  6904
            Transcript show:self name; show:': only in description: '; showCR:onlyInDescription
13711
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6905
        ].
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6906
        (Dialog confirm:'The set of classes in the image is different from the listed classes in the project definition.\\Proceed?' withCRs) ifFalse:[
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6907
            AbortSignal raiseRequest
d3fe511856fc changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13702
diff changeset
  6908
        ]
13694
ff3118874df3 changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13692
diff changeset
  6909
    ].
14045
2a6a76d7b7f6 changed:
Claus Gittinger <cg@exept.de>
parents: 14042
diff changeset
  6910
"/    self validateOrderOfClasses
13694
ff3118874df3 changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13692
diff changeset
  6911
ff3118874df3 changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13692
diff changeset
  6912
    "
ff3118874df3 changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13692
diff changeset
  6913
     squeak_vmMaker validateDescription
ff3118874df3 changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13692
diff changeset
  6914
    "
ff3118874df3 changed: #validateDescription
Claus Gittinger <cg@exept.de>
parents: 13692
diff changeset
  6915
14045
2a6a76d7b7f6 changed:
Claus Gittinger <cg@exept.de>
parents: 14042
diff changeset
  6916
    "Modified: / 06-03-2012 / 11:31:37 / cg"
14042
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6917
!
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6918
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6919
validateOrderOfClasses
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6920
    "check if the project's classes are listed in the correct dependency order in the classList.
14045
2a6a76d7b7f6 changed:
Claus Gittinger <cg@exept.de>
parents: 14042
diff changeset
  6921
     This would be required, if the generated makefile would compile files in that order,
2a6a76d7b7f6 changed:
Claus Gittinger <cg@exept.de>
parents: 14042
diff changeset
  6922
     and superclasses must be compiled before subclasses (for the header files).
2a6a76d7b7f6 changed:
Claus Gittinger <cg@exept.de>
parents: 14042
diff changeset
  6923
     However, the makefile list is generated by a separate mechanism, so that is not requiered."
14042
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6924
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6925
    |classesInDescriptionInOrder classesInProject already|
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6926
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6927
    classesInDescriptionInOrder := OrderedCollection new.
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6928
    classesInDescriptionInOrder := 
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6929
        self compiled_classNames 
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6930
            collect:[:eachName |
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6931
                |cls|
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6932
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6933
                cls := Smalltalk at:eachName.
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6934
                self assert:cls notNil message:'missing class: ',eachName.
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6935
                cls
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6936
            ].
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6937
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6938
    classesInProject := classesInDescriptionInOrder asSet.
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6939
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6940
    already := Set new.
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6941
    classesInDescriptionInOrder do:[:eachClass |
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6942
        eachClass allSuperclassesDo:[:superclass |
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6943
            (classesInProject includes:superclass) ifTrue:[
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6944
                "/ if in the set, it must have been already listed
14045
2a6a76d7b7f6 changed:
Claus Gittinger <cg@exept.de>
parents: 14042
diff changeset
  6945
                self 
2a6a76d7b7f6 changed:
Claus Gittinger <cg@exept.de>
parents: 14042
diff changeset
  6946
                    assert:(already includes:superclass) 
2a6a76d7b7f6 changed:
Claus Gittinger <cg@exept.de>
parents: 14042
diff changeset
  6947
                    message:('superclass "%1" not compiled before "%2"'
2a6a76d7b7f6 changed:
Claus Gittinger <cg@exept.de>
parents: 14042
diff changeset
  6948
                                    bindWith:superclass name
2a6a76d7b7f6 changed:
Claus Gittinger <cg@exept.de>
parents: 14042
diff changeset
  6949
                                    with:eachClass name).
14042
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6950
            ].
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6951
        ].
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6952
        already add:eachClass.
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6953
    ].
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6954
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6955
    "
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6956
     stx_goodies_refactoryBrowser_lint validateOrderOfClasses
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6957
     squeak_vmMaker validateOrderOfClasses
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6958
    "
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6959
05b7b61d7e59 added: #validateOrderOfClasses
Claus Gittinger <cg@exept.de>
parents: 14021
diff changeset
  6960
    "Created: / 05-03-2012 / 12:18:45 / cg"
9726
305dc3397c51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9714
diff changeset
  6961
! !
305dc3397c51 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9714
diff changeset
  6962
9585
b26c46ba7c2e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9584
diff changeset
  6963
!ProjectDefinition class methodsFor:'testing'!
b26c46ba7c2e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9584
diff changeset
  6964
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  6965
isApplicationDefinition
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  6966
    ^ false
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  6967
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  6968
    "Created: / 23-08-2006 / 15:17:32 / cg"
9983
f128c0a46573 preRequisite generation
Claus Gittinger <cg@exept.de>
parents: 9979
diff changeset
  6969
    "Modified: / 20-09-2006 / 14:59:56 / cg"
f128c0a46573 preRequisite generation
Claus Gittinger <cg@exept.de>
parents: 9979
diff changeset
  6970
!
f128c0a46573 preRequisite generation
Claus Gittinger <cg@exept.de>
parents: 9979
diff changeset
  6971
12309
f51aaafd2131 added: #isConsoleApplication
Claus Gittinger <cg@exept.de>
parents: 12305
diff changeset
  6972
isConsoleApplication
f51aaafd2131 added: #isConsoleApplication
Claus Gittinger <cg@exept.de>
parents: 12305
diff changeset
  6973
    ^ false
f51aaafd2131 added: #isConsoleApplication
Claus Gittinger <cg@exept.de>
parents: 12305
diff changeset
  6974
f51aaafd2131 added: #isConsoleApplication
Claus Gittinger <cg@exept.de>
parents: 12305
diff changeset
  6975
    "Created: / 20-09-2006 / 14:59:49 / cg"
f51aaafd2131 added: #isConsoleApplication
Claus Gittinger <cg@exept.de>
parents: 12305
diff changeset
  6976
!
f51aaafd2131 added: #isConsoleApplication
Claus Gittinger <cg@exept.de>
parents: 12305
diff changeset
  6977
9983
f128c0a46573 preRequisite generation
Claus Gittinger <cg@exept.de>
parents: 9979
diff changeset
  6978
isGUIApplication
f128c0a46573 preRequisite generation
Claus Gittinger <cg@exept.de>
parents: 9979
diff changeset
  6979
    ^ false
f128c0a46573 preRequisite generation
Claus Gittinger <cg@exept.de>
parents: 9979
diff changeset
  6980
f128c0a46573 preRequisite generation
Claus Gittinger <cg@exept.de>
parents: 9979
diff changeset
  6981
    "Created: / 20-09-2006 / 14:59:49 / cg"
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  6982
!
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  6983
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  6984
isLibraryDefinition
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  6985
    ^ false
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  6986
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  6987
    "Created: / 23-08-2006 / 15:17:46 / cg"
9983
f128c0a46573 preRequisite generation
Claus Gittinger <cg@exept.de>
parents: 9979
diff changeset
  6988
    "Modified: / 20-09-2006 / 15:00:00 / cg"
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  6989
!
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  6990
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  6991
isProjectDefinition
9664
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  6992
    "concrete i.e. not abstract"
f2cda0054b21 boss stuff separated
Claus Gittinger <cg@exept.de>
parents: 9634
diff changeset
  6993
13285
bd6b2a49c8af comment
Claus Gittinger <cg@exept.de>
parents: 13251
diff changeset
  6994
    ^ self ~~ ProjectDefinition "/ skip myself - I am abstract
9627
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  6995
685786ff2bdf *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9625
diff changeset
  6996
    "Created: / 10-08-2006 / 16:24:02 / cg"
13285
bd6b2a49c8af comment
Claus Gittinger <cg@exept.de>
parents: 13251
diff changeset
  6997
    "Modified: / 08-02-2011 / 10:03:49 / cg"
9585
b26c46ba7c2e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9584
diff changeset
  6998
! !
b26c46ba7c2e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9584
diff changeset
  6999
13592
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7000
!ProjectDefinition::AbbrevEntry methodsFor:'accessing'!
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7001
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7002
category
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7003
    ^ category
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7004
!
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7005
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7006
className
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7007
    ^ className
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7008
!
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7009
13695
Claus Gittinger <cg@exept.de>
parents: 13694
diff changeset
  7010
className:classNameArg fileName:fileNameArg category:categoryArg numClassInstVars:numClassInstVarsArg
13592
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7011
    className := classNameArg.
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7012
    fileName := fileNameArg.
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7013
    category := categoryArg.
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7014
    numClassInstVars := numClassInstVarsArg.
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7015
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7016
    "Created: / 18-08-2011 / 14:18:30 / cg"
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7017
!
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7018
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7019
fileName
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7020
    ^ fileName
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7021
!
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7022
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7023
numClassInstVars
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7024
    ^ numClassInstVars
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7025
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7026
    "Created: / 18-08-2011 / 14:18:37 / cg"
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7027
! !
11fec330be43 class definition
Claus Gittinger <cg@exept.de>
parents: 13568
diff changeset
  7028
9569
b0bf179c9bf5 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9559
diff changeset
  7029
!ProjectDefinition class methodsFor:'documentation'!
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  7030
13610
ec7ea708ebd2 changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13609
diff changeset
  7031
version
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  7032
    ^ '$Header: /cvs/stx/stx/libbasic/ProjectDefinition.st,v 1.425 2013-03-13 01:24:08 vrany Exp $'
13610
ec7ea708ebd2 changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13609
diff changeset
  7033
!
ec7ea708ebd2 changed: #installAutoloadedClasses
Claus Gittinger <cg@exept.de>
parents: 13609
diff changeset
  7034
12086
9db1452d0645 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 12039
diff changeset
  7035
version_CVS
14859
1511cfd924cd Merged ProjectDefinition fixes & tweaks required for stx:libjava and mercurial support.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 14851
diff changeset
  7036
    ^ '$Header: /cvs/stx/stx/libbasic/ProjectDefinition.st,v 1.425 2013-03-13 01:24:08 vrany Exp $'
13411
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  7037
!
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  7038
9f50c450bdf9 Jan's changes
vrany
parents: 13336
diff changeset
  7039
version_SVN
13485
60df70976373 changed: #classNamesByCategory
Claus Gittinger <cg@exept.de>
parents: 13419
diff changeset
  7040
    ^ '§ Id: ProjectDefinition.st 10645 2011-06-09 15:28:45Z vranyj1  §'
9536
3a835fa7e38b initial checkin
fm
parents:
diff changeset
  7041
! !
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  7042
14642
415f684f8808 class: ProjectDefinition
Claus Gittinger <cg@exept.de>
parents: 14586
diff changeset
  7043
9714
c7c36a28cc0a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 9688
diff changeset
  7044
ProjectDefinition initialize!