git: b22706c0656c - main - graphics/rawstudio: try to unbreak against upcoming libxml2 update

From: Alexey Dokuchaev <danfe_at_FreeBSD.org>
Date: Wed, 28 Aug 2024 13:38:19 UTC
The branch main has been updated by danfe:

URL: https://cgit.FreeBSD.org/ports/commit/?id=b22706c0656c9f6b49a761712115875758fc4511

commit b22706c0656c9f6b49a761712115875758fc4511
Author:     Alexey Dokuchaev <danfe@FreeBSD.org>
AuthorDate: 2024-08-28 13:36:42 +0000
Commit:     Alexey Dokuchaev <danfe@FreeBSD.org>
CommitDate: 2024-08-28 13:36:42 +0000

    graphics/rawstudio: try to unbreak against upcoming libxml2 update
    
    Hence undeprecate the port and assume its maintainership.
    
    Obtained from:  https://github.com/sergiomb2/rawstudio/commit/c002cba
    PR:             279964
---
 graphics/rawstudio/Makefile                   |   5 +-
 graphics/rawstudio/files/patch-libxml2-2.12.7 | 100 ++++++++++++++++++++++++++
 2 files changed, 101 insertions(+), 4 deletions(-)

diff --git a/graphics/rawstudio/Makefile b/graphics/rawstudio/Makefile
index 7cbb22645843..3e1580c4dc27 100644
--- a/graphics/rawstudio/Makefile
+++ b/graphics/rawstudio/Makefile
@@ -4,15 +4,12 @@ PORTREVISION=	26
 CATEGORIES=	graphics
 MASTER_SITES=	http://rawstudio.org/files/release/
 
-MAINTAINER=	ports@FreeBSD.org
+MAINTAINER=	danfe@FreeBSD.org
 COMMENT=	Open-source program to read and manipulate RAW photo images
 WWW=		https://rawstudio.org/
 
 LICENSE=	GPLv2+
 
-DEPRECATED=	Abandonware, fails to build with libxml2 2.13+ (PR 279964). Consider migrating to graphics/rawtherapee
-EXPIRATION_DATE=2024-08-31
-
 BUILD_DEPENDS=	${LOCALBASE}/include/fftw3.h:math/fftw3
 LIB_DEPENDS=	libcurl.so:ftp/curl \
 		liblcms.so:graphics/lcms \
diff --git a/graphics/rawstudio/files/patch-libxml2-2.12.7 b/graphics/rawstudio/files/patch-libxml2-2.12.7
new file mode 100644
index 000000000000..39256d3688a5
--- /dev/null
+++ b/graphics/rawstudio/files/patch-libxml2-2.12.7
@@ -0,0 +1,100 @@
+--- librawstudio/rs-curve.c
++++ librawstudio/rs-curve.c
+@@ -21,6 +21,7 @@
+ #include <rawstudio.h>
+ #include <math.h>
+ #include <libxml/encoding.h>
++#include <libxml/parser.h>
+ #include <libxml/xmlwriter.h>
+ #include <string.h> /* memset() */
+ 
+--- librawstudio/rs-lens-db.c
++++ librawstudio/rs-lens-db.c
+@@ -19,6 +19,7 @@
+ 
+ #include <rawstudio.h>
+ #include <libxml/encoding.h>
++#include <libxml/parser.h>
+ #include <libxml/xmlwriter.h>
+ #include "config.h"
+ #include "rs-lens-db.h"
+--- librawstudio/rs-lens-fix.c
++++ librawstudio/rs-lens-fix.c
+@@ -19,6 +19,7 @@
+ 
+ #include <rawstudio.h>
+ #include <libxml/encoding.h>
++#include <libxml/tree.h>
+ #include "config.h"
+ 
+ static GHashTable *lens_fix_hash_table;
+--- librawstudio/rs-library.c
++++ librawstudio/rs-library.c
+@@ -60,6 +60,7 @@
+ #include "gettext.h"
+ #include "rs-debug.h"
+ #include <libxml/encoding.h>
++#include <libxml/parser.h>
+ #include <libxml/xmlwriter.h>
+ #include <sqlite3.h>
+ 
+--- librawstudio/rs-metadata.c
++++ librawstudio/rs-metadata.c
+@@ -21,6 +21,7 @@
+ #include <glib/gstdio.h> /* g_unlink() */
+ #include <config.h>
+ #include <libxml/encoding.h>
++#include <libxml/parser.h>
+ #include <libxml/xmlwriter.h>
+ #include "gettext.h"
+ 
+--- librawstudio/rs-profile-camera.c
++++ librawstudio/rs-profile-camera.c
+@@ -20,6 +20,7 @@
+ #include <glib-2.0/glib.h>
+ #include "config.h"
+ #include <libxml/encoding.h>
++#include <libxml/parser.h>
+ #include <libxml/xmlwriter.h>
+ #include "rs-utils.h"
+ 
+--- src/rs-batch.c
++++ src/rs-batch.c
+@@ -23,6 +23,7 @@
+ #include <gtk/gtk.h>
+ #include <config.h>
+ #include <libxml/encoding.h>
++#include <libxml/parser.h>
+ #include <libxml/xmlwriter.h>
+ #include "application.h"
+ #include "rs-batch.h"
+--- src/rs-cache.c
++++ src/rs-cache.c
+@@ -20,6 +20,7 @@
+ #include <rawstudio.h>
+ #include <glib.h>
+ #include <libxml/encoding.h>
++#include <libxml/parser.h>
+ #include <libxml/xmlwriter.h>
+ #include "application.h"
+ #include "rs-cache.h"
+--- src/rs-camera-db.c
++++ src/rs-camera-db.c
+@@ -20,6 +20,7 @@
+ #include "config.h"
+ #include "gettext.h"
+ #include <libxml/encoding.h>
++#include <libxml/parser.h>
+ #include <libxml/xmlwriter.h>
+ #include "rs-camera-db.h"
+ #include "rs-photo.h"
+--- src/rs-store.c
++++ src/rs-store.c
+@@ -22,6 +22,7 @@
+ #include <glib/gprintf.h>
+ #include <config.h>
+ #include <libxml/encoding.h>
++#include <libxml/parser.h>
+ #include <libxml/xmlwriter.h>
+ #include <glib.h>
+ #include <math.h>