ProjectBuilder.st
author Claus Gittinger <cg@exept.de>
Sun, 04 Dec 2011 19:56:26 +0100
changeset 2863 eb998d836550
parent 2861 b8c6e02e60a1
child 2868 8a4d46fd157c
permissions -rw-r--r--
changed: #updateListOfMatchingProjects
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
2741
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
     1
"
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
     2
 COPYRIGHT (c) 2009 by eXept Software AG
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
     3
              All Rights Reserved
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
     4
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
     5
 This software is furnished under a license and may be used
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
     6
 only in accordance with the terms of that license and with the
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
     7
 inclusion of the above copyright notice.   This software may not
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
     8
 be provided or otherwise made available to, or used by, any
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
     9
 other person.  No title to or ownership of the software is
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
    10
 hereby transferred.
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
    11
"
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    12
"{ Package: 'stx:libtool2' }"
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    13
2635
8b62bd023558 namespace change
Claus Gittinger <cg@exept.de>
parents: 2634
diff changeset
    14
"{ NameSpace: Tools }"
8b62bd023558 namespace change
Claus Gittinger <cg@exept.de>
parents: 2634
diff changeset
    15
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    16
Object subclass:#ProjectBuilder
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    17
	instanceVariableNames:'package projectDefinitionClass sourceCodeManager buildDirectory
2673
100b4dd5c3c2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2672
diff changeset
    18
		myWorkingDirectory mySTXTopDirectory myTopDirectory outputStream
2680
3f2dbbd7743f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2678
diff changeset
    19
		makeExeOnly usedCompiler'
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    20
	classVariableNames:'PreviousBuildDirectory'
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    21
	poolDictionaries:''
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    22
	category:'System-Support-Projects'
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    23
!
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    24
2741
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
    25
!ProjectBuilder class methodsFor:'documentation'!
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
    26
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
    27
copyright
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
    28
"
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
    29
 COPYRIGHT (c) 2009 by eXept Software AG
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
    30
              All Rights Reserved
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
    31
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
    32
 This software is furnished under a license and may be used
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
    33
 only in accordance with the terms of that license and with the
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
    34
 inclusion of the above copyright notice.   This software may not
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
    35
 be provided or otherwise made available to, or used by, any
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
    36
 other person.  No title to or ownership of the software is
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
    37
 hereby transferred.
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
    38
"
783dda495655 added: #copyright
Claus Gittinger <cg@exept.de>
parents: 2723
diff changeset
    39
! !
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    40
2633
Claus Gittinger <cg@exept.de>
parents: 2628
diff changeset
    41
!ProjectBuilder class methodsFor:'accessing'!
Claus Gittinger <cg@exept.de>
parents: 2628
diff changeset
    42
Claus Gittinger <cg@exept.de>
parents: 2628
diff changeset
    43
previousBuildDirectory
Claus Gittinger <cg@exept.de>
parents: 2628
diff changeset
    44
    ^ PreviousBuildDirectory
Claus Gittinger <cg@exept.de>
parents: 2628
diff changeset
    45
!
Claus Gittinger <cg@exept.de>
parents: 2628
diff changeset
    46
Claus Gittinger <cg@exept.de>
parents: 2628
diff changeset
    47
previousBuildDirectory:something
Claus Gittinger <cg@exept.de>
parents: 2628
diff changeset
    48
    PreviousBuildDirectory := something.
Claus Gittinger <cg@exept.de>
parents: 2628
diff changeset
    49
! !
Claus Gittinger <cg@exept.de>
parents: 2628
diff changeset
    50
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    51
!ProjectBuilder class methodsFor:'examples'!
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    52
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    53
example1
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    54
    Smalltalk loadPackage:'stx:projects/helloWorldApp' asAutoloaded:true.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    55
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    56
    self new
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    57
        package:'stx:projects/helloWorldApp';
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    58
        build
2622
e55f43981463 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2614
diff changeset
    59
!
e55f43981463 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2614
diff changeset
    60
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    61
example2
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    62
    |builder|
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    63
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    64
    Smalltalk loadPackage:'stx:clients/Demos/foxCalcApplication' asAutoloaded:true.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    65
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    66
    builder := self new.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    67
    builder package:'stx:clients/Demos/foxCalcApplication'.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    68
    builder build.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    69
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    70
    UserPreferences fileBrowserClass openOnDirectory:builder packageBuildDirectory.
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    71
! !
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    72
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    73
!ProjectBuilder methodsFor:'accessing'!
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    74
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    75
buildDirectory
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    76
    ^ buildDirectory
2622
e55f43981463 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2614
diff changeset
    77
!
e55f43981463 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2614
diff changeset
    78
2634
3f14301cec84 added: #buildDirectory:
Claus Gittinger <cg@exept.de>
parents: 2633
diff changeset
    79
buildDirectory:something
3f14301cec84 added: #buildDirectory:
Claus Gittinger <cg@exept.de>
parents: 2633
diff changeset
    80
    buildDirectory := something.
3f14301cec84 added: #buildDirectory:
Claus Gittinger <cg@exept.de>
parents: 2633
diff changeset
    81
!
3f14301cec84 added: #buildDirectory:
Claus Gittinger <cg@exept.de>
parents: 2633
diff changeset
    82
2673
100b4dd5c3c2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2672
diff changeset
    83
makeExeOnly:aBoolean
100b4dd5c3c2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2672
diff changeset
    84
    makeExeOnly := aBoolean.
100b4dd5c3c2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2672
diff changeset
    85
!
100b4dd5c3c2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2672
diff changeset
    86
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    87
package:aPackageIDOrSymbol
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    88
    package := aPackageIDOrSymbol asPackageId.
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    89
!
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    90
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    91
packageBuildDirectory
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    92
    "the directoray, where the deployable binary is created (xxxSetup.exe)"
2622
e55f43981463 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2614
diff changeset
    93
e55f43981463 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2614
diff changeset
    94
    ^ buildDirectory / (package asPackageId module) / (package asPackageId directory)
2635
8b62bd023558 namespace change
Claus Gittinger <cg@exept.de>
parents: 2634
diff changeset
    95
