Skip to content

Commit

Permalink
graphics/fotoxx: the port had been updated to version 21.60
Browse files Browse the repository at this point in the history
This includes trimming MASTER_SITES, adjusting the LICENSE,
amending LIB_DEPENDS, USES, USE_GNOME, and fixing a bunch of
disgusting linuxisms.
  • Loading branch information
Alexey Dokuchaev authored and Alexey Dokuchaev committed Dec 25, 2021
1 parent dc123a0 commit 6ba8007
Show file tree
Hide file tree
Showing 11 changed files with 305 additions and 168 deletions.
36 changes: 21 additions & 15 deletions graphics/fotoxx/Makefile
Original file line number Diff line number Diff line change
@@ -1,43 +1,49 @@
# Created by: Rod Person <rodperson@rodperson.com>

PORTNAME= fotoxx
PORTVERSION= 15.05
PORTVERSION= 21.60
CATEGORIES= graphics
MASTER_SITES= http://freebsd.nsu.ru/distfiles/ \
http://fossies.org/linux/misc/legacy/ \
http://www.kornelix.com/uploads/1/3/0/3/13035936/
MASTER_SITES= https://kornelix.net/downloads/downloads/

MAINTAINER= danfe@FreeBSD.org
COMMENT= Application to organize and edit image collections

LICENSE= GPLv3
LICENSE= GPLv3+

LIB_DEPENDS= libtiff.so:graphics/tiff
LIB_DEPENDS= libchamplain-gtk-0.12.so:graphics/libchamplain \
libclutter-gtk-1.0.so:graphics/clutter-gtk3 \
liblcms2.so:graphics/lcms2 \
libpng.so:graphics/png \
libtiff.so:graphics/tiff
RUN_DEPENDS= xdg-open:devel/xdg-utils \
exiftool:graphics/p5-Image-ExifTool \
ufraw-batch:graphics/ufraw

USES= desktop-file-utils gmake gnome pkgconfig
USE_GNOME= gtk30
USES= desktop-file-utils gmake gnome jpeg pkgconfig
USE_GNOME= cairo glib20 gdkpixbuf2 gtk30
ALL_TARGET= fotoxx

WRKSRC= ${WRKDIR}/${PORTNAME}

PORTDOCS= *
PORTDATA= *
PLIST_FILES= bin/fotoxx \
man/man1/fotoxx.1.gz \
share/appdata/fotoxx.appdata.xml \
share/man/man1/fotoxx.1.gz \
share/applications/fotoxx.desktop

OPTIONS_DEFINE= DOCS

post-patch:
@${REINPLACE_CMD} -e \
's|-ggdb|| ; \
s|-rdynamic|-Wl,-export-dynamic| ; \
s|share/man|man| ; \
s|-lpthread|-lexecinfo|' ${WRKSRC}/Makefile
's,= thread,= cartoon::thread,' ${WRKSRC}/f.effects.cc
@${REINPLACE_CMD} -e \
'/#include <sys\/prctl\.h>/d' ${WRKSRC}/f.meta.cc
@${REINPLACE_CMD} -e \
's,pidof,pgrep -d\\\\ ,' ${WRKSRC}/fotoxx.cc
@${REINPLACE_CMD} -e \
'/#include/s,wait\.h,sys/&,' ${WRKSRC}/fotoxx.h
@${REINPLACE_CMD} -e \
's|/usr/share/fotoxx|${DATADIR}|' ${WRKSRC}/desktop
's|/usr/share/fotoxx|${DATADIR}|' ${WRKSRC}/fotoxx.desktop

