Commit Graph

1746 Commits

Author SHA1 Message Date
Vadim Zeitlin
2034f6683b Disable use of wxSecretStore with wxGTK1
libsecret is for GTK+ 2+ only and can't be used with GTK+ 1.
2018-07-10 14:54:19 +02:00
Cătălin Răceanu
6b0d920c3f Fixes for mingw64 to allow configure to finish under MSW 2018-06-24 19:47:55 +03:00
Cătălin Răceanu
e2594c8bb9 Add QT5_CUSTOM_DIR as Qt root dir for install and lib subdirs 2018-06-24 19:46:58 +03:00
Vadim Zeitlin
311b2aee5f Check for liblzma headers in configure too and add wxUSE_LIBLZMA
Prepare for using liblzma in wxWidgets code by adding the necessary
option and updating the configure check for it (which had been already
present due to libtiff possible dependency on liblzma).

No real changes yet.
2018-04-06 15:39:39 +02:00
Vadim Zeitlin
6037718fef Don't try building universal macOS binaries for PPC
Support for this architecture is not present in any of the still
supported SDK versions anyhow.
2018-03-08 23:21:44 +01:00
Tobias Taschner
f3f1819daf Add archive sample
This sample shows usage of wxArchiveStream and wxArchiveFactory.
It also allows for easy testing of wxArchiveStream implementations
outside of the unit tests.

See https://github.com/wxWidgets/wxWidgets/pull/730
2018-02-20 14:39:27 +01:00
Vadim Zeitlin
2ec2837f6d Update version to 3.1.2
Run misc/scripts/inc_release and rebake.
2018-02-20 00:08:01 +01:00
Vadim Zeitlin
8881953bea Add support for --with-cxx=17 configure option
Use the latest version of ax_cxx_compile_stdcxx.m4 from the autoconf
archive for C++17 support and handle "17" as the option value in our
configure.

See https://github.com/wxWidgets/wxWidgets/pull/721
2018-02-06 22:38:26 +01:00
Vadim Zeitlin
56511118d9 Merge branch 'cxx11-abi-fix'
Avoid ABI issues when building the library in C++98 mode and the
application using C++11 due to using different unordered containers.

Closes #18034.
2018-01-25 13:50:21 +01:00
Tobias Taschner
ddceaab001
Remove MSW wxUxThemeEngine class
This undocumented "private" class was used for various windows UxTheme
functions which are available since WinXP. As wxWidgets 3.1 is XP+ it
does not make sense anymore to load the theme functions dynamically.
2018-01-22 00:51:11 +01:00
Vadim Zeitlin
e723bb2ee4 Try to fix macOS build using cmake after xlocale changes
Commit bc13119494 removed the inclusion of
xlocale.h because it is not (and never was) needed under Linux with
glibc, but it is still needed under macOS, so this (silently) disabled
wxXLocale support under Mac when using configure and broke the build
when using cmake.

Fix both problems by using xlocale.h only if it's available, both in
configure and in cmake.
2018-01-21 16:49:26 +01:00
Vadim Zeitlin
bc13119494 Don't check for non-standatd xlocale.h in configure
Testing for xlocale.h was due to a misunderstanding, this header wasn't
supposed to define locale_t which is defined by locale.h itself and was
just some internal glibc header which was removed in its 2.26 release,
see

https://sourceware.org/glibc/wiki/Release/2.26#Removal_of_.27xlocale.h.27

Stop checking for it in configure and also don't always define
wxUSE_XLOCALE but only do it if the configure test succeeded.
2018-01-20 13:47:21 +01:00
Vadim Zeitlin
00b3b323de Define std-related symbols in configure when using C++11 too
Even though we don't need to perform the checks for the availability of
<unordered_map> or <type_traits> headers when using C++11 because we can
safely assume they're indeed available, we still need to define the
corresponding symbols, as if the checks were performed, so that the code
inside and outside the library could test them in any case, whether
we're using C++11 or not.
2018-01-14 03:09:12 +01:00
Rafael Kitover
22b0b4dda7 autoconf and bakefile support for GTK+4
Add autoconf and bakefile support for detecting and using GTK+4, similar
to how GTK+3 is detected and used.

GTK+3 is checked for first before GTK+4, this can be overridden in
`./configure` using `--with-gtk=4`.

With GTK+4 the `__WXGTK4__` `#define` is also set in `setup.h.in`.