!
8b62bd023558 namespace change
Claus Gittinger <cg@exept.de>
parents: 2634
diff changeset
    96
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    97
projectDefinitionClass:something
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
    98
    projectDefinitionClass := something.
2680
3f2dbbd7743f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2678
diff changeset
    99
!
3f2dbbd7743f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2678
diff changeset
   100
2683
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   101
suffixForHeaderFiles
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   102
    ^ OperatingSystem isUNIXlike ifTrue:['.H'] ifFalse:['.STH']
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   103
!
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   104
2680
3f2dbbd7743f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2678
diff changeset
   105
usedCompiler:something
3f2dbbd7743f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2678
diff changeset
   106
    usedCompiler := something.
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   107
! !
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   108
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   109
!ProjectBuilder methodsFor:'building'!
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   110
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   111
build
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   112
    "/ intermediate - this will move into a commonly used utility class
2635
8b62bd023558 namespace change
Claus Gittinger <cg@exept.de>
parents: 2634
diff changeset
   113
    "/ (where all the project code support will be collected).
8b62bd023558 namespace change
Claus Gittinger <cg@exept.de>
parents: 2634
diff changeset
   114
2647
aedc794b630a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2644
diff changeset
   115
    |makeOutput|
aedc794b630a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2644
diff changeset
   116
aedc794b630a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2644
diff changeset
   117
    makeOutput := TextStream on:(Text new:10000).
aedc794b630a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2644
diff changeset
   118
    self buildWithColorizedOutputTo:makeOutput.
aedc794b630a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2644
diff changeset
   119
aedc794b630a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2644
diff changeset
   120
    TextView openWith:makeOutput contents.
aedc794b630a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2644
diff changeset
   121
!
aedc794b630a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2644
diff changeset
   122
aedc794b630a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2644
diff changeset
   123
buildWithColorizedOutputTo:makeOutput
aedc794b630a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2644
diff changeset
   124
    "/ intermediate - this will move into a commonly used utility class
aedc794b630a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2644
diff changeset
   125
    "/ (where all the project code support will be collected).
aedc794b630a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2644
diff changeset
   126
aedc794b630a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2644
diff changeset
   127
    |stdOut stdErr lock|
2635
8b62bd023558 namespace change
Claus Gittinger <cg@exept.de>
parents: 2634
diff changeset
   128
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   129
    lock := Semaphore forMutualExclusion.
2647
aedc794b630a *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2644
diff changeset
   130
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   131
    stdErr := ActorStream new
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   132
                    nextPutBlock:[:char |
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   133
                        lock critical:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   134
                            makeOutput emphasis:{#backgroundColor->Color red. #color->Color white.}.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   135
                            makeOutput nextPut:char.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   136
                            makeOutput emphasis:nil.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   137
                        ]
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   138
                    ];
