Commit Graph

177 Commits

Author SHA1 Message Date
John Thacker dda2ead9c0 rpm: Update spec for latest dependencies
SpeexDSP is now required.
Update the required cmake and glib versions.
Our CMake build process now expects a C++ compiler to always be present,
so require it even if not building the GUI.

Only default to Qt 6 on distributions where we know we have it,
otherwise default to Qt 5 for now.

Update the required RPM version to 4.13 (which all distributions that
can currently build have) to ensure we have Boolean dependencies.
Use Boolean dependencies instead of checking the distribution, hopefully
to improve building on various other RPM-based distributions.

Redefine the cmake_install macro on SUSE to what is used on RH/Fedora.
The default SUSE macro calls the builder (make or ninja) insted of
cmake --install, which makes it difficult to pass options.

Remove tests and workarounds for RHEL 7, and SUSE < 15.2, since those
distributions are too old to build anyway.
Remove a workaround for an old broken librotli-devel package in
SUSE that's been long since fixed.
2023-01-21 23:49:35 -05:00
João Valverde ad8118b14a RPM: Try to fix build on openSUSE
SUSE defines %cmake_install as something other than cmake install.
2023-01-21 14:36:51 +00:00
João Valverde 5b57eb61f1 RPM: Fix breakage because of $docdir
%docdir only marks a directory as containing documentation.
It also needs to be included.
2023-01-21 00:05:20 +00:00
João Valverde 74909f1499 Install PDML files to DOCDIR
Add README because this stuff is somewhat obscure and move XSLT
file to DOCDIR because it is not used by wireshark directly.
2023-01-19 17:08:36 +00:00
João Valverde 06519be205 Install documentation (HTML manuals) to DOCDIR
Install documentation to DOCDIR instead of DATADIR.
The code must be fixed to open the Help URLs from
this new path.

This only affects Unix-like FHS platforms. Windows
installation does its own thing.

Needs testing with macOS packaging.
2023-01-19 01:40:59 +00:00
João Valverde 9c9c5343d8 RPM: Remove some unnecessary doc files
INSTALL and READMEs for all the different platforms are totally
unnecessary and arguably wrong. ChangeLog is not useful either IMO.
2023-01-19 00:27:50 +00:00
João Valverde 3335197b42 RPM: Fix header installation 2023-01-18 13:03:55 +00:00
Alexis Gryta 77a1cb0636 rpm packaging: Add .el7, .fc38, ... 2022-12-06 20:24:39 +00:00
João Valverde 94da25af6c RPM: Add support for Qt6 and Fedora Linux 2022-08-25 07:54:00 +00:00
João Valverde b33210750c CMake+etc: Enable Qt6 by default for Unix builds
Linux builds were left behind on the Qt transition, presumably because
our Ubuntu CI image does not support Qt6.

Enable Qt6 by default and explicitly disable it for slower or more
conservative Linux distros.

