forked from osmocom/wireshark
NSIS, WiX: Handle the presence or absence of mmdbresolve.
Only install mmdbresolve if MAXMINDDB_FOUND is true. Fixup the Qt about box and WiX GTK defines while we're here. Change-Id: I7ac3c21ddb4aebc1dae1c3d8cfd2bcafc4139d2e Reviewed-on: https://code.wireshark.org/review/26299 Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot Reviewed-by: Gerald Combs <gerald@wireshark.org>
This commit is contained in:
parent
f0fb6ee50c
commit
e3c263c012
|
@ -23,14 +23,14 @@
|
|||
!endif
|
||||
!define PRODUCT_VERSION @PRODUCT_VERSION@
|
||||
|
||||
!define MMDBRESOLVE_EXE @MAXMINDDB_FOUND@
|
||||
|
||||
!define VCREDIST_EXE "@VCREDIST_EXE@"
|
||||
|
||||
!define USER_GUIDE_DIR "@USER_GUIDE_DIR@"
|
||||
|
||||
!define SMI_DIR "@SMI_DIR@"
|
||||
|
||||
# Qt
|
||||
!define QT_DIR "@QT_DIR@"
|
||||
|
||||
# GTK+
|
||||
!define GTK_DIR "@GTK_DIR@"
|
||||
|
|
|
@ -133,7 +133,6 @@ Push "dftest"
|
|||
Push "dumpcap"
|
||||
Push "editcap"
|
||||
Push "mergecap"
|
||||
Push "mmdbresolve"
|
||||
Push "randpktdump"
|
||||
Push "rawshark"
|
||||
Push "reordercap"
|
||||
|
@ -142,6 +141,10 @@ Push "text2pcap"
|
|||
Push "tshark"
|
||||
Push "udpdump"
|
||||
|
||||
!ifdef MMDBRESOLVE_EXE
|
||||
Push "mmdbresolve"
|
||||
!endif
|
||||
|
||||
Pop $EXECUTABLE
|
||||
${DoUntil} $EXECUTABLE == ${EXECUTABLE_MARKER}
|
||||
|
||||
|
|
|
@ -1117,6 +1117,7 @@ File "${STAGING_DIR}\rawshark.exe"
|
|||
File "${STAGING_DIR}\rawshark.html"
|
||||
SectionEnd
|
||||
|
||||
!ifdef MMDBRESOLVE_EXE
|
||||
Section /o "MMDBResolve" SecMMDBResolve
|
||||
;-------------------------------------------
|
||||
SetOutPath $INSTDIR
|
||||
|
@ -1124,6 +1125,7 @@ File "${STAGING_DIR}\mmdbresolve.html"
|
|||
SetOutPath $INSTDIR
|
||||
File "${STAGING_DIR}\mmdbresolve.exe"
|
||||
SectionEnd
|
||||
!endif
|
||||
|
||||
Section /o "Androiddump" SecAndroiddumpinfos
|
||||
;-------------------------------------------
|
||||
|
|
|
@ -300,11 +300,15 @@ endif()
|
|||
file(APPEND "${_gtk_dll_manifest_wix}" "\n</Wix>\n")
|
||||
|
||||
if(BUILD_wireshark_gtk AND GTK_FOUND)
|
||||
set(use_gtk "-dGTK_DIR")
|
||||
set(d_gtk_dir "-dGTK_DIR")
|
||||
endif()
|
||||
|
||||
if(SMI_DIR)
|
||||
set(use_smi "-dSMI_DIR")
|
||||
set(d_smi_dir "-dSMI_DIR")
|
||||
endif()
|
||||
|
||||
if (MAXMINDDB_FOUND)
|
||||
set(d_mmdbresolve_exe "-dMMDBRESOLVE_EXE")
|
||||
endif()
|
||||
|
||||
set(WIX_CANDLE_DEFINES
|
||||
|
@ -323,8 +327,9 @@ set(WIX_CANDLE_DEFINES
|
|||
-dSnmpMibDir=${ARCHIVE_OUTPUT_PATH}/${CMAKE_BUILD_TYPE}/snmp/mibs
|
||||
-dVCRedistVersion=${MSVC_CRT_VERSION}
|
||||
-dVCRedistDir=${MERGE_MODULE_DIR}
|
||||
${use_gtk}
|
||||
${use_smi}
|
||||
${d_gtk_dir}
|
||||
${d_smi_dir}
|
||||
${d_mmdbresolve_exe}
|
||||
-arch ${TARGET_MACHINE}
|
||||
-ext WixUIExtension
|
||||
-I${CMAKE_SOURCE_DIR}/packaging/wix
|
||||
|
|
|
@ -434,13 +434,14 @@
|
|||
</Fragment>
|
||||
|
||||
<!-- MMDBResolve -->
|
||||
<?ifdef MMDBRESOLVE_EXE?>
|
||||
<Fragment>
|
||||
<DirectoryRef Id="INSTALLFOLDER">
|
||||
<Component Id="cmpMmdbresolve_exe" Guid="*">
|
||||
<File Id="filMmdbresolve_exe" KeyPath="yes" Source="$(var.Staging.Dir)\mmdbresolve.exe" />
|
||||
</Component>
|
||||
<Component Id="cmpMmdbresolve_html" Guid="*">
|
||||
<File Id="filMmdbresolve_html" KeyPath="yes" Source="$(var.Staging.Dir)\rawshark.html" />
|
||||
<File Id="filMmdbresolve_html" KeyPath="yes" Source="$(var.Staging.Dir)\mmdbresolve.html" />
|
||||
</Component>
|
||||
</DirectoryRef>
|
||||
</Fragment>
|
||||
|
@ -450,6 +451,7 @@
|
|||
<ComponentRef Id="cmpMmdbresolve_html" />
|
||||
</ComponentGroup>
|
||||
</Fragment>
|
||||
<?endif?>
|
||||
|
||||
<!-- Androiddump -->
|
||||
<Fragment>
|
||||
|
|
|
@ -81,9 +81,11 @@
|
|||
<Feature Id="Fe.Tools.Rawshark" Title="Rawshark" Level="1" AllowAdvertise="yes" Display="expand" Description="Raw packet filter.">
|
||||
<ComponentGroupRef Id="CG.Tools.Rawshark" />
|
||||
</Feature>
|
||||
<?ifdef MMDBRESOLVE_EXE?>
|
||||
<Feature Id="Fe.Tools.MMDBResolve" Title="MMDBResolve" Level="1" AllowAdvertise="yes" Display="expand" Description="IP geolocation database resolution.">
|
||||
<ComponentGroupRef Id="CG.Tools.MMDBResolve" />
|
||||
</Feature>
|
||||
<?endif?>
|
||||
<Feature Id="Fe.Tools.Androiddump" Title="Androiddump" Level="2" AllowAdvertise="yes" Display="expand" Description="Provide capture interfaces from Android devices.">
|
||||
<ComponentGroupRef Id="CG.Tools.Androiddump" />
|
||||
</Feature>
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
<Condition Action="disable"><![CDATA[&Fe.Wireshark <> 3]]></Condition>
|
||||
</Control>
|
||||
|
||||
<?ifdef GTK_DIR?>
|
||||
<Control Id="WiresharkLegacyStartMenuCB" Type="CheckBox" X="20" Y="117" Width="180" Height="15" CheckBoxValue="1" Property="WIRESHARK_LEGACY_START_MENU" Text="Wireshark Legacy Start Menu Item">
|
||||
<Condition Action="enable"><![CDATA[&Fe.WiresharkGTK = 3]]></Condition>
|
||||
<Condition Action="disable"><![CDATA[&Fe.WiresharkGTK <> 3]]></Condition>
|
||||
|
@ -34,6 +35,7 @@
|
|||
<Condition Action="enable"><![CDATA[&Fe.WiresharkGTK = 3]]></Condition>
|
||||
<Condition Action="disable"><![CDATA[&Fe.WiresharkGTK <> 3]]></Condition>
|
||||
</Control>
|
||||
<?endif?>
|
||||
|
||||
<Control Id="FileExtensions" Type="GroupBox" X="15" Y="180" Width="250" Height="100" Text="File Extensions"/>
|
||||
<Control Id="FileExtensionsRadio" Type="RadioButtonGroup" X="20" Y="190" Width="235" Height="50" Property="WIRESHARK_FILE_EXTENSIONS">
|
||||
|
|
|
@ -21,9 +21,9 @@
|
|||
#ifdef HAVE_LIBSMI
|
||||
#include <epan/oids.h>
|
||||
#endif
|
||||
#ifdef HAVE_GEOIP
|
||||
#include <epan/geoip_db.h>
|
||||
#endif
|
||||
|
||||
#include <epan/maxmind_db.h>
|
||||
|
||||
#ifdef HAVE_LUA
|
||||
#include <epan/wslua/init_wslua.h>
|
||||
#endif
|
||||
|
@ -248,12 +248,10 @@ FolderListModel::FolderListModel(QObject * parent):
|
|||
foreach(QString path, extPaths)
|
||||
appendRow( QStringList() << tr("Extcap path") << path.trimmed() << tr("Extcap Plugins search path"));
|
||||
|
||||
#ifdef HAVE_GEOIP
|
||||
/* GeoIP */
|
||||
QStringList geoIpPaths = QString(geoip_db_get_paths()).split(G_SEARCHPATH_SEPARATOR_S);
|
||||
foreach(QString path, geoIpPaths)
|
||||
appendRow( QStringList() << tr("GeoIP path") << path.trimmed() << tr("GeoIP database search path"));
|
||||
#endif
|
||||
/* MaxMind DB */
|
||||
QStringList maxMindDbPaths = QString(maxmind_db_get_paths()).split(G_SEARCHPATH_SEPARATOR_S);
|
||||
foreach(QString path, maxMindDbPaths)
|
||||
appendRow( QStringList() << tr("MaxMind DB path") << path.trimmed() << tr("MaxMind DB database search path"));
|
||||
|
||||
#ifdef HAVE_LIBSMI
|
||||
/* SMI MIBs/PIBs */
|
||||
|
|
Loading…
Reference in New Issue