Commit Graph

536 Commits

Author SHA1 Message Date
Øyvind Kolås 95900ae6f1 configure,meson,app: depend on GEGL-0.4.30 2021-03-27 20:26:52 +01:00
Jehan 1de810f6de configure, meson: missing OpenRaster MIME type in desktop file.
Adding support for .ora files when Python plug-ins are installed.
2021-02-20 18:48:16 +01:00
Jehan 4b39217181 devel-docs: generate Python API (GObject Introspected) documentation.
So much easier to write in autotools! Anyway here it is, also with a new
option --enable-g-ir-doc (by default set to false).
2021-01-29 15:22:36 +01:00
Jehan 72effc5a57 configure.ac, meson.build: post-release version bump to 2.99.5. 2020-12-22 23:58:16 +01:00
Jehan db996f218d Release development version GIMP 2.99.4. 2020-12-22 23:39:07 +01:00
bartoszek daea111efc autotools: bump GEGL dependency to 0.4.28. 2020-12-20 17:01:00 +00:00
Jehan b19e7796b2 app: s/pango_fc_font_has_char/pango_font_has_char/ (undeprecation). 2020-11-15 17:25:49 +01:00
Jehan 7a50b0940e app: undeprecate some Pango/Harfbuzz calls.
pango_fc_font_lock_face() is deprecated since Pango 1.44.

This may hopefully also fix #5922 as I completely changed the code where
the CRITICAL happened. Yet I left g_return_val_if_fail() to check if the
Harfbuzz font and FreeType face variables are not NULL (because looking
at the code, it looks like these functions returning NULL actually means
there is a bug in the code).

Nevertheless if it turned out that there are non-bug cases where these
could return NULL (for instance a broken font file?), then probably we
should not use g_return_val_if_fail(), but instead address the data
issue in a nicer way.

Bumping harfbuzz dependency to 1.0.5 for hb_ft_font_set_funcs(). Without
configuring the Harfbuzz font with it, hb_ft_font_get_face() always
returns NULL.
Note that it looks like hb_ft_font_lock_face() would actually be better,
but this requires harfbuzz 2.6.5 from last April which is quite recent.
So let's just use the get_face() variant for now.
2020-11-15 17:15:45 +01:00
Sergei Trofimovich cebeb90a87 configure.ac: fix `--with-linux-input` handling with upcoming autoconf-2.70
Upcoming autoconf-2.70 exposes deficiency in configure.ac:

```
$ autoconf-2.70_beta2 && ./configure --host=x86_64-pc-linux-gnu
./configure: line 1430: 5: Bad file descriptor
checking whether  is declared... ./configure: line 1432: ${+y}: bad
```

It happens because macros are called with parameters using insufficient quoting.

More details at https://lists.gnu.org/archive/html/bug-autoconf/2020-10/msg00027.html

The fix only amends `--with-linux-input`. Other cases of underquoting
will need to be handled separately.

Fix-by: Zack Weinberg
Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
2020-10-26 16:29:01 +00:00
Michael Natterer c6f6c42e7a configure.ac, meson.build: post-release version bump to 2.99.3 2020-10-25 22:26:18 +01:00
Michael Natterer 71d24f1103 configure.ac, meson.build: bump versions for the 2.99.2 release 2020-10-25 21:25:47 +01:00
Jehan fc25709367 configure: do not show "profile support: yes" when HEIC support is OFF.
Same as previous commit but for autotools, in a separate commit for easy
cherry-pick.
2020-10-22 11:57:12 +02:00
Jehan 22b8cd305c autotools: separate line for HEIC and AVIF support.
Similar to previous commit for meson (separate commit for easy
cherry-pick to gimp-2-10).
2020-10-19 20:15:35 +02:00
Jehan e77d9517f7 meson, autotools, CI: simplify plug-in binding build options.
For Python, Lua and Javascript, make the option boolean (with 'yes'
being the default). No need of a warning when not installing the
plug-ins as this would have been disabled explicitly anyway. When
installing the plug-ins, only make interpreter checks as precautionnary
verifications which don't actually change anything (except outputting
some warnings if interpreters are not found). Basically for these 3
bindings, the interpreters are only runtime dependencies anyway. So it
doesn't matter if they are not available at build time. In particular,
we get rid of the 'force' option.