post-install:
${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/fotoxx
Expand Down
6 changes: 3 additions & 3 deletions graphics/fotoxx/distinfo
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
TIMESTAMP = 1430473829
SHA256 (fotoxx-15.05.tar.gz) = 65567adc86087a3a8acdebcb0f15ec299cf690a869129825e3d32da7e50c4604
SIZE (fotoxx-15.05.tar.gz) = 3573278
TIMESTAMP = 1634502156
SHA256 (fotoxx-21.60.tar.gz) = 2973e967b04b79ed85ec4dc9ed77d78cd5881340dfc976a61ba85dcbeb4b0dfd
SIZE (fotoxx-21.60.tar.gz) = 8679841
45 changes: 45 additions & 0 deletions graphics/fotoxx/files/patch-Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
--- Makefile.orig 2021-10-17 20:02:26 UTC
+++ Makefile
@@ -1,40 +1,12 @@
# fotoxx Makefile
-#
-# export CXX=g++ gnu compiler
-# export CXX=clang++ clang compiler
-# export DEBUG=x debug build with address checking

-ifeq ($(CXX), clang++) # CLANG
- ifdef DEBUG
- CXXFLAGS += -Wall -g -O0 -fsanitize=address -Wno-stringop-truncation
- LDFLAGS += -fsanitize=address
- else
- CXXFLAGS += -Wall -g -O2
- endif
-else # GCC
- ifdef DEBUG
- CXXFLAGS += -Wall -g -rdynamic -O0 -fsanitize=address -Wno-format-truncation -Wno-stringop-truncation
- LDFLAGS += -fsanitize=address
- else
- CXXFLAGS += -Wall -g -rdynamic -O2 -Wno-format-truncation -Wno-stringop-truncation
- endif
-endif
-
PKG_CONFIG ?= pkg-config

CFLAGS = $(CXXFLAGS) $(CPPFLAGS) -c \
- `$(PKG_CONFIG) --cflags gtk+-3.0` \
- -I/usr/include/clutter-1.0/ \
- -I/usr/include/clutter-gtk-1.0/ \
- -I/usr/include/champlain-gtk-0.12/ \
- -I/usr/include/champlain-0.12/ \
- -I/usr/include/libchamplain-gtk-0.12/ \
- -I/usr/include/libchamplain-0.12/ \
- -I/usr/include/cogl/ \
- -I/usr/include/json-glib-1.0/ \
+ `$(PKG_CONFIG) pkgconf --cflags champlain-gtk-0.12`

LIBS = `$(PKG_CONFIG) --libs gtk+-3.0` \
- -lrt -lpthread -llcms2 -ltiff -lpng -ljpeg \
+ -lrt -lexecinfo -llcms2 -ltiff -lpng -ljpeg \
-lclutter-1.0 -lclutter-gtk-1.0 -lchamplain-0.12 -lchamplain-gtk-0.12

ALLFILES = fotoxx.o f.widgets.o f.file.o f.gallery.o f.albums.o f.area.o f.meta.o \
11 changes: 0 additions & 11 deletions graphics/fotoxx/files/patch-f.combine.cc

This file was deleted.

29 changes: 29 additions & 0 deletions graphics/fotoxx/files/patch-f.enhance.cc
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
--- f.enhance.cc.orig 2021-10-17 20:02:26 UTC
+++ f.enhance.cc
@@ -224,7 +224,7 @@ void m_editBD(GtkWidget *, cchar *menu)
EFeditBD.Farea = 2; // select area usable
EFeditBD.Frestart = 1; // restart allowed
EFeditBD.Fscript = 1; // scripting supported
- EFeditBD.threadfunc = thread;
+ EFeditBD.threadfunc = editBD_names::thread;
if (! edit_setup(EFeditBD)) return; // setup edit

/***
@@ -590,7 +590,7 @@ void m_flattenBD(GtkWidget *, cchar *menu)
EFflattenBD.Frestart = 1; // restartable
EFflattenBD.Fpaintedits = 1; // use with paint edits OK
EFflattenBD.Fscript = 1; // scripting supported
- EFflattenBD.threadfunc = thread;
+ EFflattenBD.threadfunc = flattenBD_names::thread;
if (! edit_setup(EFflattenBD)) return; // setup edit
Eww = E0pxm->ww;
@@ -1067,7 +1067,7 @@ void flattenBDfunc(int _NZ, int _flatten, int _deband1
EFflattenBD.menufunc = m_flattenBD;
EFflattenBD.Farea = 2; // select area usable
EFflattenBD.Frestart = 1; // restartable
- EFflattenBD.threadfunc = thread;
+ EFflattenBD.threadfunc = flattenBD_names::thread;
if (! edit_setup(EFflattenBD)) return; // setup edit
26 changes: 18 additions & 8 deletions graphics/fotoxx/files/patch-f.file.cc
Original file line number Diff line number Diff line change
@@ -1,10 +1,20 @@
--- f.file.cc.orig 2015-05-01 09:40:38 UTC
--- f.file.cc.orig 2021-10-17 20:02:26 UTC
+++ f.file.cc
@@ -74,6 +74,7 @@

#define EX extern // disable extern declarations
#include "fotoxx.h" // (variables in fotoxx.h are refs)
+#include <sys/wait.h>

/**************************************************************************/
@@ -3687,13 +3687,17 @@ int find_imagefiles(cchar *folder, int flags, char **&

if (flags & 1) Fimages = 1;
if (flags & 2) Fthumbs = 1;
+#ifdef GLOB_PERIOD
if (flags & 4) globflags += GLOB_PERIOD;
+#endif
if (flags & 8) Fdirs = 1;
if (flags & 16) Frecurse = 1;
if (flags & 32) Fnolinks = 1;

+#ifdef GLOB_ONLYDIR
if (Fdirs && ! Fimages && ! Fthumbs)
globflags += GLOB_ONLYDIR;
+#endif

globdata.gl_pathc = 0; // glob() setup
globdata.gl_offs = 0;
50 changes: 0 additions & 50 deletions graphics/fotoxx/files/patch-f.metadata.cc

This file was deleted.

11 changes: 0 additions & 11 deletions graphics/fotoxx/files/patch-f.repair.cc

This file was deleted.

51 changes: 0 additions & 51 deletions graphics/fotoxx/files/patch-fotoxx-15.05.cc

This file was deleted.

Loading

0 comments on commit 6ba8007

Please sign in to comment.