Skip to content

Commit

Permalink
gimp3-fix-ca 0.1 pre-release (Nov 14 2024)
Browse files Browse the repository at this point in the history
tag point gimp-3.0~RC1 appeared a few days ago therefore naming this
as release 0.1 since the API is considered stable now.

configure.ac also needs checks for locale.h and setlocale for newer
distros to continue a 'use whatever available version of gettext.'.
configure.ac updated to check only for 3.0, and not 2.99 since gimp
and gimptool updated to 3.0 now.

Updated fix-ca.c to move #include <libgimp/gimp> to the top to avoid
adding an additional #include <stddefs.h> to compensate for gtk+3's
undefined size_t in several gtk+3 include files. #include <locale.h>
also added due build failure of setlocale(LC_ALL) on newer distros.

gimp3->gimp. PLUG-IN-ROLE renamed from gimp3-fix-ca to gimp-fix-ca.

Added #define d_(x) and moved several strings to static const char *
We only need one, and the char str names are a bit more descriptive.

gtk, gimp or other? Temporary revert lensX/lensY from int to double.

Imported fedora plugin-gimp-fourier rpm spec file conf% improvement.

Added tests/Makefile.am scriptfu updates that work with version RC1,
and md5sum value update due to using file-bmp-export rgb-888 instead
of prior gimp-file-save. Updates required for 'make check' to pass.

Removed .github/workflows/main.yml since it's too early or ready yet
(no downloadable gimp-3.0~RC1-dev packages available yet).
  • Loading branch information
JoesCat committed Nov 14, 2024
1 parent 35083ea commit 60e0baf
Show file tree
Hide file tree
Showing 13 changed files with 493 additions and 753 deletions.
90 changes: 0 additions & 90 deletions .github/workflows/main.yml

This file was deleted.

14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -176,30 +176,29 @@ The picture below shows (50% zoom) corrected image of the interested region.

## Download and building GIMP3-Fix-CA

To compile and install this plug-in, you will need the GIMP development package
that comes with your distribution (this needs to be 2.99.19^20240912 or later).
Then run these commands in the main directory for this project:
To compile and install this plug-in, you will need the GIMP3 RC1 version or
later. Then run these commands in the main directory for this project:
```sh
autoreconf -i
automake
./configure --prefix=/usr
make
```
You can also run 'make check' if you want, but note it takes about a minute to
process since it loads and runs `gimp-2.99 -i` without display.
process since it loads and runs `gimp-3.0 -i` without a display.

At this point, the binary fix-ca is ready to install.
For a single user, or someone without administration/root priviledges, you can
install fix-ca into your local home directory as:
```sh
gimptool-2.99 --install-bin fix-ca
gimptool --install-bin fix-ca
```
or if you have administrative/root access, you can install fix-ca for everyone
to use as:
```sh
sudo make install
```
which then installs fix-ca in /usr/lib64/gimp/2.99/plug-ins/fix-ca/
which then installs fix-ca as /usr/lib64/gimp/3.0/plug-ins/fix-ca/fix-ca
and the locale files into /usr/share/locale/??/LC_MESSAGES/gimp30-fix-ca.mo

If GIMP3 is already running in your system, exit and restart Gimp for the new
Expand Down Expand Up @@ -228,7 +227,8 @@ build files. Gimp is still in release candidate mode and bugs are getting fixed.
## Version History

GIMP3-Fix-CA
- 0.0 (May 15, 2024) Pre-release (GIMP3 >= 2.99.19^20240515). Version 0.1 will happen only after gimp-3.0 is released and the API is stable.
- 0.1 (Nov 14, 2024) Ready for GIMP3-RC1 (Release Candidate 1 - Ready for larger audience, API expected to be stable).
- 0.0 (May 15, 2024) Pre-release (GIMP3 >= 2.99.19^20240515 - API is not stable yet).

