The below diff:
- moves HOMEPAGE and MASTER_SITES to dockapps.net, since it was not reachable. The distfile checksum is the same. - removes an hardcoded path to madplay; we could move to mpg123 but i did not want to include a breaking change - fixes missing includes spotted by clang - fixes the build with -fno-common (from Gentoo [0]) It builds and works fine on macppc and amd64. OK? Charlène. [0] https://gitweb.gentoo.org/repo/gentoo.git/tree/x11-plugins/wmmp3/files/wmmp3-0.12-fno-common.patch Index: Makefile =================================================================== RCS file: /cvs/ports/audio/wmmp3/Makefile,v retrieving revision 1.24 diff -u -p -u -p -r1.24 Makefile --- Makefile 12 Jul 2019 20:43:42 -0000 1.24 +++ Makefile 4 Feb 2021 21:02:24 -0000 @@ -3,17 +3,17 @@ COMMENT= wm-dockapp; front end for an mp3 player DISTNAME= wmmp3-0.12 -REVISION= 4 +REVISION= 5 CATEGORIES= audio x11 x11/windowmaker -HOMEPAGE= http://www.dotfiles.com/software/wmmp3/ +HOMEPAGE= https://www.dockapps.net/wmmp3 # GPL PERMIT_PACKAGE= Yes WANTLIB= X11 Xext Xpm c -MASTER_SITES= ${HOMEPAGE} +MASTER_SITES= https://www.dockapps.net/download/ RUN_DEPENDS= audio/madplay @@ -23,6 +23,9 @@ CONFIGURE_STYLE= gnu SAMPLE_DIR= ${PREFIX}/share/examples/wmmp3 SUBST_VARS+= SAMPLE_DIR + +post-patch: + @${SUBST_CMD} ${WRKSRC}/main.c do-install: ${INSTALL_PROGRAM} ${WRKBUILD}/wmmp3 ${PREFIX}/bin Index: patches/patch-main_c =================================================================== RCS file: /cvs/ports/audio/wmmp3/patches/patch-main_c,v retrieving revision 1.2 diff -u -p -u -p -r1.2 patch-main_c --- patches/patch-main_c 4 Aug 2003 13:31:28 -0000 1.2 +++ patches/patch-main_c 4 Feb 2021 21:02:24 -0000 @@ -1,16 +1,17 @@ $OpenBSD: patch-main_c,v 1.2 2003/08/04 13:31:28 wilfried Exp $ ---- main.c.orig 2000-04-03 02:11:46.000000000 +0200 -+++ main.c 2003-08-04 15:05:48.000000000 +0200 +Index: main.c +--- main.c.orig ++++ main.c @@ -125,7 +125,7 @@ void loadconfig() errno = 0; /* set defualts in case anything fails */ - set_mpg123("/usr/local/bin/mpg123"); -+ set_mpg123("/usr/local/bin/madplay"); ++ set_mpg123("${LOCALBASE}/bin/madplay"); set_mp3ext(".mp3"); set_playlistext(".m3u"); -@@ -230,7 +230,7 @@ int check_options(int argc, char *argv[] +@@ -230,7 +230,7 @@ int check_options(int argc, char *argv[]) return option_entered; } Index: patches/patch-main_h =================================================================== RCS file: patches/patch-main_h diff -N patches/patch-main_h --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ patches/patch-main_h 4 Feb 2021 21:02:24 -0000 @@ -0,0 +1,15 @@ +$OpenBSD$ + +Add missing include + +Index: main.h +--- main.h.orig ++++ main.h +@@ -14,6 +14,7 @@ + + #define __MAIN_H__ + ++#include <ctype.h> + #include <stdio.h> + #include <stdlib.h> + #include <string.h> Index: patches/patch-mpg123ctl_h =================================================================== RCS file: patches/patch-mpg123ctl_h diff -N patches/patch-mpg123ctl_h --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ patches/patch-mpg123ctl_h 4 Feb 2021 21:02:24 -0000 @@ -0,0 +1,15 @@ +$OpenBSD$ + +Add missing include + +Index: mpg123ctl.h +--- mpg123ctl.h.orig ++++ mpg123ctl.h +@@ -14,6 +14,7 @@ + + #define __MPG123CTL__ + ++#include <ctype.h> + #include <stdio.h> + #include <unistd.h> + #include <signal.h> Index: patches/patch-wmgeneral_c =================================================================== RCS file: patches/patch-wmgeneral_c diff -N patches/patch-wmgeneral_c --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ patches/patch-wmgeneral_c 4 Feb 2021 21:02:24 -0000 @@ -0,0 +1,19 @@ +$OpenBSD$ + +Fix the build with -fno-common + +Index: wmgeneral.c +--- wmgeneral.c.orig ++++ wmgeneral.c +@@ -58,6 +58,11 @@ + /* X11 Variables */ + /*****************/ + ++Display *display; ++Window Root, iconwin, win; ++XpmIcon wmgen; ++XpmIcon wmfont; ++ + int screen; + int x_fd; + int d_depth; Index: patches/patch-wmgeneral_h =================================================================== RCS file: patches/patch-wmgeneral_h diff -N patches/patch-wmgeneral_h --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ patches/patch-wmgeneral_h 4 Feb 2021 21:02:24 -0000 @@ -0,0 +1,22 @@ +$OpenBSD$ + +Fix the build with -fno-common + +Index: wmgeneral.h +--- wmgeneral.h.orig ++++ wmgeneral.h +@@ -41,10 +41,10 @@ typedef struct { + /* Global variable */ + /*******************/ + +-Display *display; +-Window Root, iconwin, win; +-XpmIcon wmgen; +-XpmIcon wmfont; ++extern Display *display; ++extern Window Root, iconwin, win; ++extern XpmIcon wmgen; ++extern XpmIcon wmfont; + + /***********************/ + /* Function Prototypes */