2683
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   139
                    nextPutAllBlock:[:string |
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   140
                        lock critical:[          (string includesString:'das Ziel' )ifTrue:[self halt].
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   141
                            makeOutput emphasis:{#backgroundColor->Color red. #color->Color white.}.
2683
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   142
                            makeOutput nextPutAll:string.
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   143
                            makeOutput emphasis:nil.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   144
                        ]
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   145
                    ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   146
    stdOut := ActorStream new
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   147
                    nextPutBlock:[:char |
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   148
                        lock critical:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   149
                            makeOutput nextPut:char.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   150
                        ]
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   151
                    ];
2683
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   152
                    nextPutAllBlock:[:string |
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   153
                        lock critical:[         (string includesString:'das Ziel' )ifTrue:[self halt].
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   154
                            makeOutput nextPutAll:string.
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   155
                        ]
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   156
                    ].
2635
8b62bd023558 namespace change
Claus Gittinger <cg@exept.de>
parents: 2634
diff changeset
   157
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   158
    self buildWithOutputTo:stdOut errorTo:stdErr.
2611
Claus Gittinger <cg@exept.de>
parents: 2600
diff changeset
   159
!
Claus Gittinger <cg@exept.de>
parents: 2600
diff changeset
   160
Claus Gittinger <cg@exept.de>
parents: 2600
diff changeset
   161
buildWithOutputTo:stdOut errorTo:stdErr
Claus Gittinger <cg@exept.de>
parents: 2600
diff changeset
   162
    "/ intermediate - this will move into a commonly used utility class
Claus Gittinger <cg@exept.de>
parents: 2600
diff changeset
   163
    "/ (where all the project code support will be collected).
Claus Gittinger <cg@exept.de>
parents: 2600
diff changeset
   164
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   165
    |module directory|
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   166
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   167
    projectDefinitionClass := ProjectDefinition definitionClassForPackage:package.
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   168
    projectDefinitionClass isNil ifTrue:[
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   169
        self error:('Missing ProjectDefinition class for "',package asString,'"')
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   170
    ].
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   171
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   172
    "/ ensure that everything is loaded...
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   173
    projectDefinitionClass loadAsAutoloaded:false.
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   174
    projectDefinitionClass loadExtensions.
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   175
    projectDefinitionClass loadAllClassesAsAutoloaded:false.
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   176
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   177
    module := package module.
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   178
    directory := package directory.
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   179
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   180
    buildDirectory isNil ifTrue:[
2634
3f14301cec84 added: #buildDirectory:
Claus Gittinger <cg@exept.de>
parents: 2633
diff changeset
   181
        buildDirectory := PreviousBuildDirectory ifNil:[ UserPreferences current buildDirectory ].
3f14301cec84 added: #buildDirectory:
Claus Gittinger <cg@exept.de>
parents: 2633
diff changeset
   182
        buildDirectory isNil ifTrue:[
3f14301cec84 added: #buildDirectory:
Claus Gittinger <cg@exept.de>
parents: 2633
diff changeset
   183
            buildDirectory := Filename tempDirectory construct:'stx_build'.
3f14301cec84 added: #buildDirectory:
Claus Gittinger <cg@exept.de>
parents: 2633
diff changeset
   184
        ].
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   185
    ].
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   186
    buildDirectory := buildDirectory asFilename.
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   187
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   188
    "/ self validateBuildDirectoryIsPresent.
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   189
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   190
    PreviousBuildDirectory := buildDirectory.
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   191
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   192
    "/ UserPreferences current localBuild:true
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   193
    UserPreferences current localBuild ifFalse:[
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   194
        SourceCodeManager notNil ifTrue:[
2861
b8c6e02e60a1 Do not call obsolete methods in SourceCodeManager class
Stefan Vogel <sv@exept.de>
parents: 2852
diff changeset
   195
            sourceCodeManager := SourceCodeManagerUtilities default sourceCodeManagerFor:projectDefinitionClass.
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   196
        ]
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   197
    ].
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   198
    sourceCodeManager := nil.
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   199
2598
2bb47a698d59 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2596
diff changeset
   200
    myTopDirectory := 
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   201
        Smalltalk packagePath 
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   202
            detect:[:aPath |
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   203
                (aPath asFilename / 'stx' / 'include') exists
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   204
                and: [ (aPath asFilename / 'stx' / 'rules') exists ]]
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   205
            ifNone:nil.       
2598
2bb47a698d59 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2596
diff changeset
   206
    myTopDirectory isNil ifTrue:[
2bb47a698d59 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2596
diff changeset
   207
        self error:('Cannot figure out my top directory (where stx/include and stx/rules are)')
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   208
    ].
2598
2bb47a698d59 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2596
diff changeset
   209
    myTopDirectory := myTopDirectory asFilename.
2bb47a698d59 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2596
diff changeset
   210
    mySTXTopDirectory := myTopDirectory / 'stx'.
2613
b8d38caaa884 changed: #buildWithOutputTo:errorTo:
Claus Gittinger <cg@exept.de>
parents: 2612
diff changeset
   211
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   212
    self setupBuildDirectory.
2628
57b363325368 changed:
Claus Gittinger <cg@exept.de>
parents: 2622
diff changeset
   213
    self activityNotification:'Generating stc directory...'.
2599
Claus Gittinger <cg@exept.de>
parents: 2598
diff changeset
   214
    self copySTCDirectoryForBuild.
2628
57b363325368 changed:
Claus Gittinger <cg@exept.de>
parents: 2622
diff changeset
   215
    self activityNotification:'Generating source files...'.
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   216
    self generateSourceFiles.
2672
a1cda5d8943d changed: #buildWithOutputTo:errorTo:
Claus Gittinger <cg@exept.de>
parents: 2647
diff changeset
   217
    self activityNotification:'Copying dlls for linkage...'.
2600
bfde5434dcdd added:5 methods
Claus Gittinger <cg@exept.de>
parents: 2599
diff changeset
   218
    self copyDLLsForLinkage.
2672
a1cda5d8943d changed: #buildWithOutputTo:errorTo:
Claus Gittinger <cg@exept.de>
parents: 2647
diff changeset
   219
    self activityNotification:'Copying support files for linkage...'.
2600
bfde5434dcdd added:5 methods
Claus Gittinger <cg@exept.de>
parents: 2599
diff changeset
   220
    self copySupportFilesForLinkage.
bfde5434dcdd added:5 methods
Claus Gittinger <cg@exept.de>
parents: 2599
diff changeset
   221
    self copyStartupFilesFromSmalltalk.
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   222
2628
57b363325368 changed:
Claus Gittinger <cg@exept.de>
parents: 2622
diff changeset
   223
    self activityNotification:'Executing make...'.
2611
Claus Gittinger <cg@exept.de>
parents: 2600
diff changeset
   224
    self makeWithOutputTo:stdOut errorTo:stdErr.
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   225
!
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   226
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   227
copyDLLsForLinkage
2723
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   228
    |targetBuildDir preRequisites dllRelativePaths|
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   229
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   230
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   231
    targetBuildDir := buildDirectory / package module / package directory.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   232
2723
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   233
    preRequisites := projectDefinitionClass allPreRequisites.
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   234
    OperatingSystem isUNIXlike ifTrue:[
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   235
        "For now: unix Makefiles require some libs implicitely..."
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   236
        preRequisites := preRequisites union:#(
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   237
                               'stx:goodies/refactoryBrowser/parser'
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   238
                               'stx:libtool'
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   239
                            ).
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   240
    ].
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   241
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   242
    preRequisites do:[:eachPackageToFileout |
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   243
        |packageId packageDef packageModule packageDirectory packageTargetDir
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   244
         dllSource dllSourceDir libraryName dllRelativePath|
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   245
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   246
        packageId := eachPackageToFileout asPackageId.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   247
        packageModule := packageId module.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   248
        packageDirectory := packageId directory.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   249
        packageTargetDir := (buildDirectory / packageModule / packageDirectory) recursiveMakeDirectory.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   250
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   251
        packageDef := packageId projectDefinitionClass.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   252
        libraryName := packageDef libraryName.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   253
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   254
        "/ mhmh - take them from my tree or from the projects/smalltalk execution directory ??
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   255
        dllSourceDir := myTopDirectory / packageModule / packageDirectory.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   256
        OperatingSystem isMSWINDOWSlike ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   257
"/            dllRelativePath := 'objvc','/',(libraryName,'.dll').
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   258
"/            (dllSourceDir / dllRelativePath) exists 
2723
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   259
            dllRelativePaths := Array with:('objbc\', libraryName, '.dll').
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   260
        ] ifFalse:[
2723
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   261
            dllRelativePaths := Array with:(libraryName,'.so').
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   262
            (packageModule = 'stx' and:[packageDirectory = 'libview']) ifTrue:[
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   263
                dllRelativePaths := dllRelativePaths, #('XWorkstation.so' 'GLXWorkstation.so').
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   264
            ].
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   265
        ].
2723
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   266
        dllRelativePaths do:[:dllRelativePath|
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   267
            ((packageTargetDir / dllRelativePath) exists not
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   268
             or:[(dllSourceDir / dllRelativePath) fileSize ~= (packageTargetDir / dllRelativePath) fileSize
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   269
             or:[(dllSourceDir / dllRelativePath) modificationTime >= (packageTargetDir / dllRelativePath) modificationTime
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   270
             "/ or:[ ((dllSourceDir / dllRelativePath) sameContentsAs:(packageTargetDir / dllRelativePath)) not ]
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   271
            ]]) ifTrue:[
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   272
                (packageTargetDir / dllRelativePath) directory recursiveMakeDirectory.
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   273
                (dllSourceDir / dllRelativePath) copyTo:(packageTargetDir / dllRelativePath).    
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   274
            ].
d03a850ebc29 changed: #copyDLLsForLinkage
Stefan Vogel <sv@exept.de>
parents: 2684
diff changeset
   275
        ].
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   276
    ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   277
!
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   278
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   279
copyDirectory:relativepath
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   280
    "/ need rules in stx
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   281
    ((Smalltalk projectDirectoryForPackage:'stx') asFilename construct:relativepath)
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   282
        recursiveCopyTo:(buildDirectory construct:'stx').
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   283
!
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   284
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   285
copyDirectoryForBuild:subdir
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   286
    |targetDir targetFile|
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   287
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   288
    targetDir := buildDirectory / 'stx' / subdir.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   289
    targetDir exists ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   290
        targetDir makeDirectory.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   291
    ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   292
    (mySTXTopDirectory / subdir) directoryContentsAsFilenamesDo:[:eachFile |
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   293
        eachFile isDirectory ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   294
            targetFile := targetDir / eachFile baseName.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   295
            (targetFile exists not
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   296
            or:[ targetFile modificationTime < eachFile modificationTime ]) ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   297
                self activityNotification:'copying ',eachFile pathName,'...'.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   298
                eachFile copyTo:(targetDir construct:eachFile baseName)
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   299
            ]
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   300
        ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   301
    ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   302
    self activityNotification:nil
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   303
!
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   304
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   305
copyResourcesForPackage:aPackage
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   306
    |module directory|
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   307
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   308
    module := aPackage asPackageId module.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   309
    directory := aPackage asPackageId directory.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   310
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   311
    (myTopDirectory / module / directory / 'resources' ) exists ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   312
        (myTopDirectory / module / directory / 'resources' )
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   313
            recursiveCopyTo:(buildDirectory / module / directory)
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   314
    ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   315
    (myTopDirectory / module / directory / 'styles' ) exists ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   316
        (myTopDirectory / module / directory / 'styles' )
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   317
            recursiveCopyTo:(buildDirectory / module / directory)
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   318
    ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   319
!
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   320
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   321
copySTCDirectoryForBuild
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   322
    |targetDir stc files|
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   323
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   324
    targetDir := buildDirectory / 'stx' / 'stc'.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   325
    targetDir exists ifFalse:[ targetDir makeDirectory ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   326
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   327
    stc := OperatingSystem isMSWINDOWSlike 
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   328
                ifTrue:[ 'stc.exe' ]
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   329
                ifFalse:[ 'stc' ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   330
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   331
    files := #( ) copyWith:stc.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   332
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   333
    files do:[:eachFile |
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   334
        |sourceFile targetFile|
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   335
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   336
        sourceFile := mySTXTopDirectory / 'stc' / eachFile.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   337
        targetFile := targetDir / eachFile.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   338
        (targetFile exists not
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   339
        or:[ targetFile modificationTime < sourceFile modificationTime ]) ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   340
            self activityNotification:'copying ',sourceFile pathName,'...'.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   341
            sourceFile copyTo:targetFile
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   342
        ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   343
    ].
2683
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   344
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   345
    OperatingSystem isUNIXlike ifTrue:[
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   346
        (targetDir / 'stc') makeExecutableForAll    
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   347
    ].
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   348
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   349
    self activityNotification:nil
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   350
!
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   351
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   352
copyStartupFilesFromSmalltalk
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   353
    (buildDirectory / 'stx' / 'projects/smalltalk' ) exists ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   354
        (buildDirectory / 'stx' / 'projects/smalltalk' ) recursiveMakeDirectory.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   355
    ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   356
2678
cca2788228ad added: #copySupportFilesForExecution
Claus Gittinger <cg@exept.de>
parents: 2677
diff changeset
   357
    #( 
cca2788228ad added: #copySupportFilesForExecution
Claus Gittinger <cg@exept.de>
parents: 2677
diff changeset
   358
        'keyboard.rc' 
cca2788228ad added: #copySupportFilesForExecution
Claus Gittinger <cg@exept.de>
parents: 2677
diff changeset
   359
        'keyboardMacros.rc' 
cca2788228ad added: #copySupportFilesForExecution
Claus Gittinger <cg@exept.de>
parents: 2677
diff changeset
   360
        'display.rc' 
cca2788228ad added: #copySupportFilesForExecution
Claus Gittinger <cg@exept.de>
parents: 2677
diff changeset
   361
        'd_win32.rc'
cca2788228ad added: #copySupportFilesForExecution
Claus Gittinger <cg@exept.de>
parents: 2677
diff changeset
   362
        'host.rc' 
cca2788228ad added: #copySupportFilesForExecution
Claus Gittinger <cg@exept.de>
parents: 2677
diff changeset
   363
        'h_win32.rc'  
cca2788228ad added: #copySupportFilesForExecution
Claus Gittinger <cg@exept.de>
parents: 2677
diff changeset
   364
        'smalltalk.rc'  
cca2788228ad added: #copySupportFilesForExecution
Claus Gittinger <cg@exept.de>
parents: 2677
diff changeset
   365
        'private.rc'  
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   366
    ) do:[:fn |
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   367
        (myTopDirectory / 'stx' / 'projects/smalltalk' / fn)
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   368
            copyTo: (buildDirectory / 'stx' / 'projects/smalltalk' / fn)
2678
cca2788228ad added: #copySupportFilesForExecution
Claus Gittinger <cg@exept.de>
parents: 2677
diff changeset
   369
    ].
cca2788228ad added: #copySupportFilesForExecution
Claus Gittinger <cg@exept.de>
parents: 2677
diff changeset
   370
cca2788228ad added: #copySupportFilesForExecution
Claus Gittinger <cg@exept.de>
parents: 2677
diff changeset
   371
    (myTopDirectory / 'stx' / 'doc/online/english/LICENCE_STX.html')
cca2788228ad added: #copySupportFilesForExecution
Claus Gittinger <cg@exept.de>
parents: 2677
diff changeset
   372
            copyTo: (buildDirectory / 'stx' / 'projects/smalltalk' / 'LICENCE_STX.html').
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   373
!
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   374
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   375
copySupportFilesForLinkage
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   376
    |files|
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   377
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   378
    OperatingSystem isMSWINDOWSlike ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   379
        files := #( 
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   380
                    'support/win32/borland/cs3245.dll' 
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   381
                    'support/win32/X11.dll'
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   382
                    'support/win32/Xext.dll'
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   383
                    'librun/librun.dll'
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   384
                    'libbc/librun.lib'
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   385
                    'libbc/cs32i.lib'
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   386
                    'librun/genDate.exe'
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   387
                    'librun/main.c'
2673
100b4dd5c3c2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2672
diff changeset
   388
                    'projects/smalltalk/stx_16x16.ico'
100b4dd5c3c2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2672
diff changeset
   389
                    'projects/smalltalk/stx_32x32.ico'
100b4dd5c3c2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2672
diff changeset
   390
                    'projects/smalltalk/stx_splash.bmp'
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   391
                 ).
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   392
    ] ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   393
        files := #(
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   394
                    'librun/main.c'
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   395
                    'librun/librun.so'
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   396
                )
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   397
    ].
