Commit Graph
344 Commits
Author SHA1 Message Date
Andy VandijckandMaarten Bent 100eb6efc5 Add SDL3 support 2026-08-02 14:45:12 +02:00
Steve CornettandVadim Zeitlin 8ac3d483a6 Remove wxUSE_UXTHEME option and assume it is always on
It has not been possible to build with this option disabled for 4 years.
It appears there has been little effort to support this option since
then. For 8 years, there has been a duplicate definition of
wxUxThemeIsActive(), causing a linker warning.

Closes #26509.
2026-05-25 21:19:07 +02:00
stevecorandVadim Zeitlin 1bc4900ed6 Remove wxUSE_GEOMETRY
Disabling it doesn't save much on code size and the build without it is
currently broken anyhow, so just remove the possibility to turn it off.

Closes #26388.

Closes #26402.
2026-04-24 19:10:09 +02:00
Vadim Zeitlin 73baab427b Stop checking for putws() in configure and CMake
It doesn't seem to exist anywhere other than under Windows with MSVC
where we already use it when wxHAVE_TCHAR_SUPPORT is true.
2026-04-08 00:13:32 +02:00
Vadim Zeitlin 62ac675ad6 Stop checking for get{host,serv}byname()
These functions are always available, as proven by #error directives in
the code never triggering for all the years they were there, so stop
checking for them and just assume they are available.

Also simplify the check for gethostbyname_r() in CMake and just test
directly if we can use the function with the given prototype, reducing
the number of checks to one in the most common case when before we made
3 of them (one extra due to checking if the function existed first and
another one due to a logical but wrong idea that we need to check for 5
before 6).

Finally, also define HAVE_FUNC_GETSERVBYNAME_R_{6,5} in CMake,
previously it never defined them at all and so reentrant functions were
never used.
2026-04-08 00:05:49 +02:00
Vadim Zeitlin 978599acf5 Drop support for 4 argument getservbyname_r()
This is similar to the previous commit, this getservbyname_r() prototype
shouldn't be used by any contemporary systems any longer.
2026-04-07 23:42:43 +02:00
Vadim Zeitlin 771c730ac8 Drop support for 3 argument gethostbyname_r()
This seems to have been used by old versions of IRIX and shouldn't be in
use anywhere any more, so simplify the code by not taking this prototype
into account any more.
2026-04-07 23:38:23 +02:00
Vadim Zeitlin b5703d4357 Remove check for <widec.h> from configure and HAVE_WIDEC_H
The check for this pre-C99 Solaris header was added back in a49ffb32e2
(include widec.h if it's available, it contains declarations of
[f]putws() under Solaris, 2006-11-09) and shouldn't be needed any more.

CMake never checked for it, so remove the check from configure too and
then remove the now never defined HAVE_WIDEC_H.
2026-04-07 23:21:57 +02:00
Vadim Zeitlin 96ae1fb978 Remove checks wchar.h existence
This header always exists and we already relied on it anyhow, so stop
checking that it does and remove HAVE_WCHAR_H.
2026-04-07 23:21:57 +02:00
Vadim Zeitlin 0e1fc41f8e Remove inconsistent underscore from HAVE_PTHREAD_SET_CONCURRENCY
The names of HAVE_xxx symbols are formed from upper-case name of the
corresponding function and the function is pthread_setconcurrency(), so
remove the extra underscore from the symbol name for consistency.
2026-04-07 23:21:57 +02:00
Vadim Zeitlin b2342ec001 Stop checking if wchar_t is a distinct type, just assume it is
We don't support ancient MSVC version which didn't treat wchar_t as a
distinct type, so don't bother catering for such compilers and simplify
the code by removing the checks for wxWCHAR_T_IS_REAL_TYPE.

Also remove the checks for this from configure and CMake.
2026-04-07 23:21:57 +02:00
Vadim Zeitlin 7ed866c622 Remove tests for non-standard and never used in practice wcstr.h
Stop checking for <wcstr.h>, this header never exists and is not used if
<wchar.h> exists (which it always does nowadays) anyhow.
2026-04-07 23:21:57 +02:00
Vadim Zeitlin a93fa649e4 Remove unused HAVE_FCNTL_H and CMake check for it
This was never used anywhere, we include <fcntl.h> if HAVE_FCNTL is set,
so simply remove the symbol and the CMake check for it (configure never
defined it).
2026-04-07 23:21:56 +02:00
Vadim Zeitlin d9df7db130 Allow choosing between GLX and EGL during run-time
The same library binary can now be used to use either GLX or EGL for
wxGLCanvas implementation instead of the choice being done at build time
(by either always using EGL if it is enabled or always using GLX
otherwise).

