wmmp3: fix the build with -fno-common
While here, fix hardcoded paths and add missing includes. OK sthen@
This commit is contained in:
parent
7b3f7d21a3
commit
67b23f746a
@ -1,19 +1,19 @@
|
||||
# $OpenBSD: Makefile,v 1.24 2019/07/12 20:43:42 sthen Exp $
|
||||
# $OpenBSD: Makefile,v 1.25 2021/02/05 15:39:14 cwen Exp $
|
||||
|
||||
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
|
||||
|
||||
@ -24,6 +24,9 @@ CONFIGURE_STYLE= gnu
|
||||
SAMPLE_DIR= ${PREFIX}/share/examples/wmmp3
|
||||
SUBST_VARS+= SAMPLE_DIR
|
||||
|
||||
pre-configure:
|
||||
@${SUBST_CMD} ${WRKSRC}/main.c
|
||||
|
||||
do-install:
|
||||
${INSTALL_PROGRAM} ${WRKBUILD}/wmmp3 ${PREFIX}/bin
|
||||
${INSTALL_DATA_DIR} ${SAMPLE_DIR}
|
||||
|
@ -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
|
||||
$OpenBSD: patch-main_c,v 1.3 2021/02/05 15:39:14 cwen Exp $
|
||||
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;
|
||||
}
|
||||
|
||||
|
15
audio/wmmp3/patches/patch-main_h
Normal file
15
audio/wmmp3/patches/patch-main_h
Normal file
@ -0,0 +1,15 @@
|
||||
$OpenBSD: patch-main_h,v 1.1 2021/02/05 15:39:14 cwen Exp $
|
||||
|
||||
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>
|
15
audio/wmmp3/patches/patch-mpg123ctl_h
Normal file
15
audio/wmmp3/patches/patch-mpg123ctl_h
Normal file
@ -0,0 +1,15 @@
|
||||
$OpenBSD: patch-mpg123ctl_h,v 1.1 2021/02/05 15:39:14 cwen Exp $
|
||||
|
||||
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>
|
19
audio/wmmp3/patches/patch-wmgeneral_c
Normal file
19
audio/wmmp3/patches/patch-wmgeneral_c
Normal file
@ -0,0 +1,19 @@
|
||||
$OpenBSD: patch-wmgeneral_c,v 1.1 2021/02/05 15:39:14 cwen Exp $
|
||||
|
||||
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;
|
22
audio/wmmp3/patches/patch-wmgeneral_h
Normal file
22
audio/wmmp3/patches/patch-wmgeneral_h
Normal file
@ -0,0 +1,22 @@
|
||||
$OpenBSD: patch-wmgeneral_h,v 1.1 2021/02/05 15:39:14 cwen Exp $
|
||||
|
||||
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 */
|
Loading…
Reference in New Issue
Block a user