[vlc-commits] contribs: Growl: Ignore partial availability warnings

David Fuhrmann git at videolan.org
Sat Mar 3 09:39:39 CET 2018


vlc | branch: master | David Fuhrmann <dfuhrmann at videolan.org> | Sat Mar  3 09:34:11 2018 +0100| [0bf2ee7a400eb87c58968da449338ed022f99bba] | committer: David Fuhrmann

contribs: Growl: Ignore partial availability warnings

Fixes compilation, as growl sets older deployment target internally.
Also fix install rule for framework.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=0bf2ee7a400eb87c58968da449338ed022f99bba
---

 contrib/src/growl/growl-partial-availability.diff | 59 +++++++++++++++++++++++
 contrib/src/growl/rules.mak                       |  4 +-
 2 files changed, 62 insertions(+), 1 deletion(-)

diff --git a/contrib/src/growl/growl-partial-availability.diff b/contrib/src/growl/growl-partial-availability.diff
new file mode 100644
index 0000000000..09e5672a30
--- /dev/null
+++ b/contrib/src/growl/growl-partial-availability.diff
@@ -0,0 +1,59 @@
+--- growl/Framework/Source/GrowlApplicationBridge.m	2018-03-03 09:23:45.000000000 +0100
++++ growl_new/Framework/Source/GrowlApplicationBridge.m	2018-03-03 09:21:46.000000000 +0100
+@@ -133,6 +133,8 @@
+ 
+ #pragma mark -
+ 
++#pragma clang diagnostic push
++#pragma clang diagnostic ignored "-Wpartial-availability"
+ #if defined(MAC_OS_X_VERSION_10_8) && MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_8
+ 
+ // Obnoxiously, the Mountain Lion notification center requires an
+@@ -254,6 +256,7 @@
+ 
+ @end
+ 
++#pragma clang diagnostic pop
+ #endif // MAC_OS_X_VERSION_10_8
+ 
+ #pragma mark -
+@@ -660,6 +663,8 @@
+ 
+ + (void) _fireAppleNotificationCenter:(NSDictionary *)growlDict
+ {
++#pragma clang diagnostic push
++#pragma clang diagnostic ignored "-Wpartial-availability"
+ #if defined(MAC_OS_X_VERSION_10_8) && MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_8
+    BOOL defaultOnly = YES;
+    if([[NSUserDefaults standardUserDefaults] valueForKey:GROWL_FRAMEWORK_NOTIFICATIONCENTER_DEFAULT_ONLY])
+@@ -692,6 +697,7 @@
+    [[NSUserNotificationCenter defaultUserNotificationCenter] deliverNotification:appleNotification];
+    [appleNotification release];
+ #endif
++#pragma clang diagnostic pop
+ }
+ 
+ #pragma mark -
+diff -ru growl/Framework/Source/Mist/GrowlMistView.m growl_new/Framework/Source/Mist/GrowlMistView.m
+--- growl/Framework/Source/Mist/GrowlMistView.m	2012-12-12 07:18:11.000000000 +0100
++++ growl_new/Framework/Source/Mist/GrowlMistView.m	2018-03-03 09:26:16.000000000 +0100
+@@ -122,7 +122,10 @@
+ 		[strokePath setLineWidth:3.0f];
+ 		[strokePath stroke];
+ 	}
+-	
++
++    // drawInRect: is reimplemented in category
++#pragma clang diagnostic push
++#pragma clang diagnostic ignored "-Wpartial-availability"
+ 	// Draw image.
+ 	NSRect imageRect = NSZeroRect;
+ 	if (notificationImage) {
+@@ -131,6 +134,7 @@
+ 		imageRect.origin.y = self.bounds.origin.y + MIST_PADDING;
+ 		[notificationImage drawInRect:imageRect];
+ 	}
++#pragma clang diagnostic pop
+ 	
+ 	// Draw title.
+ 	NSRect titleRect = NSZeroRect;
diff --git a/contrib/src/growl/rules.mak b/contrib/src/growl/rules.mak
index f2da07a06f..2685041621 100644
--- a/contrib/src/growl/rules.mak
+++ b/contrib/src/growl/rules.mak
@@ -17,10 +17,12 @@ growl: GrowlSDK-$(GROWL_VERSION)-src.tar.gz .sum-growl
 	$(APPLY) $(SRC)/growl/fix-function-check.patch
 	$(APPLY) $(SRC)/growl/security-nothanks.patch
 	$(APPLY) $(SRC)/growl/growl-log-delegate.patch
+	$(APPLY) $(SRC)/growl/growl-partial-availability.diff
 	$(MOVE)
 
 .growl: growl
 	cd $< && xcodebuild $(XCODE_FLAGS) MACOSX_DEPLOYMENT_TARGET=10.7 CODE_SIGNING_REQUIRED=NO CODE_SIGN_IDENTITY="" GCC_TREAT_WARNINGS_AS_ERRORS=NO -target Growl.framework -configuration Release
 	install -d $(PREFIX)
-	cd $< && mkdir -p "$(PREFIX)/Frameworks" && cp -Rf build/Release/Growl.framework "$(PREFIX)/Frameworks"
+	cd $< && mkdir -p "$(PREFIX)/Frameworks" && rm -Rf $(PREFIX)/Frameworks/Growl.framework && \
+	         cp -Rf build/Release/Growl.framework "$(PREFIX)/Frameworks"
 	touch $@



More information about the vlc-commits mailing list