New wxGLCanvas::PreferGLX() function (available only if wxHAS_GLX is
defined) can be used to request using GLX even if EGL is available,
otherwise EGL is used by default, just as before.

Additionally new "opengl.egl" system option can be used to the same
effect, mostly to allow users to set "wx_opengl_egl" environment
variable to 0 to use GLX if possible, i.e. with X11 and not Wayland.
2025-12-10 15:37:06 +01:00
Vadim Zeitlin 7aa6da06d0 Remove wxUSE_LONGLONG and always use wxLongLong_t
All supported platforms provide 64-bit integer types since many years,
so remove the legacy wxLongLongWx implementation and rename
wxLongLongNative to just wxLongLong and always compile it in.

Note that wxLongLong itself must still be kept for compatibility as it
has member functions, such as GetValue() or ToString(), that can be used
in the existing code.
2024-10-18 19:26:15 +02:00
Maarten Bent 9d32805ce0 Remove unused wxUSE_COMMON_DIALOGS option 2024-10-05 20:33:48 +02:00
Vadim Zeitlin f072544bd5 Assume sigaction::sa_handler always takes "int"
This is the standard and there doesn't seem to be any contemporary
systems where this is not the case. The configure check for it was
originally added in 101c20d554 (attempting to fix sa_handler signature
for IRIX, 2000-04-01), but IRIX is not supported/doesn't exist any
longer, so don't waste time on checking for this.

The real motivation for this change is that the test failed in CMake
builds, showing just

-- Performing Test wxTYPE_SA_HANDLER_IS_INT - Failed

in the log and then resulting in -fpermissive warnings when assigning
wxFatalSignalHandler to sa_handler and it's simpler to just remove the
check than to debug it.

See #23664.
2023-06-30 00:26:19 +01:00
Vadim Zeitlin 889845fbc4 Add support for wxNO_IMPLICIT_WXSTRING_CONV_TO_PTR to wxString
This symbol is similar to the existing wxNO_IMPLICIT_WXSTRING_ENCODING
and can be defined when building the application (as opposed to when
building the library) to disable implicit wxString conversions to
pointer types, i.e. char*, wchat_t* and void*.

This makes the just added wxUSE_CHAR_CONV_IN_WXSTRING library build
option unnecessary, so remove it.
2023-04-16 01:16:56 +02:00
Vadim Zeitlin 35c35c235e Remove wxUSE_STL which is not really used any longer
wxString is always based on std::[w]string since 2c0c727f49 (Remove wx
own wxStringImpl implementation, 2022-11-16) and all containers use
standard containers by default too now -- and there is a separate
wxUSE_STD_CONTAINERS for this anyhow.

The only remaining use of wxUSE_STL was as the default value for
wxUSE_STD_STRING_CONV_IN_WXSTRING option, but it's not really needed
for this neither, and this option can just be set to 0 by default.

Also add wxUSE_CHAR_CONV_IN_WXSTRING which can now be set to 0 too to
disable all unwanted implicit conversions (even "safe" ones, to wide
strings, in addition to the unsafe ones to narrow strings that could be
already disabled with wxUSE_UNSAFE_WXSTRING_CONV) to allow people who
don't want to have any implicit conversions at all to do it.

Keep --enable-stl configure option for compatibility, but warn if it is
used to tell people that it is not needed any longer.
2023-04-15 17:22:09 +02:00
Vadim Zeitlin 0677d493df Add wxUSE_UNICODE_UTF8 to wx/setup.h
This option can also be used under MSW, so move it to the common setup.h
instead of having it in setup.h.in only.