Vala rules do not change as the vala compiler is indeed needed at build
time and current checks work correctly. I just add a "Vala plug-ins"
line in the summary message of the meson configuration, as it was
missing.
2020-10-12 22:10:17 +02:00
Jehan ecbc38f9e9 plug-ins, extension: goat-exercises becomes a GIMP extension.
This is an extension containing a few demo plug-ins. This is good to
demonstrate the extension format. It will also allow to disable these
plug-ins (if at some point, one doesn't want to show these demo
plug-ins anymore).

And finally it deals with the fact that our plug-in code is stupid, as
it just tries to find the first executable with the same name (minus
extension) as the plug-in folder. This doesn't go well on Windows, where
the permission system is non-existent. So our code just ends up trying
to run the first file with a similar name in a plug-in folder. As the C
goat-exercise contains both an exe and the C source (and the system
probably returns files in alphabetic order), GIMP under Windows tries to
run the C source instead of the executable (this obviously doesn't go
well).
We could try to do more complex logics, like not aborting if the first
file run fails and try the next one in the plug-in folder. Or maybe just
rename the C file to another name. But any of these is just in the end
the proof that our plug-in discovery right now is just bogus. The
extension system is explicit, not based on randomly trying out files.
Plug-ins entry points are explicitly listed in the metadata manifest.
2020-10-09 15:30:54 +02:00
Jehan 0ec5ee4394 plug-ins: get rid of pygimp!
It's done, all Python plug-ins have been either ported to the new API +
Python 3, or they have been discarded (and moved to gimp-data-extras for
whoever wants to salvage them).
Let's get rid of the outdated pygimp directory (whose code has not been
built in the master branch for years now anyway)! Woohoo!
2020-09-21 18:17:18 +02:00
Jehan 5de6b2c1ea autotools, meson: bump GEGL dependency to 0.4.27.
Current dev code of GEGL is necessary as it fixes its VAPI dependency
(see gegl!83). Without this, with a recent meson version, Vala plug-in
build fails.

See !334 for some more background.
2020-09-12 15:54:13 +02:00
Simon McVittie 00024db382 build: Prefer to find libwmf using pkg-config
Traditional -config scripts are awkward for cross-compilation, multilib
systems (lib/lib64), and multiarch systems like Debian; only one copy
of the -config script can be in the PATH. As a result, some OS
distributions are starting to deprecate or even remove them.

pkg-config is designed to be a replacement for traditional -config
scripts, and is cross-compilation-friendly: the PKG_CHECK_MODULES macro
looks for an architecture-specific executable like
x86_64-linux-gnu-pkg-config, which can look in an architecture-specific
search path for library metadata, before falling back to a generic
pkg-config executable.

