- Fix under clang11

- add LICENSE
This commit is contained in:
Diane Bruce 2020-08-26 21:03:26 +00:00
parent 5b2ce80677
commit 51b30f36f9
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=546300
7 changed files with 63 additions and 14 deletions

View file

@ -11,21 +11,22 @@ DISTNAME= ${PORTNAME}-${PORTVERSION:S/^0.//}
MAINTAINER= hamradio@FreeBSD.org
COMMENT= Receive faxes using sound card and radio
LICENSE= GPLv2
LIB_DEPENDS= libXaw3d.so:x11-toolkits/Xaw3d
PLIST_FILES= bin/acfax
USES= imake xorg
WRKSRC= ${WRKDIR}/${PORTNAME}
USES= imake xorg
USE_XORG= x11 xext xmu xt sm ice
PLIST_FILES= bin/acfax
post-extract:
@${TOUCH} ${WRKSRC}/acfax.man
post-patch:
@${REINPLACE_CMD} -e 's|setup_fax(120, 288|setup_fax(120, 576|' \
${WRKSRC}/acfax.c
@${REINPLACE_CMD} -e 's|ixoc = 288|ixoc = 576|' ${WRKSRC}/fax_funcs.c
@${REINPLACE_CMD} -e 's|regex.h|gnuregex.h|' ${WRKSRC}/RegExp.h
@${REINPLACE_CMD} -e 's| -O2 -Wall||g ; \
s|-lm|-lm -lgnuregex|' ${WRKSRC}/Imakefile

View file

@ -1,5 +1,5 @@
--- RegExp.c.old Sun Feb 10 05:33:07 2002
+++ RegExp.c Sun Feb 10 05:33:24 2002
--- RegExp.c.orig 1995-07-08 18:20:49 UTC
+++ RegExp.c
@@ -23,7 +23,6 @@
*/

View file

@ -1,6 +1,15 @@
--- acfax.c.orig 2011-06-30 14:39:10.000000000 -0400
+++ acfax.c 2011-06-30 14:39:23.000000000 -0400
@@ -739,7 +739,7 @@
--- acfax.c.orig 1998-10-06 21:32:35 UTC
+++ acfax.c
@@ -108,7 +108,7 @@ struct prginfo {
String sizedesc;
} prg_info;
-Display *dpy; /* the X-Display to use */
+extern Display *dpy; /* the X-Display to use */
Screen *scr; /* screen of the display */
Pixmap cpxmap; /* The "backing store" for the canvas-widget */
GC cgc; /* GC for XPutImage from horimage/verimage to cpxmap */
@@ -739,7 +739,7 @@ void quit_cb(Widget w, XtPointer client_data, XtPointe
exit(0);
}
@ -9,3 +18,12 @@
{
int i;
Pixel respix[20];
@@ -795,7 +795,7 @@ void main(int argc, char **argv)
mode_notify = op_changed;
/* that's a hard one, but should set up all things right.... */
XtVaGetValues(canvas, XtNwidth, &wid, XtNheight, &hei, NULL);
- setup_fax(120, 288, (FAX_CNOR | FAX_CUNFL | FAX_CROT0 |
+ setup_fax(120, 576, (FAX_CNOR | FAX_CUNFL | FAX_CROT0 |
FAX_LEF2RIG | FAX_TOP2BOT | FAX_HOR | FAX_PBLK | FAX_GRAY),
toplevel, (unsigned)wid, (unsigned)hei, 500, (MOD_FM | FIL_MIDL));
aptstart = 300;

View file

@ -1,5 +1,5 @@
--- fax_funcs.c.orig Sat Jun 8 00:39:02 2002
+++ fax_funcs.c Sat Jun 8 00:39:08 2002
--- fax_funcs.c.orig 1998-10-11 16:34:37 UTC
+++ fax_funcs.c
@@ -37,6 +37,8 @@
#include "widgets.h"
#include "fax_funcs.h"
@ -9,3 +9,21 @@
/* some variables that are allowed to be global */
int lpm; /* lines per minute */
int ixoc; /* number of pixels of one scan-line / PI */
@@ -96,7 +98,7 @@ char *mod_end; /* pointer to first byte behind end of
FILE *fsfile; /* file pointer of current save-file */
char faxsavename[256]; /* current name of save-file */
char *saveline; /* storage for 1 image-line in save_func */
-XtAppContext mainapp; /* main app.context (needed for interv.timer) */
+extern XtAppContext mainapp; /* main app.context (needed for interv.timer) */
XtIntervalId chstime; /* for the repetitive called background function */
XtInputId dspxid = 0; /* for the background function when using select() */
XEvent event; /* event needed to form the XtAppMainLoop */
@@ -117,7 +119,7 @@ void init_fax(void)
if (fax_inited) return;
fprintf(stderr, "initializing FAX procedures and alloc'ing core-space\n");
lpm = 120;
- ixoc = 288;
+ ixoc = 576;
devi = 400;
mod_mode = MOD_FM | FIL_MIDL;
dmaxval = 63;

View file

@ -1,5 +1,5 @@
--- mod_demod.c.orig Sat Jun 8 00:38:29 2002
+++ mod_demod.c Sat Jun 8 00:38:41 2002
--- mod_demod.c.orig 1998-07-08 16:32:02 UTC
+++ mod_demod.c
@@ -29,6 +29,8 @@
#include <unistd.h>
#include "mod_demod.h"

View file

@ -0,0 +1,11 @@
--- widgets.c.orig 2020-08-26 20:41:16 UTC
+++ widgets.c
@@ -101,7 +101,7 @@ Pixmap px_horiz,
px_middle,
px_wide;
-XtTranslations txt_trans; /* translations for numeric entries */
+extern XtTranslations txt_trans; /* translations for numeric entries */
XtTranslations name_trans; /* translations for name-entry */
static void fchs_cb(Widget, XtPointer, XtPointer);

View file

@ -1,2 +1,3 @@
amateur FAX receiving software for Linux / X11
acfax is a program to decode faxes off a radio. It features on-the-fly
image adjustments and control over a wide array of receiving options.