| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/237>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously the .test file was generated with a reference to
${installed_tests_dir}/environment, which is only built (from the same
source code) when the module for proxy configuration from environment
variables (without using libproxy) is enabled.
The build-time test already correctly ran environment-libproxy.
Resolves: https://gitlab.gnome.org/GNOME/glib-networking/-/issues/208
Bug-Debian: https://bugs.debian.org/1031166
Signed-off-by: Simon McVittie <smcv@debian.org>
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/235>
|
|
|
|
|
|
|
|
| |
The entry points were not exported, oops! Found by Chun-wei Fan.
Hopefully fixes #185
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/226>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I tried to be too clever here and enabled environment proxy support by
default whenever libproxy is disabled. This strategy fails because all
distros enable auto features:
https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/217#note_1529568
The solution is to enable libproxy by default, and disable environment
proxy by default. This leaves only two remaining auto features: GnuTLS,
which is almost always wanted, and GNOME proxy, which is also almost
always wanted. Just pick the right defaults. If you don't want these
enabled, pass the flag to disable them. Simple
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/220>
|
|
|
|
|
|
|
|
|
|
| |
When making a static module on Windows, we should not have `dllexport`
on g_io_* functions. However, G_MODULE_EXPORT is defined to always have
`dllexport` on Windows because it is made for shared modules only.
Building both shared and static modules is not supported on Windows.
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/223>
|
|
|
|
| |
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/223>
|
|
|
|
|
|
|
| |
Otherwise, the test has no way to test the proxy resolver that it claims
to test.
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/222>
|
|
|
|
|
|
|
|
| |
After reversing the priority of the environment proxy vs. libproxy
proxy resolvers, I forgot to also reverse the logic that ensures the
correct resolver gets used when running tests.
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/222>
|
|
|
|
| |
Fix all deprecation warnings this causes.
|
|
|
|
|
| |
Also build a list of modules so parent project can know which one have
been configured.
|
|
|
|
|
|
| |
They are not needed to build the static library since it's using only
object files from the shared library, but they are needed to link
against them when used in an application.
|
|
|
|
|
| |
In our case it makes no difference, but Meson prints warning if we don't
specify that keyword argument.
|
|
|
|
|
|
|
|
|
| |
This makes it closer to the behaviour we would have if using library()
instead of shared_module(). Ideally Meson should allow us to do just
that, see https://github.com/mesonbuild/meson/pull/3361.
When we can depend on Meson >= 0.60 we should mark 'static_modules'
option deprecated.
|
|
|
|
|
|
|
|
|
|
| |
Since fixing #190, the environment proxy resolver is now redundant with
libproxy and there is no reason for it to be built or installed if
libproxy is enabled. Accordingly, let's give it its own build option. It
will be enabled by default if libproxy is enabled, and disabled by
default otherwise.
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/217>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently the environment proxy resolver has 100 priority. The portal
resolver in GLib has 90 priority, the GNOME settings resolver has 80
priority, and the libproxy resolver is relegated to last place with 0
priority. Making the new environment proxy resolver highest-priority
seemed like a good idea to me because environment variables are for
debugging and surely if an environment variable is set it's because you
want it to be respected, right?
Wrong. Problem is, Console and Terminal both inspect GNOME proxy
settings and translate them into environment variables, see console#81.
If we prioritize the environment variables, which are unable to fully
express the desktop configuration, then we lose out on goodies like
web proxy autoconfig and such. Worse, this will only happen when running
from your terminal, meaning applications will break only when run in
Console or Terminal. Imagine how frustrating that would be to debug.
Although I'm usually reluctant to make major behavior changes in a
stable release, we should revert back to longstanding historical
behavior. The environment proxy resolver will be used only as the last
fallback, useful in case libproxy is not available.
Fixes #190
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/217>
|
|
|
|
|
|
|
|
|
|
| |
If we have something silly stored in gsettings, we should reject it
rather than pass it along to API users. This ensures we return only
valid URIs or NULL.
P.S. This also fixes a GError leak on an error path.
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/212>
|
|
|
|
|
|
|
|
|
| |
This adds an extra layer of safety to ensure our GProxyResolver only
ever returns URIs that GLib considers valid. Otherwise, if libproxy
returns something silly like an empty string, nothing prevents us from
passing it along.
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/212>
|
|
|
|
|
|
| |
I've been waiting to do this for a long time!
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/212>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Instead of blindly trusting the environment, let's make sure we have
actually received proper URLs. An empty string will be assumed to mean
"no proxy, please." Any empty environment variable will still cause all
GNOME proxy settings to be ignored, because you might want to use an
empty environment variable to temporarily suppress use of GNOME proxy
settings without messing with XDG_CURRENT_DESKTOP.
Helps with glib#2597
Fixes #189
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/212>
|
|
|
|
|
|
| |
This way it can be used as a subproject
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/213>
|
|
|
|
|
| |
Otherwise, environment variable proxy configuration of the test runner
could mess up our test.
|
|
|
|
|
|
|
| |
This makes GIO find modules within "meson devenv" without having
to install it on the system.
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/208>
|
|
|
|
|
|
|
|
|
| |
getenv() does not exist on Visual Studio builds at least, but we can be
assured that g_getenv() is.
This will fix the proxy tests on Visual Studio-like builds at least.
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/207>
|
|
|
|
|
|
|
| |
This simplifies the subdir logic in the toplevel meson.build by pushing
it lower. It's not a huge simplification, but helps a bit.
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/204>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
There is no reason to use libproxy just to resolve some environment
variables for us.
This makes it possible to resolve proxies outside GNOME when built with
libproxy support disabled, and also reduces our odds of crashing if a
gjs app uses a libproxy that's linked to mozjs, or if a WebKit app uses
a libproxy that's linked to JavaScriptCore.
This should also help the user in #183 who was confused that libproxy
doesn't look at environment variables when running under KDE. Of course,
apps that use libproxy directly, rather than GProxyResolver, are still
going to look at desktop settings first. That should probably change in
libproxy.
Fixes #162
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/203>
|
|
|
|
| |
Part-of: <https://gitlab.gnome.org/GNOME/glib-networking/-/merge_requests/203>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Every GTask should have a name! This helps when debugging problems.
Also, for every GTask used in an async operation, we should check (a)
that the source tag matches, and (b) that the task is valid. This uses
g_return assertions for anything applications can screw up, and g_assert
for anything internal to glib-networking.
Lastly, there's no need to set a source tag in
g_libproxy_resolver_lookup() since that's a sync function and there's
nowhere it can ever be checked.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently glib-networking code style is inconsistent on whether to test
for NULL using !pointer or pointer == NULL. This is harmful because it
forces us to think and make a decision each time when writing such
conditions.
We have somewhat-arbitrarily agreed to stop writing this out longways.
The tiebreaker is the C++ core guidelines (endorsed by the C++
standardization people):
http://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#es87-dont-add-redundant--or--to-conditions
glib-networking is not C++, but the decision either way is arbitrary, so
this seems like as good a tiebreaker as any. Also, WebKit requires it
this way, and therefore so does Epiphany.
Fixes #72
|
|
|
|
| |
Fixes #73
|
| |
|
|
|
|
|
|
| |
As we could install gsettings-desktop-schemas and things work, we should
also make sure that the GNOME proxy module also works on Visual Studio
builds.
|
|
|
|
| |
This matches what libtool produces, and what gio/gmodule expect.
|
|
|
|
|
|
|
|
|
| |
When static_modules is true, generate a .pc file to each module to be
able to get their private dependencies.
This uses a simplified pkg.generate() API added in Meson 0.46.0.
https://bugzilla.gnome.org/show_bug.cgi?id=795043
|
|
|
|
|
|
| |
Is it GLib's proxy resolver, or is it GLib's libproxy resolver? The
answer is the later, but you'd be forgiven for being very confused.
Let's avoid that.
|
|
|
|
|
| |
It's pointing to a libtool directory that isn't created anymore. This is
handled nowadays by setting GIO_MODULE_DIR in the test environment.
|
|
|
|
|
|
| |
and use fallbacks for the mandatory dependencies
https://bugzilla.gnome.org/show_bug.cgi?id=794709
|
|
|
|
|
|
|
|
|
|
|
| |
These files are not needed except when installed tests are enabled, so
they should not be generated at all by default.
This is good to do for its own sake, but also works around some weird
behavior of meson that has resulted in these files being installed even
when installed tests are disabled.
https://bugzilla.gnome.org/show_bug.cgi?id=794372
|
| |
|
| |
|
| |
|
|
|
|
|
| |
This is precautionary. Should allow libproxy to do the right thing once
we get rid of these older, less-favored environment variables.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This will somewhat reduce the odds that that we'll load libproxy in the
gnome-shell greeter process, causing libproxy's old version of mozjs to
be loaded into the same process as gjs's newer version, causing the
login screen to crash in a spectacular loop of sadness, causing
coredumpctl to thrash the system... yeah.
This is already fixed in gnome-session by
https://git.gnome.org/browse/gnome-session/commit/?id=5f920253dfb2c0f2c4b742690f306cfea2ac6613
but I figure I should do my civic duty here to make it easier to remove
these environment variables in the future.
https://bugzilla.gnome.org/show_bug.cgi?id=790387
|
|
|
|
|
|
|
|
|
|
|
| |
This means we eliminate the priv pointer from final classes, and access
it via the _get_instance_private() getter for derivable classes. It's a
mechanical transformation, except in GTlsCertificateGnutls where a
couple loops need adjusted to make it easier to get the priv struct of
other GTlsCertificateGnutls objects.
This is considered the modern best-practice, and is possible now that we
finally depend on a recent version of GLib.
|
|
|
|
| |
The tabs are slowing me down too much. I'm not doing tabs.
|
|
|
|
|
|
|
| |
When enabled both a shared module and static library are built for each
module.
https://bugzilla.gnome.org/show_bug.cgi?id=791100
|
|
|
|
|
|
|
|
|
|
| |
To be able to static link all modules into an executable,
g_io_module_load/unload/query() symbols needs to be renamed to the new
naming scheme supported by glib 2.56. Those functions should also
support receiving NULL GIOModule, and register the extension point
manually since they won't be pre-discovered by reading giomodule.cache.
https://bugzilla.gnome.org/show_bug.cgi?id=791100
|
|
|
|
|
|
|
| |
This should be 'lib', not libdir, because systemd looks for unit files
under /usr/lib/systemd, not /usr/lib64 and not under multiarch locations.
https://bugzilla.gnome.org/show_bug.cgi?id=790367
|
|
|
|
| |
This reverts commit 101561dc4b28a4ab544c3a498003bc72eddaa63b.
|