2677
e2c24a1be97f changed: #copySupportFilesForLinkage
Claus Gittinger <cg@exept.de>
parents: 2673
diff changeset
   398
    files := files asOrderedCollection.
e2c24a1be97f changed: #copySupportFilesForLinkage
Claus Gittinger <cg@exept.de>
parents: 2673
diff changeset
   399
e2c24a1be97f changed: #copySupportFilesForLinkage
Claus Gittinger <cg@exept.de>
parents: 2673
diff changeset
   400
    OperatingSystem isMSWINDOWSlike ifTrue:[
e2c24a1be97f changed: #copySupportFilesForLinkage
Claus Gittinger <cg@exept.de>
parents: 2673
diff changeset
   401
        projectDefinitionClass applicationIconFileName notNil ifTrue:[
2678
cca2788228ad added: #copySupportFilesForExecution
Claus Gittinger <cg@exept.de>
parents: 2677
diff changeset
   402
            files add:('projects/smalltalk/',projectDefinitionClass applicationIconFileName,'.ico')
cca2788228ad added: #copySupportFilesForExecution
Claus Gittinger <cg@exept.de>
parents: 2677
diff changeset
   403
        ].
cca2788228ad added: #copySupportFilesForExecution
Claus Gittinger <cg@exept.de>
parents: 2677
diff changeset
   404
        projectDefinitionClass splashFileName notNil ifTrue:[
cca2788228ad added: #copySupportFilesForExecution
Claus Gittinger <cg@exept.de>
parents: 2677
diff changeset
   405
            files add:('projects/smalltalk/',projectDefinitionClass splashFileName,'.bmp')
cca2788228ad added: #copySupportFilesForExecution
Claus Gittinger <cg@exept.de>
parents: 2677
diff changeset
   406
        ].
2677
e2c24a1be97f changed: #copySupportFilesForLinkage
Claus Gittinger <cg@exept.de>
parents: 2673
diff changeset
   407
    ].
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   408
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   409
    files do:[:dllRelativePath |
2684
80fe0f753fd8 changed: #copySupportFilesForLinkage
sr
parents: 2683
diff changeset
   410
        (mySTXTopDirectory / dllRelativePath) exists ifTrue:[
80fe0f753fd8 changed: #copySupportFilesForLinkage
sr
parents: 2683
diff changeset
   411
            ((buildDirectory / 'stx' / dllRelativePath) exists
80fe0f753fd8 changed: #copySupportFilesForLinkage
sr
parents: 2683
diff changeset
   412
            and:[ (mySTXTopDirectory / dllRelativePath) fileSize = (buildDirectory / 'stx' / dllRelativePath) fileSize
80fe0f753fd8 changed: #copySupportFilesForLinkage
sr
parents: 2683
diff changeset
   413
            and:[ (mySTXTopDirectory / dllRelativePath) modificationTime < (buildDirectory / 'stx' / dllRelativePath) modificationTime
80fe0f753fd8 changed: #copySupportFilesForLinkage
sr
parents: 2683
diff changeset
   414
            "/ and:[ (mySTXTopDirectory / dllRelativePath) sameContentsAs:(targetBuildDir / dllRelativePath) ]
80fe0f753fd8 changed: #copySupportFilesForLinkage
sr
parents: 2683
diff changeset
   415
            ]]) ifFalse:[
80fe0f753fd8 changed: #copySupportFilesForLinkage
sr
parents: 2683
diff changeset
   416
                (buildDirectory / 'stx' / dllRelativePath) directory recursiveMakeDirectory.
80fe0f753fd8 changed: #copySupportFilesForLinkage
sr
parents: 2683
diff changeset
   417
                (mySTXTopDirectory / dllRelativePath) copyTo:(buildDirectory / 'stx' / dllRelativePath).    
80fe0f753fd8 changed: #copySupportFilesForLinkage
sr
parents: 2683
diff changeset
   418
            ]
80fe0f753fd8 changed: #copySupportFilesForLinkage
sr
parents: 2683
diff changeset
   419
        ] ifFalse:[
80fe0f753fd8 changed: #copySupportFilesForLinkage
sr
parents: 2683
diff changeset
   420
            self error:'Missing file: ',dllRelativePath printString mayProceed:true.
80fe0f753fd8 changed: #copySupportFilesForLinkage
sr
parents: 2683
diff changeset
   421
        ].
2614
Claus Gittinger <cg@exept.de>
parents: 2613
diff changeset
   422
    ].