As a bonus, pkg-config also compares version numbers correctly
(see #2454).

libwmf having pkg-config metadata seems to be a relatively new thing,
so I've kept the -config script code path too, using it if pkg-config
does not find libwmf.

Bug-Debian: https://bugs.debian.org/956183
Signed-off-by: Simon McVittie <smcv@debian.org>
2020-08-26 23:32:32 +00:00
Kevin Cozens 56982e6ce9 Allow building GIMP of without vala.
To build GIMP without vala the arguments "--enable-vala=no --with-vala=no"
must be used during the configuration process. If the --with-vala is not
provided the build process will still try to build some vala based plug-ins.

Fixes https://gitlab.gnome.org/GNOME/gimp/-/issues/5389
2020-08-23 11:20:51 +02:00
Jehan e815c615e1 icons: install switch-(on|off)-symbolic icons in GIMP's hicolor theme.
These icons are not available in any of our themes (Symbolic or Color).
Also they don't seem to be available in many icon themes either actually
and I'm not sure GIMP properly fallbacks to system icon theme when an
icon is missing in the selected theme anyway (I think to remember this
used to work, but it doesn't look like it works anymore).

Anyway I just copied the 2 symbolic switch on|off icons available in the
GTK+ repository at gtk/icons/scalable/status/. These are supposed to be
used by GtkSwitch but somehow they aren't. So for the time being, let's
bundle them directly with GIMP (until we figure something better out).
I put them in hicolor because this is the generic/default theme which is
always used as last resort and is common to any theme. It means any
specific theme will be able to override these icons, but if missing,
hicolor will be able to provide a fallback.
2020-08-22 23:53:49 +00:00
Øyvind Kolås ec746901c3 build, app: depend on GEGL 0.4.26 2020-08-02 22:34:15 +02:00
Peter Oliver 84c08e55e1 Offer image/webp content type in .desktop file
Nautilus will only offer to open WebP files in applications that accept
the `image/webp` content type, not `image/x-webp`.  Even though it isn’t
on the [official
list](https://www.iana.org/assignments/media-types/media-types.xhtml#image),
`image/webp` seems to be more
[widely](https://en.wikipedia.org/wiki/WebP)
[recommended](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types#Image_types)
than `image/x-webp`.
2020-07-22 17:42:41 +00:00
Øyvind Kolås 14765e72b6 meson, autotools, app: depend on GEGL 0.4.24 2020-06-07 21:24:03 +02:00
Øyvind Kolås 529471e1ca meson, autotools, app: depend on babl-0.1.78 2020-06-07 20:33:32 +02:00
Øyvind Kolås d7d0c046f0 app,build: depend on babl-0.1.76 2020-05-27 15:21:09 +02:00
Niels De Graef acf50009f8 Allow building vala plugins 2020-05-26 17:52:52 +00:00
Jehan 49351777b6 Issue #3884: missing libgtk-3-dev leads to configure syntax error. 2020-04-27 12:21:19 +02:00
Michael Schumacher 0108d7e214 Change order of CFLAGS for SSE tests
This makes the configure tests for SSE support fail if CFLAGS specify -mno-sse2 or/and -mno-sse4.1.
Fixes #4363.
2020-03-17 18:49:46 +00:00
Ell 51e4549d5c configure.ac: fix last commit
Removed a little bit too much.
2020-03-08 13:10:34 +02:00
Ell 52ae7d180a configure.ac, meson: require glib >= 2.56.2
GLib 2.56.0 and 2.56.1 have a Windows-specific bug we were testing
for, so let's just bump to 2.56.2.
2020-03-08 12:28:33 +02:00
Ell 401745e62a Makefile.am, meson.build: require GEGL >= 0.4.23 2020-02-20 13:02:54 +02:00
Øyvind Kolås ab5ed1575c meson,app,autotools: depend on GEGL-0.4.22 2020-02-18 22:02:30 +01:00
Jehan f98e506712 configure, data: create/install the gimp-release file. 2020-02-14 00:56:22 +01:00
Jehan 7b5fff7861 app: now also process the build revision when checking for updates.
The idea is to be able to advertize a new revision of the same version
of GIMP. For instance, this would apply when we release a
`gimp-2-10-14-setup-3.exe` Windows installer (then we are at revision
3, provided we started at revision 0).

The revision number is obviously only relevant to a given platform and
version. Also the concept of build ID allows to differentiate various
builds for a same platform, in particular to not look at revisions of
third-party builds. The build ID can be any string. Maybe we could just
use reverse DNS build id (such as "org.gimp.GIMP_official") to identify
the official GIMP build. So in the end, we only compare revisions for an
identical (version, platform, build-id) tuple.
2020-02-06 21:47:00 +01:00
Jehan 315665592c app, configure: new --disable-check-update option at configuration.
Allows to disable the automatic update check at startup. I believe some
packagers will want such options, in particular on Linux distribution
(where they control their own release schedule and won't want GIMP to
pop new version warning up because they have been slow to update their
package).
Note that it is still possible to query version checks manually in the
about dialog, but the automatic check/popup is gone with this option.
2020-02-06 21:21:17 +01:00
Øyvind Kolås ab7c119c07 meson,app,autotools: depend on babl 0.1.74 and GEGL 0.4.20 2020-01-17 17:01:22 +01:00
Michael Natterer 4dfcffe4f7 Remove all checks for finite() and isfinite()
and simply use isfinite() everywhere, it's part of C99.
2020-01-05 16:36:18 +01:00
Jehan 506a0476f4 app: check last GIMP release from gimp.org/gimp_versions.json.
GIMP will now process the remote gimp_versions json file to look if one
is using the last version of GIMP. This initial code doesn't act up yet
on this information. This will come in further commits.

Here are the characteristics:
- Since this requires internet access, a new checkbox is available in
  the Preferences dialog, allowing to disable version checks. Note that
  it is enabled by default as it is an important security feature, but
  it has to be deactivatable.
- The remote access is done as an async operation because we don't want
  it to block the startup in any way (for whatever reason). Also it
  doesn't output errors if it fails to not be a bother (you don't
  technically need internet access for an image program).
- We don't check at every startup. At each successful check, we save a
  timestamp to prevent too frequent useless checks (I set it the timer
  to a week or more for now).
2019-12-13 17:51:44 +01:00
Jehan 73c09ebb32 app, configure: add configure option for a build id and revision.
The point will be for a packager to create a unique build ID to identify
the build or provenance. I also add a revision number so that we can
identify 2 builds from the same version/commit, same maker and platform.

It will also be used later to check for new versions (see "phone home"
feature #2584).

Separating autotools and meson commits for easy backport.
2019-12-11 21:59:11 +01:00
Jehan 6124be59b7 configure: fix typo which was breaking the build. 2019-11-13 13:25:23 +01:00
Jehan f051e6d238 Issue #4185: Plug-in “file-heif.exe” crashes exporting HEIF/HEIC.
My previous test (commit 41285813a5) was a bit misinformed. So it turns
out bug #4185 is for all platforms and the broken libheif versions are
1.5.0 and 1.5.1 only.

So my new test (platform independent) is: prefer libheif versions with
profile support, except 1.5.x; then prefer lower versions without
profile support; and only as last resort accept 1.5.x versions (but
output a warning).
2019-11-13 12:33:14 +01:00
Jehan 5da252ca18 Issue #2543: gimp doesn't open on debian stretch (libmypaint crash).
Known bug in libmypaint dependency. It has been fixed in libmypaint
1.4.0, which we cannot hard require unfortunately (Debian testing still
at 1.3.0).

Still let's make add a warning so that packagers are aware of the issue
and update when possible.
2019-11-12 17:13:05 +01:00
Jehan 41285813a5 configure: improve libheif detection and output.
Replace the "Heif >= 1.4.0" line in the summary output by a comment in
the "Heif" line explaining this is about profile support.

Also add a >= 1.6.0 test and output a warning for Windows and macOS (cf.
bug #4185).
2019-11-12 14:48:26 +01:00
Alex Samorukov 2cb0493b2f Replace finite() with isfinite() by default
This is part of the C standard also also causing warning on macOS.

(cherry picked from commit 04997fc0ae)
2019-11-07 10:13:59 +01:00
Ell d97dd6413a configure.ac: fix escaping of backslashes in compiler version string
There is one more level of unescaping...
2019-10-29 21:27:21 +02:00
Øyvind Kolås f0077265b4 configure, meson, app: depend on gegl-0.4.18 2019-10-27 01:37:24 +02:00
Ell 6b87e2f90c configure.ac: add AC_MSG_RESULT() for color-profile directory check 2019-10-26 22:22:25 +03:00
Jehan 2791328e41 configure: fix LUA test.
Bug discovered by Simon. See #3921.
The logics of the whole test for binding interpreters may still change
(or even disappear), but for now, at least make it work as expected.
2019-09-12 18:02:06 +02:00
Félix Piédallu 0792cb65f4 [devel-docs] move version file to deduplicate code 2019-09-09 18:15:13 +00:00
Øyvind Kolås fe3e945154 configure,app: depend on babl-0.1.72 2019-08-22 23:15:43 +02:00