Commit Graph
3834 Commits
Author SHA1 Message Date
John Paul Mattia 122ff6d7db Add a multithreaded test for IPC over sockets
Add a test exercising the IPC-over-sockets implementation from a single
thread and from multiple threads concurrently (Execute, Request, Poke,
Advise, combined Advise+Request, and concurrent main-thread and
worker-thread Request()s).

Each test starts its own server by re-executing the test program with
WX_IPC_TEST_SERVER set and shuts it down again in the fixture teardown, so
no server process outlives a test (or disturbs the unrelated GUI tests in
test_gui). The client runs in the main Catch2 process and queries the server
for state to verify it (Catch2 macros cannot run in the server process). The
wait loops are wall-clock bounded so they behave under a GUI event loop, and
a per-fixture watchdog aborts with a diagnostic if a test ever hangs rather
than letting CI time out.

The test runs in both the console "test" and the GUI "test_gui" programs. It
is excluded from one configuration: wxQt, whose event loop does not reliably
process a cross-thread CallAfter() (a wxQt bug fixed separately).
2026-08-06 21:59:34 +02:00
Vadim Zeitlin 5ccdcd6b2a Update version to 3.3.4
Run misc/scripts/inc_release, update version.bkl and rebake.
2026-07-09 15:08:08 +02:00
Vadim Zeitlin b03b365a17 Merge branch 'osx-macos-27'
macOS 27 adaptions.

Closes #26578.
2026-07-02 23:49:20 +02:00
Blake-Madden 4eb22403a5 Remove plugin interface from test_drawing
This was never used and doesn't seem like it ever will be.

Closes #26568.
2026-06-16 00:02:56 +02:00
Vadim Zeitlin fd35f189b6 Merge branch 'msw-dark-taskdlg'
Add dark mode support to wxMSW task dialog-based dialogs.

See #26570.
2026-06-13 20:28:01 +02:00
dxbjavid ebd86dee67 Reject out-of-range parent index in cached help book
LoadCachedBook reads each index entry's parent back-reference straight
from the .cached file and uses it as an index with no check, so a
crafted cached file (which can sit inside a .htb help archive opened
through AddBook) may result in creating a pointer to data outside the
m_index array; that pointer is later dereferenced when the index is
sorted at the end of AddBookParam.

The change rejects the file when parentShift is negative or larger than
the number of index entries loaded so far, matching the existing version
and flags checks just above.

Also add a small test under tests/html that feeds such a cached stream
and confirms it is now refused rather than reading out of bounds.

Closes #26577.
2026-06-11 23:40:20 +02:00
Stefan Csomor 2268c9b5be increase min deployment for macOS 27 SDK 2026-06-10 18:15:43 +02:00
Mohmed abdel-fattah 8e2ac38462 Add dark mode support for task dialog-based dialogs
Show wxMessageDialog and wxProgressDialog using appropriate colours when
dark mode is active.

Closes #26240.

Closes #26311.
2026-06-07 18:14:58 +02:00
Maarten Bent a967bead1a CMake: Declare more build option dependencies 2026-06-06 12:43:16 +02:00
Maarten Bent d3cdfc8882 CMake: Always install common headers
Even when a component is disabled.

Fixes #26515
2026-06-06 12:43:16 +02:00
Hugo Armando Castellanos MoralesandVadim Zeitlin c52190e3d1 Fix building wxBase under Android
Link with "log" library and account for Android having gethostbyname_r()
but not getservbyname_r().

Also remove unnecessary include/wx/android/setup.h and config_android.h
files which seem to have been never used since they were added back in
1b4bff8262 (Add minimal support for building non-GUI parts of wxWidgets
for Android., 2012-02-26).

Closes #26539.

Co-authored-by: Vadim Zeitlin <vadim@wxwidgets.org>
2026-06-01 23:39:03 +02:00
Steve Cornett 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
Blake-Madden ee4fbdfb88 Add getters to wxSVGAttributes, add unit tests
Closes #26479.
2026-05-21 22:45:09 +02:00
Vadim Zeitlin e1c72e28fc Add wxSVGGraphicsContext
Allow using wxGraphicsContext API for SVG generation.

Also add wxSVGFileDC::Begin/EndLayer() and wxSVGLayer RAII helper.

