mac os x installer: support using full fpc version in installer file names

git-svn-id: trunk@15442 -
This commit is contained in:
vincents 2008-06-16 21:08:24 +00:00
parent ebdec7f951
commit 1d22108b2f
4 changed files with 19 additions and 15 deletions

View File

@ -989,19 +989,19 @@ For more information, see the readme.txt file or visit http://www.freepascal.org
<key>IFPkgDescriptionTitle</key>
<string>Free Pascal Compiler</string>
<key>IFPkgDescriptionVersion</key>
<string>_FPCVERSION_</string>
<string>_FPCFULLVERSION_</string>
</dict>
</dict>
<key>Display Information</key>
<dict>
<key>CFBundleGetInfoString</key>
<string>Free Pascal Compiler _FPCVERSION_</string>
<string>Free Pascal Compiler _FPCFULLVERSION_</string>
<key>CFBundleIdentifier</key>
<string>org.freepascal.fpc</string>
<key>CFBundleName</key>
<string>Free Pascal Compiler</string>
<key>CFBundleShortVersionString</key>
<string>_FPCVERSION_</string>
<string>_FPCFULLVERSION_</string>
</dict>
<key>Options</key>
<dict>
@ -1038,7 +1038,7 @@ For more information, see the readme.txt file or visit http://www.freepascal.org
<key>IFPkgFlagPackageSelection</key>
<integer>0</integer>
<key>Name</key>
<string>fpc-_FPCVERSION_-_DATESTAMP_-_FPCARCH_</string>
<string>fpc-_FPCFULLVERSION_-_DATESTAMP_-_FPCARCH_</string>
<key>Status</key>
<integer>1</integer>
<key>Type</key>

View File

@ -466,19 +466,19 @@
<key>IFPkgDescriptionTitle</key>
<string>Free Pascal Sources</string>
<key>IFPkgDescriptionVersion</key>
<string>_FPCVERSION_</string>
<string>_FPCFULLVERSION_</string>
</dict>
</dict>
<key>Display Information</key>
<dict>
<key>CFBundleGetInfoString</key>
<string>Free Pascal Sources _FPCVERSION_</string>
<string>Free Pascal Sources _FPCFULLVERSION_</string>
<key>CFBundleIdentifier</key>
<string>org.freepascal.fpc.source</string>
<key>CFBundleName</key>
<string>Free Pascal Sources</string>
<key>CFBundleShortVersionString</key>
<string>_FPCVERSION_</string>
<string>_FPCFULLVERSION_</string>
</dict>
<key>Options</key>
<dict>
@ -515,7 +515,7 @@
<key>IFPkgFlagPackageSelection</key>
<integer>0</integer>
<key>Name</key>
<string>fpcsrc-_FPCVERSION_-_DATESTAMP_</string>
<string>fpcsrc-_FPCFULLVERSION_-_DATESTAMP_</string>
<key>Status</key>
<integer>1</integer>
<key>Type</key>

View File