This commit does not regenerate any files.
2017-12-12 08:48:36 -08:00
Vadim Zeitlin
38cc8498d1 Fix wxXLocale availability detection in configure
This was broken by 9507bc430e which
stopped defining HAVE_LOCALE_T in configure but didn't update the code
using it.

Restore the old behaviour by continuing to define HAVE_LOCALE_T even if
we don't test (just) for it any longer.

See https://github.com/wxWidgets/wxWidgets/pull/461
2017-12-10 02:32:54 +01:00
Vadim Zeitlin
b0c4cb7131 Correct order of 3rd party libraries in wx-config output
A recent change fixing monolithic build broke the normal build when
using built-in libraries under Unix as -lwxzlib now came before -lwxpng
and so zlib symbols used by libpng were not found (in fact, they could
still be found in the system library which is usually available under
Unix, so the problem wasn't seen immediately, but it was still there).

See https://github.com/wxWidgets/wxWidgets/pull/621
2017-12-08 02:38:47 +01:00
Pavel O
204bc3c887 Fix linking of wxscintilla in static monolithic build
wx-config didn't report -lwxscintilla for `wx-config --libs stc` in static
monolithic build.

Since stc is a part of monolithic lib, -lwxscintilla will be reported
for `wx-config --libs` now as well.
2017-12-05 23:02:47 +01:00
Pavel O
390a3885ba Fix linking of third party system libs in static monolithic build
Include 3rd party libs in wx-config output even when using the system,
and not the built-in, versions of them for static monolithic build.

See https://github.com/wxWidgets/wxWidgets/pull/621
2017-11-30 21:58:06 +01:00
Pavel O
e7e649df40 Check for lzma and jbig when using system libtiff
Currently lzma and jbig libraries are checked only for builtin
libtiff. When the system libtiff is built with lzma and jbig
support and when the `--with-libtiff=sys` flag is specified
the configure script will fail, due to missing linking with
lzma and jbig.

Fixed this by moving lzma and jbig checks from libtiff-builin check
above all libtiff checks. Also added lzma and jbig libs to
EXTRALIBS_GUI.

See https://github.com/wxWidgets/wxWidgets/pull/619
2017-11-27 21:57:07 +01:00
Vadim Zeitlin
472bb3d6d2 Fix wxUSE_PRIVATE_FONTS definition in configure
Only define it unconditionally for wxMSW and wxOSX, not wxGTK where we
need to test that the required versions of FontConfig and Pango Fc are
available.

Also do all wxUSE_PRIVATE_FONTS-related checks in the same place, to
make things more clear and avoid similar blunders in the future.
2017-11-25 00:07:01 +01:00
Vadim Zeitlin
b040dab0ca Add wxUSE_PRIVATE_FONTS and drop wxHAS_PRIVATE_FONTS
Handle this feature as all the other ones and provide a configure switch
and a setup.h option to disable it if necessary, as it may be desirable
to do it, especially under Linux, to avoid extra dependency on pangoft2
if this functionality is unnecessary.
2017-11-24 22:56:17 +01:00
Vadim Zeitlin
a98c51e6bc Check for pangoft2 >= 1.38 in configure too
We need to use PKG_CHECK_MODULES(pangoft2) anyhow because we need to
link with its libraries, so make the version check there too and
simplify wxFont::AddPrivateFont() implementation in wxGTK.
2017-11-14 15:27:49 +01:00
Vadim Zeitlin
3158a46ce7 Require fontconfig >= 2.8 and change its guard macro name
FcConfigAppFontAddFile() that we use is only available since 2.8, so
check for at least this version of the library in configure.

Also change the macro guarding its use to the more semantically
appropriate "wxHAVE" rather than "wxUSE" and make it more precise by
adding "2_8_0" suffix to it.
2017-11-13 22:29:30 +01:00
Vadim Zeitlin
ac4f99fa0d Test for FontConfig availability in configure when using wxGTK
This library is now needed in order to implement wxFont private font
methods.
2017-11-13 22:29:29 +01:00
Vadim Zeitlin
824134d427 Replace Expat sources directory with a Git submodule
This will make it simpler to track upstream in the future.
2017-11-11 20:50:50 +01:00
Sean D'Epagnier
35bc8f449b Improve build and widget storage
There are no longer any qt headers included in wx/qt headers.
Applications do not need to link with qt librarys anymore, only wxqt libraries.
wxWindow and derived widgets only contain one pointer to their qtwidget, no longer
  carrying both base and derived pointers in parallel as was before.
2017-11-06 02:05:40 +01:00
Vadim Zeitlin
e70fc11ef1 Replace CppUnit with Catch for unit tests
Drop the legacy CppUnit testing framework used for the unit tests.
Replacing it with Catch has the advantage of not requiring CppUnit
libraries to be installed on the system in order to be able to run
tests (Catch is header-only and a copy of it is now included in the
main repository itself) and, in the future, of being able to write
the tests in a much more natural way.

For now, however, avoid changing the existing tests code as much as
[reasonably] possible to avoid introducing bugs in them and provide
the CppUnit compatibility macros in the new wx/catch_cppunit.h header
which allow to preserve the 99% of the existing code unchanged. Some
of the required changes are:

 - Decompose asserts using "a && b" conditions into multiple asserts
   checking "a" and "b" independently. This would have been better
   even with CppUnit (to know which part of condition exactly failed)
   and is required with Catch.

 - Use extra parentheses around such conditions when they can't be
   easily decomposed in the arrays test, due to the use of macros.
   This is not ideal from the point of view of messages given when
   the tests fail but will do for now.

 - Rewrite asserts using "a || b" as a combination of condition
   checks and assert macros. Again, this is better anyhow, and is
   required with Catch. Incidentally, this allowed to fix a bug in
   the "exec" unit test which didn't leave enough time for the new
   process to be launched before trying to kill it.

 - Remove multiple CPPUNIT_TEST_SUITE_NAMED_REGISTRATION() macros,
   our emulation of this macro can be used only once.

 - Provide string conversions using Catch-specific StringMaker for
   a couple of types.

 - Replace custom wxImage comparison with a Catch-specific matcher
   class.

 - Remove most of test running logic from test.cpp, in particular don't
   parse command line ourselves any longer but use Catch built-in
   command line parser. This is a source of a minor regression:
   previously, both "Foo" and "FooTestCase" could be used as the name of
   the test to run, but now only the latter is accepted.
2017-11-02 01:53:16 +01:00
Vadim Zeitlin
9f4f075034 Disable the use of precompiled headers under Unix by default
The speed advantage from using them is very variable, rarely big and
sometimes even negative, while the space penalty is consistently huge,
so it doesn't seem like a good trade-off to enable them by default.
2017-10-21 22:34:45 +02:00
Vadim Zeitlin
0a093193cf Merge branch 'mac-configure-fixes'
Miscellaneous improvements to configure under macOS, see
https://github.com/wxWidgets/wxWidgets/pull/568
2017-10-21 22:12:31 +02:00
Vadim Zeitlin
d9e4f72fd2 Remove unused configure --enable-objc_uniquifying option
This was only ever used in the alternative wxCocoa port which was itself
removed quite a long time ago.
2017-10-21 19:06:33 +02:00
Vadim Zeitlin
7b373703f7 Only use macOS-specific options when configuring for macOS
Don't even check for options such as --with-macosx-xxx or
--enable-universal_binaries when not targeting macOS, as they only make
sense for this platform.
2017-10-21 19:04:20 +02:00
Vadim Zeitlin
4754621959 Do Mac-specific checks in configure for all ports under Darwin
Configure options such as --enable-universal_binary or
--with-macosx-version-min should be taken into account for any port
being built under macOS, not just wxOSX itself.

In particular, this ensures that PCH and dependencies tracking is
correctly disabled automatically when building universal wxGTK
libraries.

Closes #15454.
2017-10-21 18:59:16 +02:00
Vadim Zeitlin
c77c43cf8c Remove checks for Carbon Mac tools not used any longer
We don't use Rez, DeRez and SetFile any longer and they are not
referenced in bakefile-generated makefiles any longer since the previous
commit.
2017-10-21 17:47:33 +02:00
Lauri Nurmi
94c35b2cdd Implement new static function wxDateTime::GetFirstWeekDay()
This function tries to determine the preferred first day of week to use in
calendars. The procedure for obtaining this information is highly
platform-dependent, and is not possible on all platforms; in that case
Sunday is used as the fallback value.

Implementations are included for MSW, OSX, and Linux.
2017-09-02 17:02:35 +03:00
Stefan Csomor
4f04aedf4f correcting comparison, since minimum system is transmitted we have to use the MAX_ALLOWED in order to test for SDK 2017-06-08 11:45:25 +02:00
Stefan Csomor
85a24fd4db properly support weak_linking AVKit when compiling under 10.9 + SDK, even when deployment can be lower, removing QTKit 2017-06-08 10:37:58 +02:00
Vadim Zeitlin
2f8a343b22 Add an option for reproducible library builds
This can be useful to the library packagers, notably under Debian.

Closes #17000.
2017-05-27 19:03:32 +02:00
Vadim Zeitlin
a7ae3de703 Don't accept nonsensical --without-<toolkit> options in configure
Only --with-<toolkit> options make sense, something like --without-x11
couldn't possibly be useful and was actually actively harmful as it set
wxUSE_UNIVERSAL to 1 as a side effect.

Closes #2306.
2017-05-27 19:03:32 +02:00
Vadim Zeitlin
aa7e10bb09 Check --enable-xxx and --with-xxx options in configure by default
Give an error if an unknown option is specified because this is very helpful
for catching typos which happen quite frequently in practice, considering the
number of options that we have.

To explicitly allow unknown options, i.e. restore the old behaviour,
--disable-option-checking can be used.
2017-05-27 19:03:31 +02:00
Vadim Zeitlin
1c4071a3cb Remove obsolete and useless --enable_no_deps configure option
This option didn't do anything for the last 14 years, ever since the switch to
bakefile-generated makefiles in fe0895cf82, so
remove it from configure and stop mentioning it in documentation.

Use --disable-dependency-tracking to do what this option used to be doing 15
years ago.
2017-05-27 19:03:31 +02:00
Vadim Zeitlin
545bec0bac Revert "Remove last vestiges of Carbon-related tools from the makefile"
This reverts commit 2a3721bf98 because it
requires further changes in bakefile itself to really work under Mac, where
the build would be broken as soon as configure would be regenerated (which was
forgotten by that commit due to another error, and so the two errors finally
cancelled out).
2017-05-27 18:27:26 +02:00
Vadim Zeitlin
2a3721bf98 Remove last vestiges of Carbon-related tools from the makefile
Don't detect DeRez, Rez and SetFile in configure, they are not used any
longer as .r resource files are not used under modern macOS.
2017-05-20 16:50:59 +02:00
Scott Talbert
f18d14ce77 Call PKG_PROG_PKG_CONFIG in configure.ac outside of any conditionals
Also, remove the other calls to PKG_PROG_PKG_CONFIG which are then no longer
necessary.

This ensures that all PKG_CHECK_MODULES() calls work correctly and, in
particular, fixes detecting cppunit under macOS and, due to this, Travis CI
build.
2017-05-12 00:54:34 +02:00
Vadim Zeitlin
d0aaea5143 Merge branch 'staging' of https://github.com/stahta01/wxWidgets
Allow building wxGTK for MSW using MSys2 and configure.

Close https://github.com/wxWidgets/wxWidgets/pull/428
2017-05-04 02:51:52 +02:00
Vadim Zeitlin
7fb926c664 Always use wxGTK, not wxMotif, by default under Unix systems
wxMotif is not in a shape to be really for anything currently.
2017-04-23 16:13:40 +02:00
Scott Talbert
cbe0a1f049 Add support for WebKit2GTK+ in wxWebView 2017-04-22 20:00:48 +01:00
Vadim Zeitlin
7d2bc0fc89 Merge branch 'xlocale-checks'
Fix build on systems which don't have full x-locale support even though they
do have <xlocale.h>, such as OpenIndiana.

Closes https://github.com/wxWidgets/wxWidgets/pull/461
2017-04-20 15:56:05 +02:00
Vadim Zeitlin
259b55a17c Rename wx_cv_use_xlocale_local to wx_cv_func_strtod_l
No real changes, just use more standard naming convention for a variable
containing the cached value in configure.
2017-04-20 15:55:33 +02:00
Lauri Nurmi
9507bc430e Determine availability of the required xlocale API by compiling
Even if <xlocale.h> exists, the whole API that wx requires (specifically
strtod_l() and similar) may not be available. This is the case
on e.g. OpenIndiana (SunOS).
2017-04-19 15:31:02 +03:00
Lauri Nurmi
aa5af25870 Compile the check for ICONV_CONST as C++
On OpenIndiana (SunOS) the result is different when compiled as C,
and the C++ result is what matters to wxWidgets.

Fixes compilation of src/common/strconv.cpp on OpenIndiana.
2017-04-19 15:30:41 +03:00