|
Class: ApplicationDefinition
Object
|
+--ProjectDefinition
|
+--ApplicationDefinition
|
+--stx_projects_webServer
- Package:
- stx:libbasic
- Category:
- System-Support-Projects
- Version:
- rev:
1.369
date: 2024/03/18 17:09:10
- user: matilk
- file: ApplicationDefinition.st directory: libbasic
- module: stx stc-classLibrary: libbasic
subclasses provide the info on the contents of a package/project and
how to build executables and class libraries and how to load/unload packages.
Actually, subclasses MUST be subclasses of the two abstract classes LibraryDefinition or
ApplicationDefinition. These two know how to generate all required help files for the
make/build/load process.
File creation is driven by file templates which are expanded using strings from the file mappings.
Concrete definition classes MUST redefine:
classNamesAndAttributes
list of classes which are part of the dll/exe
extensionMethodNames
list of extension methods
startupClassName / startupSelector
class and selector with which the show starts
buildTarget name of the generated exe-file
should redefine:
preRequisites list of required packages
iconFileName name of a .ico file containing the applications icon
companyName name of your company - will be shown by windows explorer
as attribute of a .dll or .exe
description short description; shown by windows explorer
legalCopyright copyright message; shown by windows explorer
productName product name; shown by windows explorer
applicationName app name; shown by windows explorer
might redefine:
isConsoleApplication if true, windows-build generates a console app.
isGUIApplication if true, the GUI framework is linked in
(as opposed to a non-GUI server-like executable)
The above info might be outdated a bit - see stx_projects_smalltalk as a concrete example.
copyrightCOPYRIGHT (c) 2006 by eXept Software AG
All Rights Reserved
This software is furnished under a license and may be used
only in accordance with the terms of that license and with the
inclusion of the above copyright notice. This software may not
be provided or otherwise made available to, or used by, any
other person. No title to or ownership of the software is
hereby transferred.
accessing
-
appSourcesProjects
-
Returns only the application projects (which are included in the application module)
Usage example(s):
bosch_dapasx_application appSourcesProjects
|
-
startupClass
-
the class, but only if loaded
-
stxSourcesProjects
-
Returns only the required STX projects (which are included in the STX module)
Usage example(s):
bosch_dapasx_application stxSourcesProjects
stx_projects_smalltalk stxSourcesProjects
exept_expecco_application stxSourcesProjects
|
code generation
-
forEachMethodsCodeToCompileDo: aTwoArgBlock ignoreOldDefinition: ignoreOldDefinition
-
redefined to add application stuff, such as definitions for the app-icon,
startup class and installation directory
-
startupClassName_code
-
generate code that answers the startupClass.
-
startupClassName_codeFor: aClassName
-
code that answers aClassName as the startupClass.
-
startupSelector_code
-
generate code that answers the startupSelector.
Checks if #open or #start are to be used for the startupClass.
-
startupSelector_codeFor: aSelector
-
generate code that answers aSelector as the startupSelector.
-
subProjects_code
-
generate code which returns a collection of subproject names.
Usage example(s):
bosch_dapasx subProjects_code
stx_goodies subProjects_code
exept_expecco subProjects_code
|
defaults
-
buildTarget
-
which target in the Makefile should be built by default?
For now, reasonable return values are 'exe', which builds the executable(s),
and 'ALL', which builds everything, including an installable package.
Here, 'ALL' is returned.
There is usually no need to redefine this default - we at exept do it for the
stx package only to speed up our own build, as we seldom need new install packages,
put often build new executables...
-
extraTargets
-
extra targets to be built when creating the exe
-
guiClassFileNames_unix
-
-
guiClassFileNames_win32
-
-
guiClasses_unix
-
-
guiClasses_win32
-
^ Array with:XWorkstation
-
needResources
-
answer true, if this application
needs resources to be installed. This is normally true.
Even non-GUI apps need some (libbasic/resources)
description
-
additionalFilesToInstall_osx
-
Each entry gives a pattern of a file to be copied and a destination directory.
Can be redefined in subclasses to install additional files under the Contents/MacOS folder;
to get to a parent folder, pass in a string like '../Library/...'
(keeping OSX specific stuff away from general things, like expecco libs).
-
additionalFilesToInstall_unix
-
application-specific files to be installed.
Each entry gives a pattern of a file to be copied and a destination directory.
Can be redefined in subclasses.
-
additionalFilesToInstall_win32
-
application-specific files to be installed.
Each line defines an entry in the NSI file, for a pattern of a file to be copied.
Can be redefined in subclasses.
-
additionalResourceTargets
-
application-specific additional resource targets to be invoked.
Can be redefined in subclasses.
-
additionalTargetDirectoriesToMakeForInstall_osx
-
Each entry gives an additional target library to be created under the Contents/MacOS folder;
to get aadditional parent folder, pass in strings like '../Library/...'
-
applicationIconFileName
-
answer the base-name of the application icon (i.e. 'app' in <app>.ico).
Subclasses MUST redefine this to either return the name of the icon file or
nil, if they do not have one.
We NO LONGER SUPPORT THE PREVIOUS APPNAME-DEFAULT,
because users tend to forget to add the icon file and then get a failing build.
** This method must be redefined in concrete classes (subclassResponsibility) **
-
applicationInstallIconFileName
-
answer the base-name of the installer icon (i.e. 'app' in <app>.ico).
Default is the same as the application icon
-
applicationName
-
answer the name of the application.
This is also the name of the generated .exe file.
Subclasses may redefine this
Usage example(s):
bosch_dapasx_application applicationName
stx_projects_smalltalk applicationName
|
-
documentExtensions
-
list extensions which should be registered with the application.
Results in the application to be started when double-clicking on such a file (win32)
-
includedInPreRequisites
-
list packages which are to be implicitely included in the prerequisites list,
even if not found by the automatic search.
Redefine this, if classes from other packages are referred to via reflection
or by constructing names dynamically (i.e. the search cannot find it)
-
initiallyLoadedPreRequisites
-
Prerequisites packages that are to be loaded early by the VM,
not later by the application's startup.
This is used for a fast startup in case that the application wants to only inform
an already running application to e.g. open an additional window.
It defines the minimum set of required classes needed for this notification to work.
(a hack, for windows, where expecco if started a second time should inform the first
one to open an additional window)
-
isGUIApplication
-
Return true, if this is a GUI app.
Redefine to return false for non-GUI applications (affects inclusion of Display classes).
-
isSingleThreadedApplication
-
Return true, if this should be started without multiple threads.
(not possible with gui applications)
-
logFilenameNoConsole
-
^ (self applicationNameNoConsole , '_%d.log')
-
mainDefines
-
-
makeConsoleApplication
-
Used with WIN32 only (i.e. affects bc.mak).
Return true, if this should be built as a console application.
Redefine to return true, if you want one always i.e. to generate both).
-
makeNonConsoleApplication
-
Used with WIN32 only (i.e. affects bc.mak).
Return true, if this should be built as a non-console application
-
offerApplicationSourceCode
-
Return true, if the source code of the application should be offered as install option
-
offerSmalltalkSourceCode
-
Return true, if the source code of the smalltalk base system should be offered as install option
-
osxDmgBackgroundImageFile
-
-
osxVolumeIconImageFileName
-
-
runAsAdmin
-
WINDOWS only! Optionally used by NSI installer.
defines a registry entry,
which sets RUNASADMIN file attribute to the noconsole application exe
-
startupClassName
-
return he name of the class which provides the entry point for the application;
a fully specified symbol or string.
** This method must be redefined in concrete classes (subclassResponsibility) **
-
startupSelector
-
The name of the entry point method (in startUpClass) used to start the application.
description - private
-
applicationNameConsole
-
only used for windows builds
-
applicationNameFromPackage
-
answer the name of the application.
This is also the name of the generated .exe file.
Subclasses may redefine this
Usage example(s):
stx_projects_smalltalk applicationNameFromPackage
exept_expecco_application applicationNameFromPackage
bosch_dapasx_application applicationNameFromPackage
alspa_batch_application applicationNameFromPackage
|
-
applicationNameNoConsole
-
only used for windows builds
-
applicationPackage
-
bosch_dapasx_application applicationPackage
stx_projects_smalltalk applicationPackage
alspa_batch_application applicationPackage
-
commonFilesToInstall_unix
-
files installed for applications.
Each entry gives a pattern of a file to be copied and a destination directory.
Do not redefine - see additionalFilesToInstall for a redefinable variant of this
-
commonFilesToInstall_win32
-
files installed for applications - used only for NSIS installer under WIN32.
Each line defines an entry in the NSI file, for a pattern of a file to be copied.
Do not redefine - see additionalFilesToInstall for a redefinable variant of this
-
docDirPath_unix
-
path relative to my dir to the documentation - or nil
-
docDirPath_win32
-
path relative to my dir to the documentation - or nil
description - project information
-
applicationType
-
-
description
-
Returns a description string which will appear in nt.def / bc.def
-
docDirPath
-
path relative to my dir to the documentation - or empty.
-
hasLicenceToAcceptDuringInstallation
-
-
productName
-
attention: this affects the name of the generated setup.exe,
which might affect the signature generation
file generation
-
basicFileNamesToGenerate
-
answer a dictionary (filename -> generator method) with all the build-support files,
that have to be generated for this package
-
generateFile: filename
-
for linux
-
generateFile: filename confirmMissingClasses: confirmBoolean
-
for linux
-
generate_modules_dot_c
-
bosch_dapasx_application generate_modules_dot_c
-
generate_modules_dot_stx
-
bosch_dapasx_application generate_modules_dot_stx
-
generate_osx_osascript
-
stx_clients_Clock_QlockTwoWatchApplication generate_osx_osascript
-
generate_osx_pkginfo
-
-
generate_packageName_dot_nsi
-
bosch_dapasx_application generate_packageName_dot_nsi
-
nsiFilename
-
(comment from inherited method)
only applications define it
file mappings
-
additionalFilesToInstall_dot_nsi: bindings
-
-
additionalSectionsDescriptions_dot_nsi
-
-
additionalSectionsDescriptions_dot_nsi: bindings
-
-
additionalSectionsInsertDescriptions_dot_nsi
-
-
additionalSectionsInsertDescriptions_dot_nsi: bindings
-
-
additionalSections_dot_nsi
-
-
additionalSections_dot_nsi: bindings
-
-
appSourcesLines_dot_nsi: bindings
-
-
autopackage_default_dot_apspec_mappings
-
applicationPackage
-
bc_dot_mak_mappings
-
windwos make is so stupid
-
bmake_dot_mak_mappings
-
-
buildDate_dot_h_mappings
-
-
commonFilesToInstall_dot_nsi: bindings
-
-
directoryUninstallLines_dot_nsi
-
%(DIRECTORY_UNINSTALL_LINES)
-
fileExtensionDefinitionLines_dot_nsi: bindings
-
-
fileExtensionUndefinitionLines_dot_nsi: bindings
-
-
make_dot_proto_mappings
-
applicationPackage
-
modules_dot_c_mappings
-
cvut_fel_izar modules_dot_c_mappings
-
modules_dot_stx_mappings
-
-
nsiDeliveredConsoleExecutable
-
made anyway
-
nsiDeliveredExecutables
-
by default, an executable named after the application.
Redefine, if that's not the case. If multiple have to be delivered,
return a string containing each individually double-quoted.
-
osx_osascript_mappings
-
-
packageName_dot_nsi_mappings
-
d at: #'ICONDEFINITION_LINE' put: 'IDR_MAINFRAME ICON DISCARDABLE "',s,'"'
-
preRequisiteLine_bc_dot_mak_mappings: aProjectID
-
-
preRequisiteLine_bc_dot_mak_mappingsForClass: aClass
-
-
preRequisiteLine_make_dot_proto_mappings: aProjectID
-
-
preRequisiteLine_make_dot_proto_mappingsForClass: aClass
-
-
runAsAdminDefinitionLines_dot_nsi: bindings
-
-
runAsAdminUndefinitionLines_dot_nsi: bindings
-
-
stxSourcesLines_dot_nsi: bindings
-
-
subProjectLine_bc_dot_mak_mappings: aProjectID
-
-
subProjectLine_make_dot_proto_mappings: aProjectID
-
file mappings support
-
allPackagesForResources
-
-
generateAllPreRequisiteLibs_modules_dot_stx
-
exept_expecco_application generateAllPreRequisiteLibs_modules_dot_stx
-
generateExtensionLine: extensionLineTemplate
-
-
generatePreRequisiteLibs_modules_dot_stx
-
exept_expecco_application generatePreRequisiteLibs_modules_dot_stx
-
generatePreRequisiteLines_bc_dot_mak
-
bosch_dapasx_application generatePreRequisiteLines_bc_dot_mak
-
generatePreRequisiteLines_make_dot_proto
-
exept_expecco_application generatePreRequisiteLines_bc_dot_mak
-
generateRequiredLibobjs_make_dot_proto
-
exept_expecco_application generateRequiredLibobjs_make_dot_proto
-
generateRequiredLibs_bc_dot_mak
-
Subprojects are not linked to the exe!
Usage example(s):
bosch_dapasx_application generateRequiredLibs_bc_dot_mak
|
-
generateRequiredLibs_make_dot_proto
-
cg: why not (self libraryNameFor:projectID),'.so'; ???
Usage example(s):
alspa_batch_application generateRequiredLibs_make_dot_proto
|
-
generateRequiredLinkLibobjs_make_dot_proto
-
self subProjects do:[:projectID |
Usage example(s):
alspa_batch_application generateRequiredLinkLibobjs_make_dot_proto
|
-
generateResourceCopyLines_bc_mak
-
exept_expecco_application generateResourceCopyLines_make_dot_proto
exept_expecco_application allPreRequisitesSorted
exept_expecco_application allPackagesForResources
exept_expecco_application generateResourceCopyLines_bc_mak
-
generateResourceCopyLines_make_dot_proto
-
exept_expecco_application generateResourceCopyLines_make_dot_proto
exept_expecco_application allPreRequisitesSorted
exept_expecco_application allPackagesForResources
exept_expecco_application make_dot_proto_resource_rules
-
generateSubProjectLibs_bc_dot_mak
-
exept_expecco_application generateSubProjectLibs_bc_dot_mak
cg_newCompiler_driver_stc generateSubProjectLines_bc_dot_mak
-
generateSubProjectLibs_make_dot_proto
-
exept_expecco_application generateSubProjectLibs_make_dot_proto
self generateSubProjectLibs_make_dot_proto
-
generateSubProjectLines_bc_dot_mak
-
exept_expecco_application generateSubProjectLines_bc_dot_mak
bosch_dapasx_application generateSubProjectLines_bc_dot_mak
cg_newCompiler_driver_stc generateSubProjectLines_bc_dot_mak
-
generateSubProjectLines_make_dot_proto
-
exept_expecco_application generateSubProjectLines_make_dot_proto
cg_newCompiler_driver_stc generateSubProjectLines_make_dot_proto
-
generateSubProjectLines_modules_dot_stx
-
exept_expecco_application generateSubProjectLines_modules_dot_stx
cg_newCompiler_driver_stc generateSubProjectLines_modules_dot_stx
file templates
-
bc_dot_def
-
the template code for the bc.def file
-
bc_dot_mak
-
answer a template for the bc.mak makefile.
Any variable definition %(Variable) will be later replaced by the mapping.
$% characters have to be duplicated
-
bc_dot_mak_app_source_rules
-
-
bc_dot_mak_resource_rules
-
-
bc_dot_mak_stx_resource_rules
-
-
bc_dot_mak_stx_source_rules
-
-
bmake_dot_mak
-
the template code for the bmake.bat file
Notice: duplicate %'s if they are needed as such in the generated file
-
buildDate_dot_h
-
the template code for the buildDate.h file
-
classLine_modules_dot_c
-
-
classLine_modules_dot_c_extern
-
-
defineAPPSourceLine_nsi_for: projectID
-
-
defineExtenionLine_nsi_for: extension
-
the template code for a single extenions definition line in the <appname>.nsi file
-
defineExtensionLine_nsi_for: extension
-
the template code for a single extenions definition line in the <appname>.nsi file
-
defineSTXSourceLine_nsi_for: projectID
-
-
extensionsLine_modules_dot_c
-
-
extensionsLine_modules_dot_c_extern
-
-
installFileLine_nsi_for: filePattern
-
the template code for a single file-install pattern to be added to the <appname>.nsi file
-
linuxSetupRules
-
this is sliced into the generated Make.proto file
-
make_dot_proto
-
,' at ',Timestamp now printString
-
make_dot_proto_app_source_rules
-
-
make_dot_proto_app_source_rules_for: projectID
-
-
make_dot_proto_resource_rules
-
-
make_dot_proto_source_title_for: projectID
-
self packageNameFor: projectID.
Usage example(s):
self make_dot_proto_source_title_for: 'stx:libbasic'
|
-
make_dot_proto_stx_resource_rules
-
non-GUI app: only include libbasic resources (for Date)
-
make_dot_proto_stx_source_rules
-
-
make_dot_proto_stx_source_rules_for: projectID
-
-
modules_dot_c
-
-
modules_dot_stx
-
-
osxDmgImageSetupLines
-
generate (OSX unix) copy commands to generate a directory holding the dmg prototype image directory.
This is used to generate a macOS deployable dmg containing an app
-
osxPkgDistributionScript
-
unfinished.
generate (OSX unix) copy commands to generate a directory holding the pkg prototype image directory.
This is used to generate a macOS deployable pkg containing libraries or non-GUI programs
-
osxPkgImageSetupLines
-
generate (OSX unix) copy commands to generate a directory holding the pkg prototype image directory.
This is used to generate a macOS deployable pkg containing libraries or non-GUI programs
-
osxSetupRules
-
this is sliced into the generated Make.proto file
-
osxSetupRules_forDMG
-
this is sliced into the generated Make.proto file
-
osxSetupRules_forPKG
-
this is sliced into the generated Make.proto file
-
osx_osascript
-
generate (OSX unix) osa script commands to arrange the dmg folder being shown.
This is used to generate a macOS deployable dmg
-
packageName_dot_nsi
-
the template code for the <appname>.nsi file
Usage example(s):
bosch_dapasx_application packageName_dot_nsi
bosch_dapasx_application generateFile:'dapasx.nsi'
|
-
packageName_dot_rc
-
the template code for the <appname>.rc file
Usage example(s):
stx_libbasic3 packageName_dot_rc
stx_libbasic3 generate_packageName_dot_rc
|
-
preRequisiteLine_bc_dot_mak
-
Note: the trailing blank in 'CFLAGS_LOCAL=$(GLOBALDEFINES) '
is required!
-
preRequisiteLine_make_dot_proto
-
Note: the trailing blank in 'CFLAGS_LOCAL=$(GLOBALDEFINES) '
is required!
-
subProjectLine_bc_dot_mak
-
Note: the trailing blank in 'CFLAGS_LOCAL=$(GLOBALDEFINES) '
is required!
-
subProjectLine_make_dot_proto
-
Note: the trailing blank in 'CFLAGS_LOCAL=$(GLOBALDEFINES) '
is required!
-
undefineExtenionLine_nsi_for: extension
-
the template code for a single extenions undefinition line in the <appname>.nsi file
-
undefineExtensionLine_nsi_for: extension
-
the template code for a single extenions undefinition line in the <appname>.nsi file
queries
-
definitionClassOfApplicationBundle
-
Return the applicationDefinition of the applicationBundle or nil.
This is the applicationDefinition of the package which gets actually deployed.
This information is currently used for automatic check of language translations.
Here, ssume that I am the bundle.
Redefine in other applications if that is not true.
Usage example(s):
exept_expecco definitionClassOfApplicationBundle
exept_expecco_application definitionClassOfApplicationBundle
exept_expecco_plugin_swt definitionClassOfApplicationBundle
|
-
isAbstract
-
Return if this class is an abstract class.
True is returned here for myself only; false for subclasses.
Abstract subclasses must redefine this again.
-
projectType
-
-
shouldBeLoadedInitially: aProjectID
-
answer true, if a class should be loaded early by the VM,
and NOT later by the application (will be markd with a '*' in modules.stx)
sanity checks
-
validateDescription
-
perform some consistency checks (set of classes in project same as those listed in description);
called before checking in build support files
testing
-
isApplicationDefinition
-
(comment from inherited method)
true iff an application-package (i.e. not a library).
Applications have a main and startup for standalon start
-
isConsoleApplication
-
Used with WIN32 only (i.e. affects bc.mak).
Return true, if this is a console application.
Console applications have stdout and stderr and open up a command-window
when started. Only console applications can interact with the user in the
command line window.
By default, GUI apps are compiled as non-console apps.
If you need both (as in expecco), redefine this as true AND in addition redefine
makeConsoleApplication to return true.
|