GIMP2-Fix-CA
- 4.0 (February 29, 2024) Upgraded code to use GIMP-2.10 API. Now Gimp-Fix-CA works with RGB/RGBA with precisions of 8bit, 16bit, 32bit, or double for each color of R,G,B,A. Also added Lens X/Y center and a lens centerline in the preview window. Local Language support now included for the installable Gimp-Fix-CA. This version is bumped to 4.0 since it requires GIMP-2.10.xx, and also because non-interactive scripting also requires Lateral Lens X/Y positions (default=-1,-1)
Expand Down
25 changes: 17 additions & 8 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ AC_PREREQ([2.69])
#
m4_define([fix_ca_name], [gimp3-fix-ca])
m4_define([fix_ca_major_version], [0])
m4_define([fix_ca_minor_version], [0])
m4_define([fix_ca_minor_version], [1])
m4_define([fix_ca_version],[fix_ca_major_version.fix_ca_minor_version])
m4_define([fix_ca_package_name], [gimp3-fix-ca])
m4_define([fix_ca_package_home], [https://github.com/JoesCat/gimp3-fix-ca])
Expand Down Expand Up @@ -52,8 +52,8 @@ AC_PROG_SED
AC_PROG_LN_S
AC_PROG_MKDIR_P
AC_PATH_PROG([CHMOD],[chmod],[:])
AC_CHECK_PROGS([GIMP],[gimp-3.0 gimp-2.99],[:])
AC_CHECK_PROGS([GIMPTOOL],[gimptool-3.0 gimptool-2.99],[:])
AC_CHECK_PROGS([GIMP],[gimp-3.0],[:])
AC_CHECK_PROGS([GIMPTOOL],[gimptool-3.0],[:])
AC_PATH_PROG([MD5SUM],[md5sum],[:])
AC_PATH_PROG([MSGFMT],[msgfmt],[:])
AC_PATH_PROG([MSGINIT],[msginit],[:])
Expand Down Expand Up @@ -120,12 +120,18 @@ if test "${FCA_CFLAGS}"x != x; then
fi

#--------------------------------------------------------------------------
# Check for required libraries.
# NOTE: Some distros don't have /usr/local included in the /etc/ld.so PATH,
# so, PKG_CHECK_MODULES may not find libraries you compile into /usr/local,
# therefore use AC_SEARCH_LIBS, AC_CHECK_FUNC for backup.

# Check for math.h include and math library (some OSes have -lm built-in).
have_libm=maybe
AC_CHECK_HEADER([math.h],
AC_SEARCH_LIBS([cos],[m],[have_libm=yes]))
AC_SEARCH_LIBS([cos],[m],[have_libm=yes],
AC_CHECK_FUNC([cos],[have_libm=yes])))
if test x"${have_libm}" != xyes; then
AC_MSG_FAILURE([ERROR: Please install the Math library and math.h],[1])
AC_MSG_FAILURE([ERROR: Please install the Math library and math.h],[1])
fi

# Avoid being locked to a particular gettext verion, use what's available.
Expand All @@ -135,9 +141,12 @@ AC_CHECK_FUNC([gettext],[have_gettext=yes],[have_gettext=no])
AC_CHECK_FUNC([bind_textdomain_codeset],,[have_gettext=no])
AC_CHECK_FUNC([textdomain],,[have_gettext=no])
if test x"${have_gettext}" = xno; then
AC_SEARCH_LIBS([intl],[have_gettext=yes],[
AC_MSG_ERROR([ERROR: gettext() required! Please install libintl or GETTEXT Packages.])])
AC_SEARCH_LIBS([intl],[have_gettext=yes],[
AC_MSG_ERROR([ERROR: gettext() required! Please install libintl or GETTEXT Packages.])])
fi
AC_CHECK_HEADER([locale.h],
AC_CHECK_FUNC([setlocale],,[
AC_MSG_ERROR([ERROR: setlocale() required! Please install setlocale packages.])]))
GETTEXT_PACKAGE=gimp30-fix-ca
AC_SUBST(GETTEXT_PACKAGE)
AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE", [The gettext translation domain.])
Expand Down Expand Up @@ -185,7 +194,7 @@ CPPFLAGS="${CPPFLAGS} AS_ESCAPE([-I${top_builddir}]) AS_ESCAPE([-I${top_srcdir}]
AC_SUBST([CPPFLAGS],["${CPPFLAGS}"])

#--------------------------------------------------------------------------
# Enable debug_time mode
# Enable debug_time mode, shows runtime and various printf on command-line.
AC_ARG_ENABLE([debugtime],
[AS_HELP_STRING([--enable-debugtime],
[Enable debugging time printf mode on commandline @<:@default=no@:>@])],
Expand Down
Loading

0 comments on commit 60e0baf

Please sign in to comment.