summaryrefslogtreecommitdiff
path: root/sync-build.sh
AgeCommit message (Collapse)AuthorFilesLines
2019-01-28sync-build.sh: remove RPATH settingPeter Wu1-10/+0
Since v2.9.1rc0-449-ga37388fbb6 it is no longer possible to override CMAKE_INSTALL_RPATH to create relocatable build directories. An attempt to add this feature in a generic way to older CMake versions failed, see https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=15163#c12 I do not really need relocatable builds at the moment and can wait until CMake 3.14 is released should I need it in the future.
2019-01-17sync-build.sh: use lld only for Clang 8 and newerPeter Wu1-5/+12
GCC does not support -fuse-ld=lld and LLD 7.0.1 has a bug that causes crashes when (statically) linking code that uses thread-local storage without a PLT.
2019-01-13sync-build.sh: switch to lld, remove unused stuffPeter Wu1-13/+8
Remove ENABLE_xxx options that are enabled by default, check CMakeOptions.txt instead if you want to see available values. Skip rebuilding if only tests change. Remove -fsanitize options since these are set via CMake options. Use lld instead of gold since it is almost twice as fast as gold: lld 4.8s gold 9.2s bfd 10.8s Tested (n=3) with lld 7.0.1-1 and binutils 2.31.1-4 on Arch Linux, Linux 4.19.12-arch1-1-ARCH, i7-6700HQ, wireshark v2.9.1rc0-363-g178d81f804. Commands: time cmake -GNinja /tmp/wireshark -DCMAKE_BUILD_TYPE=Debug \ -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ \ -DCMAKE_C_FLAGS="-fdiagnostics-color -fuse-ld=lld" \ -DCMAKE_CXX_FLAGS="-fdiagnostics-color -fuse-ld=lld" \ -DDISABLE_WERROR=1 -DENABLE_ASAN=1 -DENABLE_UBSAN=1 time ninja && rm -rf run time ninja # measured this with various -fuse-ld= values. Total build time is about 21s for cmake, 3m18s for the initial ninja. Ignoring the noise, a full build somehow takes about the same time as with gold, but incremental builds with lld are consistently faster.
2018-07-31sync-build.sh: drop obsolete cmake options, ignore some changesPeter Wu1-5/+2
Do not wake up on running tests (which might touch __pycache__ and pytest files).
2017-11-07sync-build: enable ASAN/UBSAN via option, remove gcrypt optionPeter Wu1-1/+2
GCRYPT is enabled by default, the option is gone since 2.4. Enable the ASAN option via CMake to ensure that building lemon does not fail if detect_leaks is not set.
2016-12-21notes,sync-build.sh: notes for MPX, build adjustmentsPeter Wu1-4/+5
Append to PATH to avoid clobbering it when putting ccache in $PATH. Enable SBC codec for testing. Enable debug-prefix-map, should make relocatable debug builds easier (where I build in a different directory and move it).
2016-05-12sync-build.sh: fix PKG_CONFIG_LIBDIR, enable gold linkerPeter Wu1-1/+2
Gold linker seems marginally faster.
2015-12-05sync-build.sh: allow BUILDDIR and cmake options overridePeter Wu1-4/+23
For testing other build types (-DCMAKE_BUILD_TYPE=RelWithDebInfo) and compilers (BUILDDIR=/tmp/wsbuild-gcc).
2015-10-11sync-build.sh: enable relocatable folder, copy more filesPeter Wu1-9/+19
Copy compile_commands.json, config.h. (ab)use CMAKE_INSTALL_RPATH to enable relocatable executables. Note that this is only safe for development, if you install the generated binaries without stripping/modifying rpath, then insecure situations may occur in an hostile environment (wrong libraries may be loaded).
2015-07-10sync-build.sh: enable compression for rsyncPeter Wu1-0/+2
Advantages: lower transmission size, faster completion for slow WAN links. Disadvantage: slight delays in compile output reporting.
2015-06-28sync-build.sh: allow to specify targetPeter Wu1-2/+7
Useful to build just tshark if I want to test a dissector.
2015-03-24sync-build.sh: immediatelly trigger build on execPeter Wu1-0/+5
Avoids the need to manually touch /tmp/sync-build-* to trigger a build on startup. Can be overridden with the NOTRIGGER=1 env.
2015-03-06sync-build.sh: allow running it locallyPeter Wu1-10/+17
Let 'localhost' bypass SSH so I can still use its watch functionality, but build locally. Use -fno-common to workaround bug https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65285 Disable verbose warnings and disable werror to reduce the huge trace of warnings which make me overlook real issues.
2015-02-20sync-build: force colorPeter Wu1-1/+1
Ninja can strip colors if needed, but otherwise it needs to be forced on https://github.com/martine/ninja/issues/174
2015-02-20Switch to ninjaPeter Wu1-1/+2
Ninja is awesome, it is faster than Unix Makefiles!
2015-02-14sync-build.sh: cflags envvar tweaksPeter Wu1-5/+19
Default CXXFLAGS to CFLAGS (previously it would always use CFLAGS anyway due to a typo), do not require schroot, use 2*nproc instead of hardcoded 16 jobs. Document envvars.
2015-02-07sync-build.sh: more color, only ignore top-level config.hPeter Wu1-4/+5
There is packaging/macosx/native-gtk/config.h
2015-01-29sync-build.sh: use GTK3, allow cmake regenerate forcePeter Wu1-3/+10
2014-12-10sync-build.sh: enable extra warnings, ignore filesPeter Wu1-0/+3
2014-10-01sync-build.sh: add -fsanitize=undefined, NOCOPYPeter Wu1-3/+12
2014-09-26sync-build.sh: 32-bit on 64-bit supportPeter Wu1-14/+47
Also allows you to override CC/CXX (for Clang support), fix /tmp/wireshark/ symlink and /tmp/wsbuild/run/ sync, enable some additional modules (but disable SBC which would be used for Bluetooth audio support), pass -DCMAKE_EXPORT_COMPILE_COMMANDS (for clang-check iirc).
2014-07-07sync-build.sh: remote compilation after editingPeter Wu1-0/+109
This script helps me in syncing sources with a remote build machine and building changes once I have made a local change. It also syncs back generated binaries.