@ -83,6 +83,7 @@ make build PP=$PPC_RELEASE DATA2INC=$FPCBUILDDIR/fpcsrc/utils/data2inc
COMPILER=$FPCBUILDDIR/fpcsrc/compiler/$PPCARCH
FPCVERSION=`$COMPILER -iV`
FPCFULLVERSION=`$COMPILER -iW`
FPCARCH=`$COMPILER -iSP`
# clean installdir: since I am not root and the install dir can contain files owned by root
@ -131,7 +132,8 @@ IFS=.
FPCMAJORVERSION=`set $FPCVERSION; echo $1`
FPCMINORVERSION=`set $FPCVERSION; echo $2$3`
IFS=$OLDIFS
sed -e "s|_PPCARCH_|$PPCARCH|g" -e "s|_FPCSRCDIR_|$FPCSVNDIR|g" -e "s|_FPCVERSION_|$FPCVERSION|g" \
sed -e "s|_PPCARCH_|$PPCARCH|g" -e "s|_FPCSRCDIR_|$FPCSVNDIR|g" \
-e "s|_FPCVERSION_|$FPCVERSION|g" -e "s|_FPCFULLVERSION_|$FPCFULLVERSION|g" \
-e "s|_DATESTAMP_|$DATESTAMP|g" -e s/_FPCMAJORVERSION_/$FPCMAJORVERSION/g \
-e "s/_FPCMINORVERSION_/$FPCMINORVERSION/g" -e "s/_FPCARCH_/$FPCARCH/g" \
$TEMPLATEDIR/$FPCPACKPROJ.template > $INSTALLDIR/$FPCPACKPROJ
@ -139,12 +141,12 @@ sed -e "s|_PPCARCH_|$PPCARCH|g" -e "s|_FPCSRCDIR_|$FPCSVNDIR|g" -e "s|_FPCVERSIO
# build package
$FREEZE -v $INSTALLDIR/$FPCPACKPROJ
DMGFILE=~/pkg/fpc-$FPCVERSION-$DATESTAMP-$FPCARCH-macosx.dmg
DMGFILE=~/pkg/fpc-$FPCFULLVERSION-$DATESTAMP-$FPCARCH-macosx.dmg
rm -rf $DMGFILE
$HDIUTIL create -anyowners -volname fpc-$FPCVERSION -imagekey zlib-level=9 -format UDZO -srcfolder $INSTALLDIR/build $DMGFILE
if [ -e $DMGFILE ]; then
#update lazarus snapshot web page
echo "$DMGFILE fpc-$FPCVERSION-*-$FPCARCH-macosx.dmg" >> $UPDATELIST
echo "$DMGFILE fpc-$FPCFULLVERSION-*-$FPCARCH-macosx.dmg" >> $UPDATELIST
fi

View File

@ -69,25 +69,27 @@ $SVN export $FPCSOURCEDIR/packages $INSTALLDIR/fpcsrc/packages
# fill in packproj template.
FPCVERSION=`$COMPILER -iV`
FPCFULLVERSION=`$COMPILER -iW`
FPCARCH=`$COMPILER -iSP`
OLDIFS=$IFS
IFS=.
FPCMAJORVERSION=`set $FPCVERSION; echo $1`
FPCMINORVERSION=`set $FPCVERSION; echo $2$3`
IFS=$OLDIFS
sed -e "s|_FPCSRCDIR_|$FPCSVNDIR|g" -e "s|_FPCVERSION_|$FPCVERSION|g" \
-e "s|_DATESTAMP_|$DATESTAMP|g" -e s/_FPCMAJORVERSION_/$FPCMAJORVERSION/g -e s/_FPCMINORVERSION_/$FPCMINORVERSION/g \
sed -e "s|_FPCSRCDIR_|$FPCSVNDIR|g" -e "s|_DATESTAMP_|$DATESTAMP|g" \
-e "s|_FPCVERSION_|$FPCVERSION|g" -e "s|_FPCFULLVERSION_|$FPCFULLVERSION|g" \
-e s/_FPCMAJORVERSION_/$FPCMAJORVERSION/g -e s/_FPCMINORVERSION_/$FPCMINORVERSION/g \
$TEMPLATEDIR/$PACKPROJ > $INSTALLDIR/$PACKPROJ
# build package
$FREEZE -v $INSTALLDIR/$PACKPROJ
DMGFILE=~/pkg/fpcsrc-$FPCVERSION-$DATESTAMP-$FPCARCH-macosx.dmg
DMGFILE=~/pkg/fpcsrc-$FPCFULLVERSION-$DATESTAMP-$FPCARCH-macosx.dmg
rm -rf $DMGFILE
$HDIUTIL create -anyowners -volname fpcsrc-$FPCVERSION -imagekey zlib-level=9 -format UDZO -srcfolder $INSTALLDIR/build $DMGFILE
if [ -e $DMGFILE ]; then
#update lazarus snapshot web page
echo "$DMGFILE fpcsrc-$FPCVERSION-*-$FPCARCH-macosx.dmg" >> $UPDATELIST
echo "$DMGFILE fpcsrc-$FPCFULLVERSION-*-$FPCARCH-macosx.dmg" >> $UPDATELIST
fi