2600
bfde5434dcdd added:5 methods
Claus Gittinger <cg@exept.de>
parents: 2599
diff changeset
   423
!
bfde5434dcdd added:5 methods
Claus Gittinger <cg@exept.de>
parents: 2599
diff changeset
   424
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   425
createHeaderFileFor:aClass in:packageTargetDir
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   426
    |instVarList classInstVarList classVarList bindings superclassFilename
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   427
     template file newContents oldContents|
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   428
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   429
    instVarList := StringCollection new.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   430
    aClass instVarNames do:[:v |
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   431
        instVarList add:('OBJ %1;' bindWith:v)
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   432
    ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   433
    classInstVarList := StringCollection new.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   434
    aClass class instVarNames do:[:v |
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   435
(v includes:$_) ifTrue:[self halt].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   436
        classInstVarList add:('OBJ %1;' bindWith:v)
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   437
    ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   438
    classVarList := StringCollection new.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   439
    aClass classVarNames do:[:v |
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   440
        classVarList add:('extern OBJ %1_%2;' bindWith:aClass name with:v)
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   441
    ].
2614
Claus Gittinger <cg@exept.de>
parents: 2613
diff changeset
   442
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   443
    bindings := Dictionary new.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   444
    bindings at:'ClassName' put:aClass name. 
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   445
    aClass superclass isNil ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   446
        bindings at:'SuperclassName' put:'-'. 
2852
a3007ba3b216 changed:
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   447
        bindings at:'SuperclassFileInclude' put:''.
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   448
    ] ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   449
        bindings at:'SuperclassName' put:aClass superclass name. 
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   450
        bindings at:'SuperclassFileName' put:(superclassFilename := Smalltalk fileNameForClass:aClass superclass).
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   451
        bindings at:'SuperclassFileInclude' put:('#include "%1.STH"' bindWith:superclassFilename).
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   452
    ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   453
    bindings at:'InstVarList' put:instVarList asString. 
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   454
    bindings at:'ClassVarList' put:classVarList asString. 
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   455
    bindings at:'ClassInstVarList' put:classInstVarList asString. 
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   456
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   457
    template := 
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   458
'/* This file was generated by ProjectBuilder. */
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   459
/* !!!!!!!! Do not change by hand !!!!!!!! */
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   460
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   461
/* Class: %(ClassName) */
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   462
/* Superclass: %(SuperclassName) */
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   463
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   464
%(SuperclassFileInclude)
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   465
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   466
/* INDIRECTGLOBALS */
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   467
#ifdef _HEADER_INST_
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   468
%(InstVarList)
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   469
#endif /* _HEADER_INST_ */
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   470
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   471
#ifdef _HEADER_CLASS_
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   472
%(ClassVarList)
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   473
#endif /* _HEADER_CLASS_ */
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   474
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   475
#ifdef _HEADER_CLASSINST_
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   476
%(ClassInstVarList)
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   477
#endif /* _HEADER_CLASSINST_ */
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   478
'.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   479
    newContents := template bindWithArguments:bindings.
2683
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   480
    file := packageTargetDir asFilename / ((Smalltalk fileNameForClass:aClass),(self suffixForHeaderFiles)).
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   481
    (file exists not
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   482
    or:[ (oldContents := file contents) ~= newContents ]) ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   483
        file contents: newContents.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   484
    ].
