2 # What to do before running this script:
3 # - openUp needs to be installed.
4 # - Set VERSION and BETA below
5 # - To enable beta, also edit Source/AIAdium.h, and set BETA_RELEASE to TRUE. Set it to FALSE when doing a final release.
6 # - Edit the following plist keys in Adium_2.plist
7 # - CFBundleGetInfoString
8 # - CFBundleShortVersionString
11 # How to run this script:
20 # First upload to cachefly. If you don't have access and need to do a release, get with Evan or Chris (tick).
21 # Triggering the version checker once the release is up:
23 # 2) Get the number out of the 'buildnum' file in Adium.app/Contents/Resources
24 # 3) Paste that number into the appropriate place (adium version or adium-beta version, depending on which you're triggering) in the version.plist file in our sf.net ht_docs folder. You should be able to ftp into shell.sf.net with your sf.net login/pass and then cd to the right directory (/home/groups/a/ad/adium/htdocs)
28 # No need for changes below this point
34 ADIUM_DIR
=$(BUILD_DIR
)/Adium
35 RELEASE_NAME
=AdiumX_
$(VERSION
)
37 BUILDSTYLE
=Deployment-Debug
41 BUILDFLAGS
="BUILDCONFIGURATION=$(BUILDSTYLE)"
42 PRODUCT_DIR
=$(shell defaults read com.apple.Xcode PBXProductDirectory
2> /dev
/null
)
43 ifeq ($(strip $(PRODUCT_DIR
)),)
44 ADIUM_BUILD_DIR
=$(SRC_DIR
)/build
/$(BUILDSTYLE
)
46 TARGET_BUILD_DIR
=$(PRODUCT_DIR
)/$(BUILDSTYLE
)
47 ADIUM_BUILD_DIR
=$(TARGET_BUILD_DIR
)
50 .PHONY
: all update compile
clean release source createfolder diskimage
52 all: update compile release
58 $(MAKE
) $(BUILDFLAGS
) -C
$(SRC_DIR
)
61 $(MAKE
) $(BUILDFLAGS
) -C
$(SRC_DIR
)
66 release
: createfolder diskimage
69 @
# clean build directory
76 cp
-R
$(ADIUM_BUILD_DIR
)/Adium.app
$(ADIUM_DIR
)
78 @
# copy the text files
79 cp
$(SRC_DIR
)/Changes.txt
$(ADIUM_DIR
)
80 cp
$(SRC_DIR
)/License.txt
$(ADIUM_DIR
)
82 @
# symlink /Applications
83 ln
-s
/Applications
$(ADIUM_DIR
)/Applications
85 @
# delete svn and backup files
86 find
$(BUILD_DIR
) -name
".svn" -type d
-exec
rm -rf
{} \
; -prune
87 find
$(BUILD_DIR
) \
( -name
"*~" -or
-name .DS_Store \
) -type f
-delete
89 @
# delete unneeded nib files for non-beta builds
91 find
$(BUILD_DIR
) \
( -name classes.nib
-or
-name
info.nib \
) -type f
-delete
95 rm "$(BUILD_DIR)/$(RELEASE_NAME).dmg" || true
96 @
# make Adium disk image
97 mkdir
-p
$(ADIUM_DIR
)/.background
98 cp
$(ART_DIR
)/dmgBackground.png
$(ADIUM_DIR
)/.background
100 .
/make-diskimage.sh
$(BUILD_DIR
)/$(RELEASE_NAME
).dmg
$(ADIUM_DIR
) "Adium X $(VERSION)" dmg_adium.scpt