[vlc-commits] configure: Require URL when using Breakpad, disable by default
Marvin Scholz
git at videolan.org
Mon Nov 6 17:57:19 CET 2017
vlc | branch: master | Marvin Scholz <epirat07 at gmail.com> | Thu Oct 5 11:33:27 2017 +0200| [10bad27b685203f9e7a4a6054a975125cb08a72f] | committer: Marvin Scholz
configure: Require URL when using Breakpad, disable by default
Change the `--enable-breakpad` flag to `--with-breakpad=URL`, that
means in order to enable the Breakpad crash reporter, the CrashDragon
server url needs to be given to that argument.
URL should be the base URL of the crash server, without a trailing `/`.
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=10bad27b685203f9e7a4a6054a975125cb08a72f
---
configure.ac | 34 ++++++++++++++++++++++++----------
share/Info.plist.in | 2 +-
2 files changed, 25 insertions(+), 11 deletions(-)
diff --git a/configure.ac b/configure.ac
index 7e4e90bb14..579ed76dab 100644
--- a/configure.ac
+++ b/configure.ac
@@ -3803,19 +3803,33 @@ AM_CONDITIONAL(HAVE_SPARKLE, [test "$enable_sparkle" != "no"])
dnl
dnl MacOS X breakpad creash reporter support
dnl
-AC_ARG_ENABLE(breakpad,
- [ --enable-breakpad Breakpad crash reporter support for OS X (default enabled on Mac OS X)])
-if test "x${enable_breakpad}" != "xno" -a "${HAVE_OSX}" = "1"
-then
- if test ! -d ${CONTRIB_DIR}/Breakpad.framework -a ! -d ${CONTRIB_DIR}/Frameworks/Breakpad.framework
- then
+AC_ARG_WITH([breakpad],
+ AS_HELP_STRING([--with-breakpad=URL], [Enable Breakpad reporter using given URL]), [], [with_breakpad=no])
+
+AS_IF([test "$with_breakpad" != "no"], [
+
+ AS_IF([test "$with_breakpad" = "yes"], [
+ AC_MSG_ERROR([You need to supply the CrashDragon Server URL as value for --with-breakpad])
+ ])
+
+ AS_IF([test "$HAVE_OSX" != "1"], [
+ AC_MSG_ERROR([Breakpad currently only works on macOS])
+ ])
+
+ AC_MSG_CHECKING([for Breakpad framework])
+ AS_IF([test ! -d ${CONTRIB_DIR}/Breakpad.framework -a \
+ ! -d ${CONTRIB_DIR}/Frameworks/Breakpad.framework], [
+ AC_MSG_RESULT([no])
AC_MSG_ERROR([Breakpad framework is required and was not found in ${CONTRIB_DIR}])
- fi
+ ], [
+ AC_MSG_RESULT([yes])
+ AC_DEFINE([HAVE_BREAKPAD], [1], [Define to 1 if breakpad is enabled.])
+ AC_SUBST(BREAKPAD_URL, ["${with_breakpad}"])
+ ])
- AC_DEFINE([HAVE_BREAKPAD], [1], [Define to 1 if breakpad is enabled.])
-fi
-AM_CONDITIONAL(HAVE_BREAKPAD, [test "$enable_breakpad" != "no"])
+])
+AM_CONDITIONAL(HAVE_BREAKPAD, [test "$with_breakpad" != "no"])
dnl
dnl Minimal Mac OS X module
diff --git a/share/Info.plist.in b/share/Info.plist.in
index c957254d94..53d6c46f65 100644
--- a/share/Info.plist.in
+++ b/share/Info.plist.in
@@ -1395,7 +1395,7 @@
<key>BreakpadRequestComments</key>
<string>1</string>
<key>BreakpadURL</key>
- <string>https://crashes.videolan.org/crashreports</string>
+ <string>@BREAKPAD_URL@/crashreports</string>
<key>CFBundleURLTypes</key>
<array>
<dict>
More information about the vlc-commits
mailing list