2852
a3007ba3b216 changed:
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   485
a3007ba3b216 changed:
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   486
    "Modified: / 15-08-2011 / 14:58:46 / cg"
2614
Claus Gittinger <cg@exept.de>
parents: 2613
diff changeset
   487
!
Claus Gittinger <cg@exept.de>
parents: 2613
diff changeset
   488
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   489
generateSourceFiles
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   490
    sourceCodeManager notNil ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   491
        "/ check out / generate files there
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   492
        self generateSourceFilesByCheckingOutUsing:sourceCodeManager
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   493
    ] ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   494
        "/ local build
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   495
        "/ fileout the project
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   496
        self generateSourceFilesByFilingOut
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   497
    ]
2599
Claus Gittinger <cg@exept.de>
parents: 2598
diff changeset
   498
!
Claus Gittinger <cg@exept.de>
parents: 2598
diff changeset
   499
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   500
generateSourceFilesByCheckingOutUsing:aSourceCodeManager
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   501
    "/ will no longer be needed/supported
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   502
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   503
    |repository stxRepository module directory|
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   504
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   505
self halt.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   506
    "/ check out / generate files there
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   507
    repository := (aSourceCodeManager repositoryNameForModule:module) ifNil:[aSourceCodeManager repositoryName].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   508
    stxRepository := aSourceCodeManager repositoryName.
2600
bfde5434dcdd added:5 methods
Claus Gittinger <cg@exept.de>
parents: 2599
diff changeset
   509
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   510
    (buildDirectory construct:'stx') exists ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   511
        (module ~= 'stx') ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   512
            OperatingSystem
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   513
                executeCommand:('cvs -d ',stxRepository,' co stx')
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   514
                inputFrom:nil
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   515
                outputTo:Transcript
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   516
                errorTo:Transcript
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   517
                inDirectory:buildDirectory
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   518
                onError:[:status| self error:'cvs update stx failed'].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   519
        ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   520
    ].
2635
8b62bd023558 namespace change
Claus Gittinger <cg@exept.de>
parents: 2634
diff changeset
   521
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   522
    ((buildDirectory construct:module) construct:'CVS') exists ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   523
        OperatingSystem
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   524
            executeCommand:('cvs -d ',repository,' co -l ',directory)
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   525
            inputFrom:nil
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   526
            outputTo:Transcript
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   527
            errorTo:Transcript
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   528
            inDirectory:buildDirectory
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   529
            onError:[:status| self error:'cvs update failed'].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   530
    ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   531
    OperatingSystem
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   532
        executeCommand:'cvs upd -d'
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   533
        inputFrom:nil
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   534
        outputTo:Transcript
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   535
        errorTo:Transcript
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   536
        inDirectory:(buildDirectory construct:module)
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   537
        onError:[:status| self error:'cvs update failed'].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   538
self halt.
2600
bfde5434dcdd added:5 methods
Claus Gittinger <cg@exept.de>
parents: 2599
diff changeset
   539
!
bfde5434dcdd added:5 methods
Claus Gittinger <cg@exept.de>
parents: 2599
diff changeset
   540
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   541
generateSourceFilesByFilingOut
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   542
    "/ local build
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   543
    "/ fileout the project
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   544
2844
5e4e46856d8d changed: #generateSourceFilesByFilingOut
Stefan Vogel <sv@exept.de>
parents: 2793
diff changeset
   545
    |fullPathName|
