Commit graph

1763 commits

Author SHA1 Message Date
Vadim Zeitlin
e89f05faba Remove memory debugging/tracing support and all related options
Drop disabled by default and pretty useless memory tracing code and all
the overlapping and poorly documented build options related to it.

Remove memory.cpp entirely and update all the make/project files, but
preserve the now completely trivial wx/memory.h for compatibility and
also keep including wx/string.h from wx/object.h as it seems like a lot
of existing code actually depends on this, even if it should not.

Replace the options in the propgrid sample with a couple of other
debug-related options that were not used before to avoid leaving the
"Debugging Section" completely empty.
2023-01-05 21:41:38 +01:00
Vadim Zeitlin
d74c9e51da Remove memcheck sample
This sample wasn't really useful and demonstrated functionality which
was disabled by default since many years and will be completely removed
soon.
2023-01-05 18:24:57 +01:00
Vadim Zeitlin
7899850496 Do use host-specific pkg-config when cross-compiling
This re-enables the use of $host-pkg-config after it was disabled again
by d6ddfe87e1 (Disable build system pkg-config when cross-compiling to
non-Linux, 2022-11-30).

Closes #23037.
2022-12-23 19:24:30 +01:00
Vadim Zeitlin
0f54ec8b36 Update configure after the changes of the last commit
This should have been included in it but was forgotten.
2022-12-04 13:33:36 +00:00
Paul Cornett
471c642979 Simplify configure check for Cairo
Instead of checking for Cairo and then checking for
a function in Cairo 1.2, just check for Cairo 1.2.
2022-11-30 09:22:23 -08:00
Vadim Zeitlin
d6ddfe87e1 Disable build system pkg-config when cross-compiling to non-Linux
This restores a modified form of the original commit 893ebbab0c (Disable
use of build system pkg-config files when cross-compiling, 2020-12-13),
thus mostly reverting 6dbf59f34f (Revert "Disable use of build system
pkg-config files when cross-compiling", 2022-10-25) and now disables the
use of build system pkg-config files only when cross-compiling for
non-Linux hosts.

This seems like the best behaviour by default because it avoids
unexpected problems when cross-compiling for MSW or iOS where build
system .pc files should never be used, but still uses these files, if
they are available, when cross-compiling for other Linux systems.

This is Linux-specific currently but should probably be extended to
other Unix systems too. In any case, the default behaviour can always be
overridden by setting PKG_CONFIG_LIBDIR manually.

See #22886.
2022-11-30 02:18:38 +01:00
Paul Cornett
7d070a7e83 Remove HAVE_ROUND, it is not used anymore 2022-11-28 09:11:01 -08:00
Vadim Zeitlin
280dbce37e Restore configure tests disabled by GTK1 support removal
The changes of fb4f0b590c (Remove wxGTK1 port and GPE support,
2022-10-16) accidentally disabled several checks that were supposed to
be done when using wxGTK, notably for GTK print library.

This was due to WXGTK2 not being defined any longer and is fixed now by
replacing the tests for it with tests for wxUSE_GTK (as WXGTK2 used to
mean "any GTK version other than 1", and not "GTK version 2").

Closes #22994.
2022-11-26 20:24:15 +01:00
Vadim Zeitlin
be7860c766 Remove wxUSE_STD_STRING and wxUSE_STD_CONTAINERS_COMPATIBLY
Assume they are always 1 now, there is no good reason to ever set them
to 0 any more.

Note that we still keep wxUSE_STD_IOSTREAM for now, but we can drop
wxUSE_STD_DEFAULT as it's not worth having it just for this single
option (previously it was used as the default value for 3 of them).
2022-11-17 00:40:50 +01:00
Vadim Zeitlin
b4b23ac423 Merge branch 'always-use-thread-local'
Always use thread_local as we can rely on compiler TLS support working
under Windows 7 and later.

There are some known problems in MinGW thread local variable support,
but they only affect (obsolete) 32-bit builds and will hopefully be
fixed in this compiler soon.

See #22917.
2022-11-10 16:32:42 +01:00
Mojca Miklavec
da4b42688a Fix implicit declaration configuration errors with Xcode 12
Some configure could fail with errors like the following:

conftest.c:56:33: error: implicitly declaring library function 'exit'
with type 'void (int) __attribute__((noreturn))'
[-Werror,-Wimplicit-function-declaration]

See https://trac.macports.org/ticket/61672

Closes #22946.
2022-11-08 18:49:08 +01:00
Vadim Zeitlin
31ac8012e4 Remove Unicode option support from wx-config and wxwin.m4
Keep the option itself, but hardcode its value.
2022-10-28 01:11:36 +02:00
Vadim Zeitlin
c78b0d652b Remove UNICODE build option, hardcode its value as 1
Also hardcode "u" suffix for the library names -- it doesn't make sense
any longer, but we need to keep it for compatibility.
2022-10-27 19:43:59 +02:00
Vadim Zeitlin
a60c9b0f5e Remove --disable-unicode option from configure
Disabling Unicode support is not supported any longer.

Also report Unicode encoding used by wxString at the end of running
configure, this is more useful than just saying "wchar_t", as it's
platform-dependent.
2022-10-27 19:43:30 +02:00
Vadim Zeitlin
4e802e6fc7 Remove wxUSE_COMPILER_TLS and always use C++11 thread_local
Don't use compiler-specific __thread and use the standard keyword
instead.

Keep the existing TLS-related macros for compatibility, but remove our
custom implementation of them, so that they're always trivial now.
2022-10-26 03:31:54 +02:00
Vadim Zeitlin
6dbf59f34f Revert "Disable use of build system pkg-config files when cross-compiling"
This reverts commit 893ebbab0c because it
breaks cross-compiling using target-specific pkg-config installed on the
main system, which is a perfectly legitimate use case.

To avoid the original problem fixed by that commit, PKG_CONFIG_LIBDIR
needs to be set manually before running configure when using host
pkg-config -- but not when using target pkg-config.

Closes #22886.
2022-10-25 18:51:31 +02:00
Vadim Zeitlin
4e52fbc4b5 Merge branch 'qt-fixes'
Various wxQt build fixes.

See #22902.
2022-10-23 15:55:03 +02:00
Vadim Zeitlin
ee67242b5f Add support for wxUSE_TASKBARBUTTON option to configure
Add new --enable-taskbarbutton option and define wxUSE_TASKBARBUTTON as
1 by default instead of always defining it as 0, as was the case before.

Closes #22900.
2022-10-23 15:03:03 +02:00
Vadim Zeitlin
fba8a119a1 Add Unix files to wxQt build under Unix
Compile Unix, but not GUI toolkit, specific wxDialUpManager, wxJoystick
and wxSound implementations when building wxQt.

Closes #22895, #22896.
2022-10-21 19:01:22 +02:00
Vadim Zeitlin
b2050fcb6f Update to Catch v2
Use Catch2 public header instead of using internal Catch v1 headers: we
can do this now because Catch2 supports (albeit in a rather ugly way)
being used with PCH.
2022-10-18 18:39:13 +02:00
Vadim Zeitlin
fb4f0b590c Remove wxGTK1 port and GPE support
Remove the port files and references to it from the common headers and
elsewhere.

Also remove GPE (GNOME PDA Environment) support as libgpewidget is
unmaintained since 2006 or so and has never been really used.

Use __WXGTK__ to test for any version of wxGTK now. Still define
__WXGTK20__ for compatibility, but always define it now and don't test
for it in the library code.
2022-10-16 22:01:02 +02:00
Vadim Zeitlin
0ef1cdcc21 Remove support for wxMotif
This port hasn't been updated for ages and is not used by anybody any
longer, so remove its code to facilitate maintenance.

Also remove references to this port from the documentation and most of
the other places (VMS-specific descrip.vms files still check for it
because it's not clear how to update them all), including configure.

Regenerate the latter and rebake all makefiles.

Finally document that this port is not available any longer.
2022-10-16 16:39:56 +02:00
Vadim Zeitlin
86348a9d28 Stop testing for pre-standard hash map/set classes
Always use std::unordered_{map,set} when we use them at all, don't
bother with checking for their availability and with tr1 or even older
alternatives.
2022-10-11 00:45:30 +02:00
Vadim Zeitlin
a0ae0cd316 Use <type_traits> unconditionally
Don't use or even mention tr1/type_traits any more.
2022-10-11 00:45:30 +02:00
Vadim Zeitlin
583a426a37 Use std::string::compare() unconditionally
Don't test for it in configure/CMake and just always use it.
2022-10-11 00:45:30 +02:00
Vadim Zeitlin
0a387693c6 Use std::wstring unconditionally
Don't test for its existence in configure and CMake and don't use
wxStdWideString in the code.
2022-10-11 00:45:30 +02:00
Vadim Zeitlin
73869d37fd Always use variadic macros and remove wxNO_VARIADIC_MACROS
Variadic macros are always available in C++11, which will be required
very soon, so don't bother testing for them and just always use them.
2022-10-11 00:02:29 +02:00
Vadim Zeitlin
7aea15dda5 Require C++11 in configure 2022-10-11 00:02:28 +02:00
Vadim Zeitlin
327d65be92 Change package version in configure to 3.3.0 2022-10-11 00:02:28 +02:00
Vadim Zeitlin
097abf20b9 Stop disabling deprecation warnings when compiling wxGTK
Don't use blanket warning suppression, as this suppresses even warnings
about using our own deprecated API which is undesirable.
2022-09-25 01:11:55 +02:00
Artur Wieczorek
8a64c8abdc Remove v2.8 compatibility flag, add v3.2 flag 2022-08-02 08:26:04 +02:00
Vadim Zeitlin
6ed6d97bfe Don't use system libcurl under Mac with --disable-sys-libs
It doesn't seem right that the system zlib (installed by e.g. MacPorts)
can be picked up by configure even when --disable-sys-libs is specified,
so disable its use under Mac, as libcurl is optional there.

Still use the system libcurl under Linux in the same case, however, as
it's required to have wxWebRequest at all there and dependency on it is
not really a problem in practice.

This commit is best viewed with Git --color-moved
--color-moved-ws=ignore-all-space -w options.
2022-07-30 15:00:27 +02:00
Vadim Zeitlin
556868390f Merge branch 'statvfs'
Fix statvfs() detection in CMake under NetBSD and prefer statvfs() to
non-portable statfs() more generally.

See #22643.
2022-07-24 16:44:06 +02:00
Vadim Zeitlin
e62e7a6d62 Check for statvfs() first in configure
This POSIX function should be preferred to Linux/BSD-specific statfs()
if it's available (as should always be the case nowadays).

This commit is best viewed with Git --color-moved
--color-moved-ws=ignore-all-space -w options.
2022-07-24 16:43:04 +02:00
Vadim Zeitlin
af4ad43824 Rebake and rerun autoconf after the version update 2022-07-17 17:03:39 +02:00
Mark Harfouche
a157327207 Fix wxrc installation under macOS
Run install_name_tool on wxrc binary again: this used to be done and is
still needed, but was broken in 30915c6163 (Make wxrc independent from
GUI support, 2021-07-07) which moved the code appending the line calling
install_name_tool for wxrc to change-install-name script before this
script creation, meaning that it was simply overwritten later.

See #22620.
2022-07-10 23:28:19 +02:00
Vadim Zeitlin
2a2308d5ed Update version to 3.2.0 and rebake and rerun autoconf
Update all make/project files to use 3.2.0.
2022-06-21 00:54:26 +02:00
Maarten Bent
665692f6a8 Add --enable-webviewedge to configure
It is disabled by default, just like other build systems.
Add -Wno-unknown-pragmas to the configure build too.
2022-05-22 19:20:10 +02:00
Vadim Zeitlin
a7eee933c6 Merge branch 'tsan-warnings'
Fix a harmless warning from thread sanitizer and make wxAtomicInc() more
useful.

See #22417.
2022-05-11 02:37:26 +02:00
Maarten Bent
760bfaa34e Add --with-nanosvg option to configure
So wxUSE_NANOSVG is enabled by default.
2022-05-11 01:55:19 +02:00
Vadim Zeitlin
cf66ce5f94 Return the new value from wxAtomicInc() too
This is easy to do and can be useful when using an atomic initialization
counter.

The only platform where not returning the new value might be more
efficient than returning it is Solaris which is not really relevant any
more and on all the other platforms the functions we were already using
provided this value already (or almost, in case of using gcc builtins,
when we just have to use a different one).
2022-05-11 00:16:47 +02:00
Vadim Zeitlin
5d5591816d Update to bakefile 0.2.13 to fix DLL directory creation
Fix the bug introduced in ec0734f96f (Install DLLs in bindir, not
libdir, when using MSW toolchains, 2021-01-09): the directory where the
DLLs were installed wasn't created any more, resulting in errors if it
didn't exist.

Update to latest bakefile version adding the missing mkdir command to
fix this and also use a released bakefile version for the wx makefiles.

Regenerate configure to match the new version.

See #14601.
2022-04-23 23:11:31 +02:00
Vadim Zeitlin
7d31e055c4 Don't touch non-wx libraries in "make install" under Mac
Only run install_name_tool on our own libraries as part of "make
install" instead of doing it on all libraries in the installation
directory: this was at best useless and at worst harmful, as some
combinations of install_name_tool and macOS versions don't work well
together and result in corrupting the already installed libraries.
2022-04-17 17:59:01 +02:00
Vadim Zeitlin
d31d645777 Drop remains of support for Metrowerks Standard C++ library
This compiler is not supported since a very long time, so get rid of the
tests for __MSL__.
2022-04-14 00:38:03 +02:00
Vadim Zeitlin
7b0d77e0c0 Remove checks for [v]snprintf() and vsscanf() declarations
Consider that all still supported/existing platforms provide these
declarations, if they provide these functions at all (and they probably
all do, so we almost certainly could remove all the test for them, but
keep them for now).

Note that we still test for broken declarations as this might still be
useful on HP-UX 11 systems, where this problem was reported "only" 8
years ago.

By not using AC_CHECK_FUNCS() we avoid the problem when using it with
snprintf() when cross-compiling with the latest MinGW API headers, see
https://sourceforge.net/p/mingw-w64/bugs/935/ for more details.

This commit is best viewed ignoring whitespace-only changes.
2022-04-14 00:33:51 +02:00
Vadim Zeitlin
19e3a47d98 Update version to 3.1.7 and rebake the makefiles
Make it possible to distinguish the latest master from 3.1.6 before
making any changes.

Closes #22282.
2022-04-07 17:40:13 +02:00
Vadim Zeitlin
762c80b809 Handle --with-cxx=20 configure option too
Although wxWidgets doesn't use any C++20 features yet, still allow
compiling it in C++ 20 mode if wanted.

Update the helper macro for detecting available C++ version support from
https://www.gnu.org/software/autoconf-archive/ax_cxx_compile_stdcxx.html
with just a minor change to de-TAB-ify it to pass our code style check
forbidding indenting with TABs.

Closes #22238.
2022-03-28 00:55:54 +02:00
Lauri Nurmi
d8ddf1307a Fix compilation on recent FreeBSDs by ignoring <sys/epoll.h>
On recent FreeBSDs, the "Linux-only" <sys/epoll.h> exists in the default
include path, and is thus detected by configure. However, the header belongs
to the epoll-shim emulation library, and it is doubtful whether using it
on FreeBSD is a good idea. Therefore check that the operating system
is actually Linux before enabling wxEpollDispatcher.

Closes #22146.
2022-02-25 00:36:53 +01:00
Lauri Nurmi
8b3e0acf75 Fix compilation on 64-bit OpenIndiana (SunOS)
src/unix/mediactrl.cpp failed to compile due to a precision-losing cast
(from 'gpointer' {aka 'void*'} to 'window_id_type' {aka 'unsigned int'}).

Tell pkg-config to use 64-bit configs if building for 64-bit on SunOS.

PKG_CONFIG_PATH is set to /usr/lib/64/pkgconfig in that case.

Documented at:
https://docs.oracle.com/cd/E37838_01/html/E66175/gplhi.html

Closes #22143.
2022-02-20 18:04:38 +01:00
Vadim Zeitlin
271926fde0 Fix description of wxUSE_SPELLCHECK option in configure and CMake
Don't say that it's only for MSW and GTK 3, as it's also available under
Mac. Also don't use "spellchecking" non-word in the description of a
spell-checking option.

No real changes.
2021-10-17 19:36:56 +02:00