ProjectDefinition.st
branchjv
changeset 21026 81e280fc1b93
parent 21024 8734987eb5c7
parent 20986 3758c77e6af0
child 21242 19fabe339f8b
equal deleted inserted replaced
21025:442ca2ef6f76 21026:81e280fc1b93
     1 "{ Encoding: utf8 }"
       
     2 
       
     3 "
     1 "
     4  COPYRIGHT (c) 2006 by eXept Software AG
     2  COPYRIGHT (c) 2006 by eXept Software AG
     5               All Rights Reserved
     3               All Rights Reserved
     6 
     4 
     7  This software is furnished under a license and may be used
     5  This software is furnished under a license and may be used
   158     It *is* supported by all SCMs based on new stx:libscm. More specifically, *it is supported* by
   156     It *is* supported by all SCMs based on new stx:libscm. More specifically, *it is supported* by
   159     Mercurial.
   157     Mercurial.
   160 
   158 
   161     ## Adding additional rules to generated makefiles
   159     ## Adding additional rules to generated makefiles
   162 
   160 
   163     There are two ways to add additional rules to generatec makefiles (Make.proto and bc.mak):
   161     There are two ways to add additional rules to generated makefiles (Make.proto and bc.mak):
   164       1) overriding #additionalRules_make_dot_proto and/or #additionalRules_bc_dot_mak
   162       1) overriding #additionalRules_make_dot_proto and/or #additionalRules_bc_dot_mak
   165       2) addng a method annotated by <file:target:> or <file:target:extends:> 
   163       2) adding a method annotated by <file:target:> or <file:target:extends:> 
   166 
   164 
   167     ### Overriding #additionalRules* methods
   165     ### Overriding #additionalRules* methods
   168 
   166 
   169     You may override #additionalRules_make_dot_proto and/or #additionalRules_bc_dot_mak and return
   167     You may override #additionalRules_make_dot_proto and/or #additionalRules_bc_dot_mak and return
   170     string containing the code of the rules. This string is inserted to the resulting makefile
   168     string containing the code of the rules. This string is inserted to the resulting makefile
  3080 legalCopyright
  3078 legalCopyright
  3081     "Returns a copyright string which will appear in <lib>.rc.
  3079     "Returns a copyright string which will appear in <lib>.rc.
  3082      Under win32, this is placed into the dll's file-info.
  3080      Under win32, this is placed into the dll's file-info.
  3083      Other systems may put it elsewhere, or ignore it."
  3081      Other systems may put it elsewhere, or ignore it."
  3084 
  3082 
  3085      |m|
  3083     |m thisYear template|
  3086      
  3084      
  3087      m := self module.
  3085     m := self module.
       
  3086     thisYear := Date today year.
       
  3087 
  3088     m = 'stx' ifTrue:[
  3088     m = 'stx' ifTrue:[
  3089         "hardwired-default"
  3089         "hardwired-default"
  3090         ^ 'Copyright Claus Gittinger 1988-%1\nCopyright eXept Software AG %1' bindWith:(Date today year)
  3090         template := 'Copyright Claus Gittinger %1\nCopyright eXept Software AG %1' 
  3091     ].
  3091     ] ifFalse:[
  3092     m = 'exept' ifTrue:[
  3092         m = 'exept' ifTrue:[
  3093         "hardwired-default"
  3093             "hardwired-default"
  3094         ^ 'Copyright eXept Software AG %1' bindWith:(Date today year)
  3094             template := 'Copyright eXept Software AG %1' 
  3095     ].
  3095         ] ifFalse:[
  3096 
  3096             template := 'My CopyRight or CopyLeft %1'
  3097     ^ 'My CopyRight or CopyLeft'
  3097         ].
  3098 
  3098     ].
  3099     "
  3099     ^ template bindWith:thisYear
  3100         self legalCopyright
  3100 
  3101     "
  3101     "
  3102 
  3102      self legalCopyright
  3103     "Modified: / 30-08-2006 / 18:53:36 / cg"
  3103     "
       
  3104 
       
  3105     "Modified (comment): / 18-11-2016 / 12:23:36 / cg"
  3104 !
  3106 !
  3105 
  3107 
  3106 majorVersionNr
  3108 majorVersionNr
  3107     "Returns a versionNumber which will appear in libName.rc"
  3109     "Returns a versionNumber which will appear in libName.rc"
  3108 
  3110 
  3211     m := self module.
  3213     m := self module.
  3212     m = 'stx' ifTrue:[
  3214     m = 'stx' ifTrue:[
  3213         ^ 'Smalltalk/X'
  3215         ^ 'Smalltalk/X'
  3214     ].
  3216     ].
  3215     m = 'exept' ifTrue:[
  3217     m = 'exept' ifTrue:[
  3216         ^ 'eXept addOns'
  3218         ^ 'eXept AddOns'
  3217     ].
  3219     ].
  3218 
  3220 
  3219     self isApplicationDefinition ifFalse:[
  3221     self isApplicationDefinition ifFalse:[
  3220         ^ 'LibraryName'
  3222         ^ 'LibraryName'
  3221     ].
  3223     ].
  3234             ^ nm copyButLast:'Start' size.
  3236             ^ nm copyButLast:'Start' size.
  3235         ].
  3237         ].
  3236         ^ nm
  3238         ^ nm
  3237     ].
  3239     ].
  3238 
  3240 
  3239     "Modified: / 08-11-2007 / 16:45:14 / cg"
  3241     "Modified: / 18-11-2016 / 11:44:03 / cg"
  3240 !
  3242 !
  3241 
  3243 
  3242 productNameAsValidFilename
  3244 productNameAsValidFilename
  3243     "Returns a filename generated from the product name.
  3245     "Returns a filename generated from the product name.
  3244      This will be the name of the deployable package (i.e. <fn>.dmg, <fn>Setup.exe, etc.)"
  3246      This will be the name of the deployable package (i.e. <fn>.dmg, <fn>Setup.exe, etc.)"