Issue #1342 - Remove support for system libevent

This commit is contained in:
wolfbeast 2020-01-23 13:08:02 +01:00 committed by Roy Tam
commit 25ae10aaec
8 changed files with 4 additions and 55 deletions

View file

@ -33,7 +33,6 @@ if ('MOZ_OFFICIAL_BRANDING' in listConfig) or (strBrandingDirectory.endswith("br
# Applies to Pale Moon and Basilisk
if ('MC_BASILISK' in listConfig) or ('MC_PALEMOON' in listConfig):
listViolations += [
'MOZ_SYSTEM_LIBEVENT',
'MOZ_SYSTEM_NSS',
'MOZ_SYSTEM_NSPR',
'MOZ_SYSTEM_JPEG',

View file

@ -46,7 +46,6 @@ export:: $(export-preqs)
-DMOZ_SYSTEM_ZLIB=$(MOZ_SYSTEM_ZLIB) \
-DMOZ_SYSTEM_PNG=$(MOZ_SYSTEM_PNG) \
-DMOZ_SYSTEM_JPEG=$(MOZ_SYSTEM_JPEG) \
-DMOZ_SYSTEM_LIBEVENT=$(MOZ_SYSTEM_LIBEVENT) \
-DMOZ_SYSTEM_LIBVPX=$(MOZ_SYSTEM_LIBVPX) \
-DMOZ_SYSTEM_ICU=$(MOZ_SYSTEM_ICU) \
$(srcdir)/system-headers $(srcdir)/stl-headers | $(PERL) $(topsrcdir)/nsprpub/config/make-system-wrappers.pl system_wrappers

View file

@ -1276,11 +1276,7 @@ bzlib.h
#ifdef MOZ_ENABLE_GIO
gio/gio.h
#endif
#if MOZ_SYSTEM_LIBEVENT==1
event.h
#else
sys/event.h
#endif
#ifdef MOZ_ENABLE_LIBPROXY
proxy.h
#endif

View file

@ -58,7 +58,7 @@ if os_win:
'src/chrome/common/process_watcher_win.cc',
'src/chrome/common/transport_dib_win.cc',
]
elif not CONFIG['MOZ_SYSTEM_LIBEVENT']:
else:
DIRS += ['src/third_party']
if os_posix:
@ -143,9 +143,9 @@ if os_solaris:
'src/base/atomicops_internals_x86_gcc.cc',
'src/base/process_util_linux.cc',
'src/base/time_posix.cc',
]
]
elif not CONFIG['MOZ_SYSTEM_LIBEVENT']:
else:
LOCAL_INCLUDES += ['src/third_party/libevent/linux']
ost = CONFIG['OS_TEST']

View file

@ -32,7 +32,7 @@ else:
else:
libevent_include_suffix = 'linux'
if os_posix and not CONFIG['MOZ_SYSTEM_LIBEVENT']:
if os_posix:
DEFINES['HAVE_CONFIG_H'] = True
LOCAL_INCLUDES += sorted([
'libevent',

View file

@ -10,9 +10,6 @@ include(libevent_path_prefix + '/libeventcommon.mozbuild')
if os_win:
error('should not reach here on Windows')
if CONFIG['MOZ_SYSTEM_LIBEVENT']:
error('should not reach here if we are using a native libevent')
UNIFIED_SOURCES += [
'libevent/buffer.c',
'libevent/bufferevent.c',

View file

@ -2014,44 +2014,6 @@ esac
MOZ_CONFIG_NSPR()
dnl ========================================================
dnl system libevent Support
dnl ========================================================
MOZ_ARG_WITH_STRING(system-libevent,
[ --with-system-libevent[=PFX]
Use system libevent [installed at prefix PFX]],
LIBEVENT_DIR=$withval)
_SAVE_CFLAGS=$CFLAGS
_SAVE_LDFLAGS=$LDFLAGS
_SAVE_LIBS=$LIBS
if test "$LIBEVENT_DIR" = yes; then
PKG_CHECK_MODULES(MOZ_LIBEVENT, libevent,
MOZ_SYSTEM_LIBEVENT=1,
LIBEVENT_DIR=/usr)
fi
if test -z "$LIBEVENT_DIR" -o "$LIBEVENT_DIR" = no; then
MOZ_SYSTEM_LIBEVENT=
elif test -z "$MOZ_SYSTEM_LIBEVENT"; then
CFLAGS="-I${LIBEVENT_DIR}/include $CFLAGS"
LDFLAGS="-L${LIBEVENT_DIR}/lib $LDFLAGS"
MOZ_CHECK_HEADER(event.h,
[if test ! -f "${LIBEVENT_DIR}/include/event.h"; then
AC_MSG_ERROR([event.h found, but is not in ${LIBEVENT_DIR}/include])
fi],
AC_MSG_ERROR([--with-system-libevent requested but event.h not found]))
AC_CHECK_LIB(event, event_init,
[MOZ_SYSTEM_LIBEVENT=1
MOZ_LIBEVENT_CFLAGS="-I${LIBEVENT_DIR}/include"
MOZ_LIBEVENT_LIBS="-L${LIBEVENT_DIR}/lib -levent"],
[MOZ_SYSTEM_LIBEVENT= MOZ_LIBEVENT_CFLAGS= MOZ_LIBEVENT_LIBS=])
fi
CFLAGS=$_SAVE_CFLAGS
LDFLAGS=$_SAVE_LDFLAGS
LIBS=$_SAVE_LIBS
AC_SUBST(MOZ_SYSTEM_LIBEVENT)
dnl ========================================================
dnl = If NSS was not detected in the system,
dnl = use the one in the source tree (mozilla/security/nss)
@ -5710,7 +5672,6 @@ MC_BASILISK=$MC_BASILISK
MC_PALEMOON=$MC_PALEMOON
MOZ_EME=$MOZ_EME
MOZ_WEBRTC=$MOZ_WEBRTC
MOZ_SYSTEM_LIBEVENT=$MOZ_SYSTEM_LIBEVENT
MOZ_SYSTEM_NSS=$MOZ_SYSTEM_NSS
MOZ_SYSTEM_NSPR=$MOZ_SYSTEM_NSPR
MOZ_SYSTEM_JPEG=$MOZ_SYSTEM_JPEG

View file

@ -201,9 +201,6 @@ if CONFIG['MOZ_SYSTEM_PNG']:
if CONFIG['MOZ_SYSTEM_HUNSPELL']:
OS_LIBS += CONFIG['MOZ_HUNSPELL_LIBS']
if CONFIG['MOZ_SYSTEM_LIBEVENT']:
OS_LIBS += CONFIG['MOZ_LIBEVENT_LIBS']
if CONFIG['MOZ_SYSTEM_LIBVPX']:
OS_LIBS += CONFIG['MOZ_LIBVPX_LIBS']