--- a/patches Mon May 13 13:12:33 2002 +0200
+++ b/patches Tue May 21 10:16:25 2002 +0200
@@ -1,186 +1,10 @@
"/
"/ $Header$
"/
-"/ This file is processed at initial startup
+"/ This file is processed very early at initial startup (before any rc script)
"/ - not when resuming an image.
"/
-"/
-"/ install uncompiled classes as autoload
-"/ classes ... (if not already present)
-"/ Autoloaded classes will be automatically filed-in
-"/ when first accessed. This allows a smaller executable,
-"/ but creates a short delay, when the class is loaded on
-"/ first access.
-"/
-"/ You can add more classes to these lists -
-"/ i.e. all your classes you like to have around,
-"/ but which are not needed often enough to justify
-"/ machine code for them ...
-
-|cpu iSets requiredClasses enableJIT|
-
-'patches [info]: initial startup (snapshot image restart is faster) ...' infoPrintCR.
-
-"/
-"/ the JIT translator is known to work with the following
-"/ architectures:
-"/ ix86 (linux, win32, unixware)
-"/ sgi-mips (irix)
-"/ alpha (osf)
-"/ sparc (solaris) [only tested with v7 & v8 & v9 cpus]
-"/ aix (rs6k) [not very well tested]
-"/
-enableJIT := false.
-
-cpu := OperatingSystem getCPUType.
-(#(
- 'i386'
- 'sparc'
- 'mips'
- 'alpha'
-) includes:cpu) ifTrue:[
- enableJIT := true.
-
- cpu = 'sparc' ifTrue:[
- "/ for now, disable if we detect running on a sparcV10;
- "/ Reason:
- "/ we do not have v10 machines here at Exept (they even do not exist at this time),
- "/ and therefore have no way of checking if it runs on v10.
- "/ I dont want ST/X to crash on your side in that case ...
- "/ ... better run a bit slower than not running at all.
- "/ Please let us know if it runs and we will remove the code below
- "/ (which you should do as well).
-
- iSets := OperatingSystem getSystemInfo at:#instructionSets.
- (iSets includesString:'sparcv10') ifTrue:[
- 'patches [warning]: disable JIT for sparcV10 - not yet validated' infoPrintCR.
- enableJIT := false
- ]
- ]
-].
-
-enableJIT ifTrue:[
- "/ 'patches [info]: turn on JIT ...' infoPrintCR.
- ObjectMemory justInTimeCompilation:true.
-].
-
-"/ GLXWorkstation forceGL:true.
-"/ OperatingSystem disableSignal:14.
-
-ObjectMemory infoPrinting:false.
-"/ Smalltalk loadBinaries:true.
-Compiler allowUnderscoreInIdentifier:true.
-Compiler warnUnderscoreInIdentifier:false.
-Compiler warnSTXSpecials:false.
-
-"/
-"/ set the package for changes done below
-"/
-Project notNil ifTrue:[
- |p|
-
- p := Project new.
- p package:#'autoloaded'.
- p comment:'only for autoloaded classes'.
- Project current:p.
-].
-
-"/
-"/ when filing in, keep source as reference to file
-"/ (instead of keeping a string locally in the image)
-"/
-"/ I disable this - its dangerous if you fileIn
-"/ classes from other directories and fileOut later clobbers those files
-"/
-"/ ClassCategoryReader sourceMode:#reference.
-
-"/
-"/ the following are required (either compiled or interpreted) ...
-"/
-requiredClasses := #(
- ObsoleteObject
- "/ BinaryIOManager BinaryInputManager BinaryOutputManager BinaryObjectStorage
- StringCollection
- CachingRegistry Registry
-).
-
-requiredClasses do:[:s |
- (Smalltalk at:s) isNil ifTrue:[
- ('patches [info]: loading ' , s , ' ...') infoPrintCR.
- Smalltalk fileInClass:s initialize:true lazy:false silent:true
- ]
-].
-!
-
-|optionalViews|
-
-(Smalltalk at:#View) isNil ifTrue:[
- 'patches [info]: installing required autoloaded classes ...' infoPrintCR.
-
- optionalViews := #(
- DeviceWorkstation
- Workstation
- XWorkstation
- DisplayRootView
- SimpleView
- TopView
- StandardSystemView
- ModalBox
- View
- PseudoView
- DeviceDrawable
- DisplayMedium
- DisplaySurface
- GraphicsMedium
- DeviceGraphicsContext
- GraphicsContext
- Image
- ViewStyle
- KeyboardMap
- KeyboardForwarder
- TextCollector
- SynchronousWindowSensor
- WindowSensor
- WindowGroup
- WindowEvent
- WindowingTransformation
- FontDescription
- Font
- Form
- Cursor
- Color
- Depth1Image
- Depth8Image
- ResourcePack
- Model
- Controller
- ApplicationModel
- ApplicationWindow
- WindowBuilder
- PopUpView
- ShadowView
- Colormap
- DeviceHandle
- DisplayObject
- ).
- optionalViews do:[:s |
- "install if not already compiled-in"
- (Smalltalk at:s) isNil ifTrue:[
- Autoload subclass:s
- instanceVariableNames:''
- classVariableNames:''
- poolDictionaries:''
- category:'autoloaded-Views'
- ]
- ].
- (Smalltalk at:#DeviceWorkstation) autoload.
- (Smalltalk at:#XWorkstation) autoload.
- (Smalltalk at:#Workstation) autoload.
- (Smalltalk at:#DeviceHandle) autoload.
-].
-!
-
"/
"/ set the package for changes done below
"/