Closes #26395.
2026-05-19 03:01:39 +02:00
Maarten Bent 3d389bbbbf CMake: Add UNICODE define to all targets
Unix builds / Ubuntu 18.04 wxGTK 3 compatible 3.0 (push) Has been cancelled
Unix builds / Ubuntu 24.04 wxGTK ASAN not compatible (push) Has been cancelled
Unix builds / Ubuntu 18.04 wxGTK UTF-8 (push) Has been cancelled
Unix builds / Ubuntu 18.04 wxQt (push) Has been cancelled
Unix builds / Ubuntu 18.04 wxX11 (push) Has been cancelled
Unix builds / Ubuntu 20.04 wxGTK 3 with clang (push) Has been cancelled
Unix builds / Ubuntu 22.04 wxGTK with wx containers (push) Has been cancelled
Unix builds / Ubuntu 18.04 wxDFB (push) Has been cancelled
Unix builds / Ubuntu 24.04 wxGTK UBSAN (push) Has been cancelled
Unix builds / Ubuntu 18.04 wxGTK 3 static with gcc 4.8 (push) Has been cancelled
Unix builds / Ubuntu 18.04 wxGTK 2 (push) Has been cancelled
CMake builds / Ubuntu 22.04 wxGTK 3 (push) Has been cancelled
CMake builds / macOS latest wxGTK 3 Unix Makefiles (push) Has been cancelled
CMake builds / MSW/MSVC wxMSW (push) Has been cancelled
CMake builds / MSW/Clang wxMSW (push) Has been cancelled
CMake builds / macOS latest wxOSX Ninja (push) Has been cancelled
CMake builds / macOS 14 wxOSX Xcode (push) Has been cancelled
CMake builds / macOS 14 wxIOS (push) Has been cancelled
CMake builds / MSW/MSVC wxQt 5.15 (push) Has been cancelled
CMake builds / MSW/MSVC wxQt 6.10 (push) Has been cancelled
Mac builds / wxMac ARM ASAN not compatible (push) Has been cancelled
Mac builds / wxMac Universal C++14 (push) Has been cancelled
Mac builds / wxiOS Simulator on Silicon Mac (push) Has been cancelled
Mac builds / wxiOS (push) Has been cancelled
Mac builds / wxMac Intel C++17 (push) Has been cancelled
Mac Xcode builds / iOS Simulator static (push) Has been cancelled
Mac Xcode builds / macOS dynamic Release (push) Has been cancelled
Mac Xcode builds / iOS static Debug (push) Has been cancelled
MSW builds / wxMSW vs2022 DLL Debug x64 (push) Has been cancelled
MSW builds / wxMSW vs2022 DLL Release x64 (push) Has been cancelled
MSW builds / wxMSW vs2022 Debug Win32 (push) Has been cancelled
MSW builds / wxMSW vs2022 Release arm64 (push) Has been cancelled
MSW builds / wxMSW vs2026 DLL Release x64 (push) Has been cancelled
MSW cross-builds / wxMSW 64 bits not compatible (push) Has been cancelled
MSW cross-builds / wxMSW/Univ (push) Has been cancelled
MSW cross-builds / wxMSW 32 bits (push) Has been cancelled
Code Checks / Check Spelling (push) Has been cancelled
Code Checks / Check Whitespace (push) Has been cancelled
Code Checks / Check Mixed EOL (push) Has been cancelled
Code Checks / Check C++ Style (push) Has been cancelled
Code Checks / Check All Headers In allheaders.h (push) Has been cancelled
So IDEs like Visual Studio show the correct character set.

Add an option to override the character set and use it in the win32 API tests.

See #26458.

Closes #26462.
2026-05-15 02:20:19 +02:00
Maarten Bent cd201ad5f3 CMake: Fix libwebp build properties
Allow to call wx_add_builtin_library for external targets.
and use it for the libwebp targets.

See #26428.

Closes #26456.
2026-05-15 02:12:54 +02:00
iht f5cb9a66c0 Update wxwidgets.props and common.bkl for VS 2026
This is in line with the changes in a0f5c92b96 and 3d88038d01
2026-05-12 16:29:03 +02:00
AtesComp 488e7363bc Add support for private fonts to wxQt
Use QFontDatabase::addApplicationFont() to implement AddPrivateFont().

Closes #26403.

Closes #26419.
2026-05-08 15:48:12 +02:00
Steve Cornett bd00c4806d Remove redundant Visual Studio optimization settings
Remove compiler options implied by /O2 as it makes it unnecessarily more
difficult to replace /O2 with /O1.

Closes #26416.
2026-04-29 23:06:46 +02:00
stevecor 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 8ef84ab4fd Don't use /MP option when not using MSVS CMake generator
It is useless in this case as make/Ninja generators only compile a
single file at once anyhow and can also be harmful when using clang-cl
compiler which gives warnings about unsupported option.

See #26392.
2026-04-19 00:24:57 +02:00
Maarten Bent 8ade35509a CMake: Show check_symbol_exists messages only once
Same behaviour as the built-in check functions.
2026-04-11 20:18:37 +02:00
Maarten Bent 8c1ede6607 CMake: Don't install release PDBs when stripped releases is enabled
See #26338
2026-04-11 20:18:14 +02:00
Maarten Bent 62403ce1e0 CMake: Add wxbase_only target
Can be used by console applications, it links with wx::base with wxUSE_GUI=0.

