1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-25 09:34:11 +00:00

print/magicfilter: Update version 2.3.h=>2.3.i

- Switch MASTER_SITES to GH
- Adopt port
- Add LICENSE BSD3CLAUSE
- Unbreak on HEAD
- Refresh patches

Changelog: https://github.com/Orc/magicfilter/releases/tag/v2.3.i
This commit is contained in:
Muhammad Moinur Rahman 2023-05-16 16:29:22 +02:00
parent 41146fe76c
commit 2d2f4f4462
9 changed files with 20 additions and 99 deletions

View File

@ -1,14 +1,20 @@
PORTNAME= magicfilter
PORTVERSION= 2.3.h
PORTREVISION= 9
DISTVERSIONPREFIX= v
DISTVERSION= 2.3.i
CATEGORIES= print
MASTER_SITES= http://www.pell.portland.or.us/~orc/Code/magicfilter/
MAINTAINER= ports@FreeBSD.org
MAINTAINER= bofh@FreeBSD.org
COMMENT= Customizable, extensible automatic printer filter
WWW= https://www.pell.portland.or.us/~orc/Code/magicfilter/
LICENSE= BSD3CLAUSE
BUILD_DEPENDS= ${LOCALBASE}/lib/libmagic.so:sysutils/file
RUN_DEPENDS= ${LOCALBASE}/lib/libmagic.so:sysutils/file
USES= ghostscript
USE_GITHUB= yes
GH_ACCOUNT= Orc
HAS_CONFIGURE= yes
CONFIGURE_SCRIPT= configure.sh
@ -18,9 +24,10 @@ CONFIGURE_ARGS+= --prefix=${PREFIX} \
--use-fifo
CONFIGURE_ENV+= LOCALBASE=${LOCALBASE}
.if exists(${LOCALBASE}/lib/libmagic.so)
BUILD_DEPENDS+= ${LOCALBASE}/lib/libmagic.so:sysutils/file
RUN_DEPENDS+= ${LOCALBASE}/lib/libmagic.so:sysutils/file
.include <bsd.port.pre.mk>
.if ${OPSYS} == FreeBSD && ${OSVERSION} >= 1400079
CFLAGS+= -Wno-error=int-conversion
.endif
.include <bsd.port.mk>
.include <bsd.port.post.mk>

View File

@ -1,2 +1,3 @@
SHA256 (magicfilter-2.3.h.tar.gz) = 8d6a3e3e68a16aa43682cdd77e8a9d28635eef4ea5e8dcf558e9a6fb88f8642c
SIZE (magicfilter-2.3.h.tar.gz) = 161929
TIMESTAMP = 1684246289
SHA256 (Orc-magicfilter-v2.3.i_GH0.tar.gz) = 39b1e0764c6318d2e90c20b58b135d9eb29facd9b8055c8b1c4766a731d20afe
SIZE (Orc-magicfilter-v2.3.i_GH0.tar.gz) = 120443

View File

@ -1,5 +1,5 @@
--- Makefile.in.orig 2014-07-07 11:57:40.878417316 +0800
+++ Makefile.in 2014-07-07 11:59:03.900407189 +0800
--- Makefile.in.orig 2009-11-23 03:45:02 UTC
+++ Makefile.in
@@ -44,46 +44,46 @@ cfmagic: file/magic
@MAKE_MAGIC@ magic

View File

@ -1,21 +0,0 @@
--- configure.sh.orig Thu Apr 27 10:32:23 2006
+++ configure.sh Thu Apr 27 10:33:46 2006
@@ -1061,6 +1061,7 @@
AC_LIBS="$AC_LIBS -lz"
unset BUILD_MAGIC
fi
+ unset BUILD_MAGIC
if [ "$BUILD_MAGIC" ]; then
case $ac_os in
@@ -1106,8 +1107,8 @@
AC_SUB CFMAGIC "cfmagic"
else
AC_SUB LIBMAGIC ""
- AC_SUB MAGIC_HEADER ""
- AC_SUB MAGIC_LIB ""
+ AC_SUB MAGIC_HEADER "-I${LOCALBASE}/include"
+ AC_SUB MAGIC_LIB "-L${LOCALBASE}/lib -Wl,-rpath -Wl,${LOCALBASE}/lib"
AC_SUB MAKE_MAGIC ":"
AC_SUB CFMAGIC ""
fi

View File

@ -1,11 +0,0 @@
--- fe.c.orig 2003-05-09 18:27:15 UTC
+++ fe.c
@@ -128,7 +128,7 @@ be(int input, int output)
/* read rules
*/
- while ( (r = getline(f)) != 0) {
+ while ( (r = get_line(f)) != 0) {
rulecount++;
if (tail) {
tail->next = r;

View File

@ -1,12 +0,0 @@
diff -ur file/file.c file/file.c
--- file/file.c Sun Dec 5 01:32:50 2004
+++ file/file.c Sun Dec 5 01:34:31 2004
@@ -33,7 +33,7 @@
#include <string.h>
#include <errno.h>
#include <sys/param.h> /* for MAXPATHLEN */
-#include <malloc.h>
+#include <stdlib.h>
extern int getopt();
extern int optind;

View File

@ -1,12 +0,0 @@
diff -ur getaline.c getaline.c
--- getaline.c Sun Dec 5 01:32:50 2004
+++ getaline.c Sun Dec 5 01:33:24 2004
@@ -27,7 +27,7 @@
* THE POSSIBILITY OF SUCH DAMAGE.
*/
#include <stdio.h>
-#include <malloc.h>
+#include <stdlib.h>
#include "magicfilter.h"

View File

@ -1,20 +0,0 @@
--- getline.c.orig 2002-12-14 09:02:26 UTC
+++ getline.c
@@ -34,7 +34,7 @@
* /pattern/ action[/hint/] [arg {arg ...}]
*/
-#include <malloc.h>
+#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#include "rule.h"
@@ -175,7 +175,7 @@ vis(FILE *output, unsigned char *s)
* getline() gets a rule off the input stream
*/
struct rule *
-getline(FILE *input)
+get_line(FILE *input)
{
static char *bfr = 0; /* a buffer for reading lines into */
static int buflen = 0; /* size of that buffer */

View File

@ -1,11 +0,0 @@
--- rule.h.orig 2002-07-11 23:23:43 UTC
+++ rule.h
@@ -55,7 +55,7 @@ struct rule {
struct rule *next; /* next rule in the chain */
} ;
-extern struct rule *getline(FILE *);
+extern struct rule *get_line(FILE *);
extern struct rule *rules;
char * action_p(enum rule_action);