Drop experimental status for Qt6, because we are using it to build
official Windows and macOS releases.
2022-08-22 09:08:06 +00:00
John Thacker 32326b3a07 packaging: EPEL 8 has asciidoctor now
rubygems-asciidoctor was released 2022-05-18 for EPEL 8
( https://bugzilla.redhat.com/show_bug.cgi?id=1820896 )
so we don't need to special case it for RHEL/Centos 8.
2022-07-28 16:17:52 +00:00
John Thacker 1b62c53f56 packaging: Add Qt5Concurrent to SUSE BuildRequires
Qt5Concurrent is needed since 0438fca96b
Add it to the spec file requirements, since it's a separate package
on openSUSE.
2022-07-27 16:59:44 +00:00
John Thacker 081bc13eb8 rpm: Disable build terminating on double dash versions for all distros
RPM 4.11.2 introduced build failures on "wrong" version formatting,
including everything with a double dash. This broke a lot of
packages, so many distributions turned it off by default, but
some don't. Make sure it's off, because build from git versions
have dashes. Fixes the Rocky 9 CI build.

Note that we try to work around this by replacing the dashes in
our version number with underscores, but RPM will still complain
about an invalid version in the dependency it generates from our
pkg-config file.
2022-07-24 20:13:46 -04:00
Gerald Combs d1074274d1 More Perl cleanup.
Remove perl from INSTALL and our RPM spec.

[skip ci]
2022-07-24 11:05:44 -07:00
Gerald Combs c5e265f852 CMake: Deduplicate some version variables.
Use PROJECT_VERSION instead of VERSION. Prepend "PROJECT_" or
"LOG_PROJECT_" as needed to other variables. Remove the leftover unused
variables.
2022-06-07 16:04:17 -07:00
John Thacker 2b24b512ca rpm: Support for building with clang on Fedora
Fedora now supports rpm options to build with clang as the compiler
https://docs.fedoraproject.org/en-US/packaging-guidelines/#compiler
2022-04-25 08:52:23 -04:00
John Thacker 858a670d34 rpm: Specfile cleanup
Fix some deprecated and obsolete syntax from the rpm specfile that
modern distributions complain about:
Don't specify the BuildRoot
Don't have a %clean section
Don't remove the BuildRoot at the start of %install
Don't repeat Name in summary
Version the Obsoletes
Have a %build section
Escape macros in changelog
Remove comment about user setting _smp_mflags since rpm does that
automatically better now
Be consistent about spaces and tabs (tabs are used)
2022-04-25 06:53:05 -04:00
John Thacker 7ec3e841ba rpm: Fix SUSE 15.1 builddir issue on make
SUSE 15.1 moved to out of source builds, and sets a builddir
appropriately, but it makes some decisions about automatically
entering the build dir when building or installing that are
handled by the distribution's various Make and Ninja macros
differently than other distributions and later SUSE releases.
Work around it, so that both ninja and make builds work on
SUSE 15.1 (both OpenSUSE and SLES)

Related to #17910
2022-04-24 18:49:38 -04:00
John Thacker 0676ddfb4f rpm: Update glib and cmake BuildRequirements
Update glib and cmake requirements in the rpm spec, and also remove
some RHEL 7 conditions associated with them, since the versions of
glib and cmake in RHEL 7 are too old to be supported.
2022-04-23 20:48:16 -04:00
John Thacker 92c8c2f7a0 rpm: RHEL 8 update macros
RHEL 8 and derivatives have supported the various CMake macros since
8.4 (June 2021, see https://access.redhat.com/errata/RHEA-2021:1747)
Use them there as well, so that we have a unified spec file for all
recent distributions (with the older RHEL/CentOS 7 and SLES 12 being
the only exceptions.)
2022-01-17 17:10:50 +00:00
John Thacker 65e3c4fbe2 rpm: expand comment
Be a bit more precise about what's wrong with bindir on SUSE
(when prefix is /usr/local or anything else.)
2022-01-17 08:01:46 -05:00
John Thacker 1d0fb38d38 rpm: Fix up paths
Fedora and SUSE 15 use out of source builds by default, but store
the build directory in differently named macros. Define one macro
for the build directory that has the appropriate value (which will
be "." for any distribution that doesn't have either macro, and
thus presumably does in-source builds.) This fixes building and
installing the guides with any of the supported distributions.

Also, since RHEL/CentOS 7 doesn't have a special CMake macro, it
needs to set the install prefix when calling cmake.

Also, fix a comment warning by escaping the percent sign.
2022-01-17 00:56:16 -05:00
John Thacker 800524131f rpm packaging: Add build requirements for the guides
The HTML guides require xsltproc and the docbook xsl stylesheets
in order to be generated.
2022-01-16 08:19:10 +00:00
John Thacker 736441ccfa packaging: Add RPM build dependencies for ninja, asciidoctor
If we're building with ninja, we need to require it.

While CentOS/RHEL/Rocky 8 doesn't have a asciidoctor package
(so we install it separately), we can add a BuildRequires on
the file that RubyGems creates for other rpm based distributions.
2022-01-08 00:00:52 +00:00
John Thacker 7027242c27 packaging: Let SUSE build with /usr prefix
There's a couple places where /usr/local is hardcoded in the
spec file that need to be replaced with %{_prefix} in order for
RPMs to build correctly on OpenSUSE with prefixes other than
/usr/local
2022-01-07 14:40:58 +00:00
John Thacker 858402d3c7 packaging: Fix RPM -qt subpackage requires
The BuildRequires and Requires for the -qt subpackage need to
go into its %package section, not its %description section.
The dependencies were not being enforced, but instead being added
to the description of the GUI package.
2022-01-06 04:33:00 +00:00
John Thacker 4b5d54f5ea packaging: Bump RPM glib2 version to 2.38
We require glib2 version 2.38 now, increase the version requirement
in the RPM spec file to match.
2022-01-05 10:21:23 -05:00
John Thacker 2cb8f34721 packaging: Remove unnecessary Requires
Automatic dependency generation has been around since RPM 4.0 (September
2000). The BuildRequires are sufficient for all of these; the automatic
dependences for the .so files works and are superior as they are versioned.

Red Hat and SUSE both recommend using automatic dependencies and
avoiding unnecessary Requires in spec files:
https://docs.fedoraproject.org/en-US/packaging-guidelines/#_explicit_requires
https://en.opensuse.org/openSUSE:Package_dependencies
2022-01-05 09:53:17 -05:00
John Thacker 98378d76d0 packaging: ENABLE_RPATH_ORIGIN on Fedora RPM build
Fedora Linux recently turned on some hardcore RPATH hardening
that causes RPM build to fail with a wide variety of prefixes unless
$ORIGIN is enabled.

It builds fine with /usr as the prefix because in that case we disable
the RPATH.

In the long run perhaps we should have the rpm-package target use the
standard prefix of /usr instead of the CMAKE_INSTALL_PREFIX, but even
so we want the spec file to work if /usr/local is set as the prefix.
Fix #17830
2022-01-04 21:48:31 -05:00
João Valverde 119473eab3 CMake: Use more consistent naming for options
Having some options use DISABLE_ and others ENABLE_ is inconsistent
and difficult to remember. Use ENABLE_ instead consistently.

Frame-larger-than remains an exception.
2022-01-03 15:55:06 +00:00
Gerald Combs 7f47511653 Try to fix RPM packaging.
Asciidoctor is now required for packaging. Try to make sure it's
installed on CentOS 8 and openSUSE 15.2. Note that CentOS 8 doesn't have
an Asciidoctor package, which complicates our SPEC.
2021-10-01 18:26:24 +00:00
Gerald Combs 84ab55cf75 Docs+Packaging: Convert our man pages to Asciidoctor.
Convert doc/*.pod to Asciidoctor. This:

* Means we use the same markup for our man pages, the guides, and
  release notes.
* Lets us add versions to our man pages.
* Gives us more formatting options, e.g. AsciiDoc supports `commands`,
  nested lists and makes it easy to include version information. The
  manpage backend doesn't seem to support tables very well,
  unfortunately.

Convert our CMake configuration to produce *roff and html man pages
using Asciidoctor. Add a "manarg" block macro which makes our synopses
wrap correctly.

Similar to the release notes, guides, and FAQ, if Asciidoctor isn't
found the man pages won't be generated or installed.

Move Asciidoctor to the list of package build dependencies in various
places.

This commit includes the conversion script (pod2adoc.py), which will be
removed later.

Line count sanity check:

Man page         .pod .adoc
androiddump       260  280
asn2deb            93  105
capinfos          401  471
captype            54   55
ciscodump         241  269
dftest             42   42
dpauxmon          153  169
dumpcap           464  534
editcap           528  583
etwdump           136  156
extcap            157  181
idl2deb            91  103
idl2wrs           120  100
mergecap          206  207
mmdbresolve        75   75
randpkt           107  111
randpktdump       158  184
rawshark          558  610
reordercap         76   78
sdjournal         145  157
sshdump           272  302
text2pcap         274  312
tshark           2135 2360
udpdump           133  151
wireshark-filter  486  479
wireshark        2967 3420
2021-10-01 16:42:34 +00:00
João Valverde ffcfc83ecb Rename version.h to be more descriptive
Version.h is too generic. This is specific to VCSVERSION and that
should be made more obvious and discoverable.
2021-07-09 18:27:41 +00:00
João Valverde 5dd15cd56c RPM: Don't install HTML manuals twice
Fixes e4d4814168.
2021-03-30 03:00:17 +01:00
Gerald Combs 5848d8a6f2 RPM: Update the HTML documentation location. 2021-03-29 15:16:36 -07:00
João Valverde e4b5573ff5 RPM: Fix build using the Unix Makefiles generator 2021-03-06 12:25:14 +00:00
Dario Lombardo 6b0f2ead7a rpm: disable double dash check on fedora.
Standard naming convention in Wireshark generates a version that
make the rpm build fail on Fedora. Since we've not evidence that
this happens on other platforms, just disable on that one.
2021-01-07 19:03:36 +00:00
Gerald Combs 53775325df RPM: Try to fix openSUSE packaging.
Try to fix

    + /usr/lib/rpm/suse_update_desktop_file.sh wireshark
    ERROR: suse_update_desktop_file: unable to find wireshark
2020-12-12 21:16:55 +00:00
Peter Eszlari 001d0debdc rpm: rename metadata 2020-12-12 17:08:31 +00:00
Peter Eszlari 42a09ad02e Linux: rename metadata according to spec
https://www.freedesktop.org/software/appstream/docs/sect-Metadata-Application.html

https://specifications.freedesktop.org/desktop-entry-spec/latest/ar01s02.html#desktop-file-id
2020-12-10 18:11:12 +00:00
Gerald Combs f21cd2e23f wiretap: Convert ascend.y to Lemon.
Convert wiretap/ascend.y.in from Bison/YACC to Lemon and rename it to
wiretap/ascend_parser.lemon. Tighten up some of our scanning and
parsing. Make the indentation in it and related files consistent. Aside
from the recent IPv4 fragment offset changes, this produces identical
output to the 3.4 branch for the Ascend trace files I have here.

Remove the comment about supporting other commands. Another timeline
might have an Ascend that successfully pivoted to DSL or 15625B+1D
gigabit ISDN, but this one has neither.

This was our last/only Bison/YACC file, so remove Bison/YACC as a
development and packaging dependency and remove references to it from
the documentation.
2020-11-30 08:15:43 +00:00
John Thacker ac34f3e8b6 RPM+CI: Update and fix for Fedora 33, CentOS 8, OpenSUSE Leap 15.2
Re-enable Fedora build and add CentOS 8 and OpenSUSE 15.2 builds.
Fedora 33 does out of build tree cmake builds and needs spec file changes.
CentOS 8 has some changes with cmake and other packages that are similar to
older Fedora, and needs extra repositories enabled to get -devel packages
(still missing -devel for some optional libraries). OpenSUSE Leap 15.2 also
has some changes needed to build. Note that OpenSUSE Leap 15.1 is EOL
at the end of November 2020. Fixes #16971
2020-11-05 17:58:16 -05:00
Gerald Combs 05bd5cd91e CI+RPM: Disable the Fedora build for now.
Fedora 33's RPM environent added changes that break CMake. Disable it
for now.
2020-10-28 20:48:49 +00:00
Lin Sun 6136c719da RTP: opus playback
It's possible to play opus payload with libopus (https://opus-codec.org/).
Closes #16882.

Helped-by: Pascal Quantin <pascal.quantin@gmail.com>
Signed-off-by: Lin Sun <lin.sun@zoom.us>
Signed-off-by: Yuanzhi Li <ryanlee@mail.ustc.edu.cn>
2020-10-03 21:15:09 +00:00
Gerald Combs 937c7c512a Debian+RPM: Require QtSVG.
Although we don't depend on any of Qt's SVG classes directly, we do use
SVG icons in Preferences → Appearance → Language and QIcon loads its SVG
engine dynamically. If it's not present Wireshark will still run, but
the user won't see any flag icons.

Require QtSVG in the Debian and RPM packaging. It's not that large (~
400k here on Ubuntu 18.04) and ensures that we have a uniform user
experience across platforms. In this particular case, if the user
experience happens to be "Wireshark's UI is in a language I don't
understand" the little flags can come in handy.

Change-Id: If3c2e8a6040967353dbc462ee475ef12514b25f9
Reviewed-on: https://code.wireshark.org/review/36037
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2020-02-11 01:43:33 +00:00
Peter Wu b926d24b96 RPM: fix missing qt5-linguist dependency, simplify installed packages
Remove unnecessary Qt5SVG build dependency. Do not install Qt4 qt-devel.
qt5-qtbase-devel is big, try to avoid pulling unnecessary deps.

Change-Id: Id289bea10ea89de6b7a3ea77996d861ff7354560
Reviewed-on: https://code.wireshark.org/review/36058
Reviewed-by: Dario Lombardo <lomato@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2020-02-09 13:10:12 +00:00
Jirka Novak a47cf5f45d RPM: fixed log sequence
Change-Id: I0d244ff6950961219ea29f7b2c290c483e92bfd3
Reviewed-on: https://code.wireshark.org/review/35877
Petri-Dish: Pascal Quantin <pascal@wireshark.org>
Reviewed-by: Pascal Quantin <pascal@wireshark.org>
2020-01-20 21:29:51 +00:00
Jirka Novak 12a13a6926 RTP: decode iLBC payload
It is possible to decode iLBC payload. It uses libilbc library (https://github.com/TimothyGu/libilbc).

Bug: 16314
Change-Id: Id4cad7ae32305a0e94ef32beb24e07733d7f834e
Reviewed-on: https://code.wireshark.org/review/35686
Reviewed-by: João Valverde <j@v6e.pt>
Petri-Dish: Pascal Quantin <pascal@wireshark.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2020-01-20 07:50:08 +00:00
Gerald Combs 451a241e50 Add c-ares to the required library list.
Although c-ares support was techically optional, it was either on by
default or required in all of our packaging. Go ahead and require it
globally. C-ares is widely available and synchronous name resolution can
easily result in a horrific user experience.

Change-Id: Id67c797316ed6b8a0ab5052e55a43a1b9e2a2464
Reviewed-on: https://code.wireshark.org/review/35188
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2019-11-23 22:45:59 +00:00
Peter Wu ceb2ee2e44 rpm: use python3 to fix CentOS 7 builds
CentOS 7 (1908) started including python3 (Python 3.6), see
https://wiki.centos.org/Manuals/ReleaseNotes/CentOS7.1908

Change-Id: I6418e7839f1119cf1152f445759e92acd4f39cc4
Reviewed-on: https://code.wireshark.org/review/34593
Reviewed-by: Dario Lombardo <lomato@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-09-23 08:50:10 +00:00