Update wx_copy_target in wxWidgetsConfig.cmake to handle INTERFACE libraries correctly.

See #26285
2026-04-11 20:18:04 +02:00
Maarten Bent 24571ab89d CMake: Install with relative symlinks
Try to install using 'ln -s --relative' first, before falling back to 'ln -s' and 'cmake  -E create_symlink'.
If all fail, use 'cmake  -E copy'.

Also add an option to disable using symlinks and always copy.

Correctly use and (not) escape DESTDIR and CMAKE_INSTALL_PREFIX in install and uninstall variables.

Fixes #26247
2026-04-11 20:18:04 +02:00
Maarten Bent 54bbd316de CMake: Get rid of macro to link sample libraries
And check if widgets sample targets are valid before using it.
2026-04-11 17:16:28 +02:00
Maarten Bent 48092f29cb CMake: Set the wx-config RESCOMP value 2026-04-11 17:16:27 +02:00
Maarten Bent 7f293e4194 CMake: Refactor applying toolkit properties
Group them together in base and not-base.
2026-04-11 17:16:27 +02:00
Maarten Bent 764d775076 CMake: Allow to override wx_option_auto 2026-04-11 17:16:27 +02:00
Maarten Bent b17a03da7f CMake: Import install properties of static libraries
When installing static libraries, the built-in libraries also need import mappings for MinSizeRel and RelWithDebInfo configurations.
Otherwise they will default to using Debug libraries.
2026-04-11 17:16:27 +02:00
Vadim Zeitlin e54db6712d Don't check for pthread_mutex_timedlock() under Apple systems
Both check_function_exists() and check_symbol_exists() somehow find it
there, but it's not declared when compiling.

Just skip the check for it.
2026-04-08 03:28:51 +02:00
Vadim Zeitlin 9149976823 Make checking for symbols more verbose in CMake
For some reason, check_symbol_exists() doesn't give any messages unlike
check_function_exists(), so give them ourselves when using it.
2026-04-08 03:28:51 +02:00
Vadim Zeitlin 94f53184f2 Skip some CMake checks that always fail under Windows
Don't test for things which have no chances to exist under Windows, this
just wastes time.
2026-04-08 03:28:51 +02:00
Vadim Zeitlin 61caeef0fc Check for _timezone first under Windows
It's not clear if __timezone ever exists, but at the very least don't
test for it first as this fails with MSVC when testing for _timezone
succeeds.

This should have been done in 12a3a16e7b (Prefer using "timezone" to
"__timezone" on POSIX systems, 2026-04-07).

See #25310.
2026-04-08 03:28:51 +02:00
Vadim Zeitlin 2710f61f53 Use check_symbol_exists() for pthread functions
Using check_function_exists() seems to be prone to false positives, e.g.
it detects pthread_mutex_timedlock() as being available under iOS when
it's not actually available there and the build fails later.
2026-04-08 03:28:51 +02:00
Vadim Zeitlin e6ccde6640 Take multiple symbols in wx_check_symbol_exists_if_not_linux()
No real changes, just rename the helper function slightly to allow
passing it multiple symbols to check for in the same header.
2026-04-08 03:28:51 +02:00
Vadim Zeitlin f275d6f435 Add detection of SM library to CMake
Enabling wxUSE_DETECT_SM option broke the build for systems where SM
library is not available as there were no actual checks for it.

Add the check now.
2026-04-08 01:03:16 +02:00
Vadim Zeitlin 4b7600e9b5 Fix quoting in wx_check_c_source_compiles_if_not_linux() 2026-04-08 00:57:55 +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 5d13d7cedc Skip checks that always succeed under Linux in CMake
This significantly cuts down the number of checks and running time of
CMake configure stage.
2026-04-08 00:10:00 +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 4b936606bc Don't check for gethostname() in CMake if uname() was found
The existing test was reversed (which indicates that we probably don't
need to test for gethostname() at all and could just assume that uname()
is always available), we only need gethostname() as fallback in case
uname() is not found.
2026-04-07 23:59:05 +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 6ad18e66cb Only check for ftime() in CMake if gettimeofday() is not found
We use ftime() only as fallback, so don't waste time checking for it if
it's never going to be used.
2026-04-07 23:21:57 +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 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 73d66e7aa7 Check for _NL_TIME_FIRST_WEEKDAY in CMake build too
HAVE_NL_TIME_FIRST_WEEKDAY was never defined otherwise.
2026-04-07 23:21:56 +02:00