5e4e46856d8d changed: #generateSourceFilesByFilingOut
Stefan Vogel <sv@exept.de>
parents: 2793
diff changeset
   546
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   547
    (package module ~= 'stx') ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   548
        (buildDirectory / package module) makeDirectory.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   549
    ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   550
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   551
    "/ file out the package(s) which are to be built
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   552
    ((Array with:package))
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   553
    do:[:eachPackageToFileout |
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   554
        |packageId packageModule packageDirectory packageTargetDir packageDef|
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   555
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   556
        packageId := eachPackageToFileout asPackageId.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   557
        packageModule := packageId module.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   558
        packageDirectory := packageId directory.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   559
        packageTargetDir := (buildDirectory / packageModule / packageDirectory) recursiveMakeDirectory.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   560
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   561
        packageDef := packageId projectDefinitionClass.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   562
        (packageDef compiled_classNames_common ,
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   563
        packageDef compiled_classNamesForPlatform) do:[:eachClassName |
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   564
            |cls fileName newSource|
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   565
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   566
            cls := Smalltalk classNamed:eachClassName.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   567
            self assert:cls isLoaded.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   568
            fileName := (Smalltalk fileNameForClass:cls),'.st'.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   569
            fileName := packageTargetDir asFilename construct:fileName.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   570
            fileName exists ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   571
                newSource := String streamContents:[:s | cls fileOutOn:s withTimeStamp:false].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   572
                newSource = fileName contentsAsString ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   573
                    fileName contents:newSource
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   574
                ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   575
            ] ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   576
                cls fileOutIn:packageTargetDir withTimeStamp:false
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   577
            ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   578
        ].
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   579
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   580
"/        (Smalltalk allClassesInPackage:eachPackageToFileout) do:[:cls |
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   581
"/            cls isPrivate ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   582
"/                cls isLoaded ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   583
"/                    self halt.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   584
"/                    cls autoload.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   585
"/                ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   586
"/                cls fileOutIn:packageTargetDir
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   587
"/            ]
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   588
"/        ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   589
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   590
        projectDefinitionClass forEachFileNameAndGeneratedContentsDo:[:fileName :fileContents |
2844
5e4e46856d8d changed: #generateSourceFilesByFilingOut
Stefan Vogel <sv@exept.de>
parents: 2793
diff changeset
   591
            fullPathName := packageTargetDir construct:fileName.
5e4e46856d8d changed: #generateSourceFilesByFilingOut
Stefan Vogel <sv@exept.de>
parents: 2793
diff changeset
   592
            fullPathName directory exists ifFalse:[
5e4e46856d8d changed: #generateSourceFilesByFilingOut
Stefan Vogel <sv@exept.de>
parents: 2793
diff changeset
   593
                "take care for files like 'autopackage/default.apspec'"
5e4e46856d8d changed: #generateSourceFilesByFilingOut
Stefan Vogel <sv@exept.de>
parents: 2793
diff changeset
   594
                fullPathName directory makeDirectory.
5e4e46856d8d changed: #generateSourceFilesByFilingOut
Stefan Vogel <sv@exept.de>
parents: 2793
diff changeset
   595
            ].
5e4e46856d8d changed: #generateSourceFilesByFilingOut
Stefan Vogel <sv@exept.de>
parents: 2793
diff changeset
   596
            (fullPathName exists
5e4e46856d8d changed: #generateSourceFilesByFilingOut
Stefan Vogel <sv@exept.de>
parents: 2793
diff changeset
   597
             and:[ fullPathName contents = fileContents ]) ifFalse:[
5e4e46856d8d changed: #generateSourceFilesByFilingOut
Stefan Vogel <sv@exept.de>
parents: 2793
diff changeset
   598
                fullPathName contents:fileContents.
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   599
            ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   600
        ].    
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   601
    ].
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   602
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   603
    "/ generate header files in prerequisite packages...
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   604
    (projectDefinitionClass allPreRequisites)
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   605
    do:[:eachPackageToFileout |
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   606
        |packageId packageDef packageModule packageDirectory packageTargetDir|
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   607
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   608
        packageId := eachPackageToFileout asPackageId.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   609
        packageModule := packageId module.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   610
        packageDirectory := packageId directory.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   611
        packageTargetDir := (buildDirectory / packageModule / packageDirectory) recursiveMakeDirectory.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   612
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   613
        packageDef := packageId projectDefinitionClass.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   614
        (packageDef compiled_classNames_common ,
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   615
        packageDef compiled_classNamesForPlatform) do:[:eachClassName |
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   616
            |cls|
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   617
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   618
            cls := Smalltalk classNamed:eachClassName.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   619
            "/ self assert:cls isLoaded.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   620
            cls isLoaded ifTrue:[    
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   621
                self createHeaderFileFor:cls in:packageTargetDir
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   622
            ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   623
        ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   624
        self copyResourcesForPackage:eachPackageToFileout.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   625
    ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   626
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   627
"/    stx_libbasic2 preRequisitesForBuilding#(#'stx:libbasic')
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   628
!
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   629
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   630
makeWithOutputTo:stdOut errorTo:stdErr
2680
3f2dbbd7743f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2678
diff changeset
   631
    |module directory compilerFlag makeCommand|
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   632
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   633
    module := package module.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   634
    directory := package directory.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   635
2680
3f2dbbd7743f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2678
diff changeset
   636
    makeCommand := ParserFlags makeCommand.
2793
e03152b97cdd usevc/usebc handling
Claus Gittinger <cg@exept.de>
parents: 2741
diff changeset
   637
    usedCompiler = 'vc' ifTrue:[ makeCommand := 'vcmake'. compilerFlag := '-DUSEVC' ].
e03152b97cdd usevc/usebc handling
Claus Gittinger <cg@exept.de>
parents: 2741
diff changeset
   638
    usedCompiler = 'lcc' ifTrue:[ makeCommand := 'lcmake'. compilerFlag := '-DUSELCC' ].
2680
3f2dbbd7743f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2678
diff changeset
   639
    usedCompiler = 'gcc' ifTrue:[ makeCommand := 'make'. ].
2852
a3007ba3b216 changed:
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   640
    "/ makeCommand := makeCommand, ' TOP=', mySTXTopDirectory pathName.
2680
3f2dbbd7743f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2678
diff changeset
   641
2683
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   642
    OperatingSystem isUNIXlike ifTrue:[
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   643
        OperatingSystem
2845
0d52c66fbc8e changed: #makeWithOutputTo:errorTo:
Stefan Vogel <sv@exept.de>
parents: 2844
diff changeset
   644
            executeCommand:('sh %1/rules/stmkmf' bindWith:mySTXTopDirectory pathName)
2683
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   645
            inputFrom:nil
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   646
            outputTo:stdOut
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   647
            errorTo:stdErr
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   648
            inDirectory:(buildDirectory / module / directory)
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   649
            onError:[:status| self error:'make failed'].
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   650
    ].
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   651
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   652
    projectDefinitionClass isLibraryDefinition ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   653
        OperatingSystem
2680
3f2dbbd7743f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2678
diff changeset
   654
            executeCommand:(makeCommand,' classLibRule')
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   655
            inputFrom:nil
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   656
            outputTo:stdOut
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   657
            errorTo:stdErr
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   658
            inDirectory:(buildDirectory / module / directory)
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   659
            onError:[:status| self error:'make failed'].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   660
    ] ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   661
        OperatingSystem
2680
3f2dbbd7743f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2678
diff changeset
   662
            executeCommand:(makeCommand,' exe')
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   663
            inputFrom:nil
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   664
            outputTo:stdOut
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   665
            errorTo:stdErr
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   666
            inDirectory:(buildDirectory / module / directory)
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   667
            onError:[:status| self error:'make failed'].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   668
2673
100b4dd5c3c2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2672
diff changeset
   669
        (makeExeOnly ? false) ifFalse:[
100b4dd5c3c2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2672
diff changeset
   670
            OperatingSystem
2680
3f2dbbd7743f *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2678
diff changeset
   671
                executeCommand:(makeCommand,' setup')
2673
100b4dd5c3c2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2672
diff changeset
   672
                inputFrom:nil
100b4dd5c3c2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2672
diff changeset
   673
                outputTo:stdOut
100b4dd5c3c2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2672
diff changeset
   674
                errorTo:stdErr
100b4dd5c3c2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2672
diff changeset
   675
                inDirectory:(buildDirectory / module / directory)
100b4dd5c3c2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2672
diff changeset
   676
                onError:[:status| self error:'make failed'].
100b4dd5c3c2 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2672
diff changeset
   677
        ]
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   678
    ]
2793
e03152b97cdd usevc/usebc handling
Claus Gittinger <cg@exept.de>
parents: 2741
diff changeset
   679
2852
a3007ba3b216 changed:
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   680
    "Modified: / 15-08-2011 / 14:49:21 / cg"
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   681
!
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   682
2683
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   683
recursiveCopyDirectoryForBuild:subdir
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   684
    |targetDir|
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   685
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   686
    targetDir := buildDirectory / 'stx' / subdir.
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   687
    targetDir exists ifFalse:[
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   688
        targetDir makeDirectory.
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   689
    ].
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   690
    (mySTXTopDirectory / subdir) directoryContentsAsFilenamesDo:[:eachFile |
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   691
        eachFile recursiveCopyTo:(targetDir construct:eachFile baseName)
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   692
    ].
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   693
    self activityNotification:nil
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   694
!
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   695
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   696
setupBuildDirectory
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   697
    buildDirectory exists ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   698
        buildDirectory recursiveMakeDirectory.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   699
    ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   700
    (buildDirectory / 'stx') exists ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   701
        (buildDirectory / 'stx') makeDirectory.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   702
    ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   703
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   704
    self copyDirectoryForBuild:'include'.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   705
    self copyDirectoryForBuild:'rules'.
2683
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   706
    OperatingSystem isUNIXlike ifTrue:[
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   707
        self recursiveCopyDirectoryForBuild:'configurations'.
ff39502be3a2 some tries for UNIX - unfinished
sr
parents: 2680
diff changeset
   708
    ]
2611
Claus Gittinger <cg@exept.de>
parents: 2600
diff changeset
   709
!
Claus Gittinger <cg@exept.de>
parents: 2600
diff changeset
   710
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   711
validateBuildDirectoryIsPresent
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   712
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   713
    ^ self.
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   714
2644
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   715
"/    [
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   716
"/        |default directoryIsOKForMe stc |
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   717
"/
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   718
"/        default := (buildDirectory ?
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   719
"/                          PreviousBuildDirectory)
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   720
"/                          ifNil:[ UserPreferences current buildDirectory].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   721
"/
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   722
"/        buildDirectory := Dialog requestDirectoryName:'Temporary Work-ROOT for build:'
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   723
"/                                 default:default.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   724
"/
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   725
"/        buildDirectory isEmptyOrNil ifTrue:[^ self].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   726
"/        buildDirectory := buildDirectory asFilename.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   727
"/        directoryIsOKForMe := true.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   728
"/
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   729
"/        buildDirectory exists ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   730
"/            Dialog warn:(self classResources string:'Work directory %1 does not exist.' with:buildDirectory).
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   731
"/            directoryIsOKForMe := false.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   732
"/        ] ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   733
"/            (buildDirectory construct:'stx') exists ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   734
"/                Dialog warn:(self classResources stringWithCRs:'Work directory must contain an stx subDirectory,\which contains (at least) the stc and include subdirectories.').
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   735
"/                directoryIsOKForMe := false.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   736
"/            ] ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   737
"/                stc := (OperatingSystem isMSDOSlike) ifTrue:['stc.exe'] ifFalse:['stc'].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   738
"/                (((buildDirectory construct:'stx')construct:'stc')construct:stc) exists ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   739
"/                    Dialog warn:(self classResources stringWithCRs:'Work directory must contain an stc compiler in the stx/stc subDirectory.').
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   740
"/                    directoryIsOKForMe := false.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   741
"/                ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   742
"/                ((buildDirectory construct:'stx')construct:'include') exists ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   743
"/                    Dialog warn:(self classResources stringWithCRs:'Work directory must have had a make run before (for include files to exists).').
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   744
"/                    directoryIsOKForMe := false.
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   745
"/                ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   746
"/            ]
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   747
"/        ].
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   748
"/        directoryIsOKForMe
Claus Gittinger <cg@exept.de>
parents: 2635
diff changeset
   749
"/    ] whileFalse
2596
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   750
! !
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   751
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   752
!ProjectBuilder class methodsFor:'documentation'!
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   753
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   754
version_CVS
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   755
    ^ '$Header$'
876679f78999 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   756
! !