Also do the same thing for wxUSE_UTF8_LOCALE_ONLY, even if it's less
clear if this one is really useful in non-Unix environment.
2023-03-24 19:18:30 +01:00
Vadim Zeitlin c076721af7 Remove NEED_PBT_H not used any longer
It is not used nor defined since f1a6c1d024 (Don't include pbt.h from
wxMSW code unnecessarily., 2011-11-29).
2023-01-26 17:45:10 +01:00
Vadim Zeitlin 2433e201e4 Remove HAVE_RE_SEARCH
It is not used any longer since removing non-PCRE-based wxRegEx
implementation.
2023-01-26 17:43:54 +01:00
Vadim Zeitlin f205dca9dc Remove wxUSE_UNICODE definition from VMS setup.h
It can't be defined as 0 any longer and will always be 1 anyhow.
2023-01-26 17:32:55 +01:00
Vadim Zeitlin 4060201f77 Remove __DOS__ definition
This is another one which wasn't used since an awfully long time.
2023-01-26 17:32:09 +01:00
Vadim Zeitlin eb22752516 Remove long obsolete hack for MacTypes compilation problem
This is not relevant and we shouldn't have this __Point__ in our headers
any longer.
2023-01-26 17:31:18 +01:00
Vadim Zeitlin e5380e739b Remove Alpha architecture detection
This architecture doesn't exist and is not supported since a very long
time, so stop testing for it and defining __ALPHA__ which was never used
anyhow.
2023-01-26 17:31:05 +01:00
Vadim Zeitlin 15e556e027 Remove vestiges of PowerPC support
It may still be supported for wxGTK, but we don't need to do anything
special for it, so we don't need to define __POWERPC__, which was never
used anyhow, neither.
2023-01-26 17:27:48 +01:00
Vadim Zeitlin e039d78ed3 Remove CONST_COMPATIBILITY which was never used
It already wasn't used in c801d85f15 (Initial revision, 1998-05-20).
2023-01-26 17:24:58 +01:00
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 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 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 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 dd404fdd77 Remove HAVE_STRTOULL and HAVE_WCSTOULL
We can assume these functions are always available now as they are part
of C++11.
2022-10-11 00:02:29 +02:00
Jouk 966ebcc93d Do not call GTKAllowDiagnosticsControl() for gtk<2.0 2022-09-02 12:28:17 +02:00
Artur Wieczorek 8a64c8abdc Remove v2.8 compatibility flag, add v3.2 flag 2022-08-02 08:26:04 +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
Jouk 5536f0196f OnOpenVMS langinfo.h is too old 2022-03-31 08:36:00 +02:00
Jouk 7dd4d1d8b8 Disable Tango Art, because of problems 2022-03-17 09:29:49 +01:00
Jouk f4e0c76346 Add wxUSE_SPELLCHECK to setup for OpenVMS 2021-09-22 08:44:01 +02:00
Vadim Zeitlin 32d9b0413d Don't bother checking for size_t, mode_t and off_t neither
The latter two are always defined in sys/types.h on all Unix systems and
we already define them for MSVC (which doesn't use configure anyhow).

The former type is always defined everywhere.
2021-07-28 21:09:32 +02:00
Vadim Zeitlin e8975eec72 Stop testing for gid_t and uid_t that we never use in CMake
Also remove the corresponding parts of setup.h.in.
2021-07-28 21:01:17 +02:00
Vadim Zeitlin 244389699e Drop checks for pid_t from autoconf and CMake
This type should always be defined in sys/types.h on any non-ancient
Unix system, so don't bother checking for it, which is not only wasteful
but can even be harmful because it can conflict with pid_t definitions
in the other libraries under Windows, where we (wrongly) define it as
int (which is actually a bug in autoconf, which was recently fixed, see
https://savannah.gnu.org/support/index.php?110296) when using CMake.

So just don't define it at all: it should be already defined under Unix
and we don't use it under MSW anyhow.

See https://github.com/microsoft/vcpkg/issues/19110

See #18150.
2021-07-28 21:01:17 +02:00
Vadim Zeitlin dbe0950384 Drop WX_NO_REGEX_ADVANCED and always define wxHAS_REGEX_ADVANCED
Using non-PCRE system regex library, which was the only build variant
when wxHAS_REGEX_ADVANCED was not defined, is not supported any more, so
simplify the code by not testing for it.
2021-07-24 19:17:59 +02:00
Jouk b5a9ef543a Correction of modification date 2021-06-25 08:05:52 +02:00
Jouk 1cc1ddeefb Fix for OpenVMS CRTL version 8.5 2021-06-24 09:01:21 +02:00