diff --git a/contrib/src/growl/rules.mak b/contrib/src/growl/rules.mak
index adaf514b739af93db39a82b8307a8b5b09288f3a..88ca6577a36486fce6bbfa4637f34d1472e3936f 100644
--- a/contrib/src/growl/rules.mak
+++ b/contrib/src/growl/rules.mak
@@ -15,9 +15,14 @@ $(TARBALLS)/growl-$(GROWL_VERSION).tar.bz2:
 growl: growl-$(GROWL_VERSION).tar.bz2 .sum-growl
 	$(UNPACK)
 	mv Growl-1.2.2-src $@
+	sed -i.orig -e s/"SDKROOT = macosx10.5"/"SDKROOT = macosx$(OSX_VERSION)"/g \
+		-e s/"GCC_VERSION = 4.0"/"GCC_VERSION = 4.2"/g \
+		-e s/com.apple.compilers.gcc.4_0/com.apple.compilers.gcc.4_2/g \
+		$@/Growl.xcodeproj/project.pbxproj
+	sed -i.orig -e s/"REVISION \$$REV"/"REVISION 0x\$$REV"/g $@/generateHgRevision.sh
 	touch $@
 
 .growl: growl
-	cd $< && xcodebuild -sdk /Developer/SDKs/MacOSX10.6.sdk -arch $(ARCH)
+	cd $< && xcodebuild -sdk /Developer/SDKs/MacOSX$(OSX_VERSION).sdk -arch $(ARCH)
 	cd $< && cp -R -L build/Release/Growl.framework "$(PREFIX)"
 	touch $@