audio/gramofile: Document ncurses requirement and honor CFLAGS
While here, add DragonFly support
This commit is contained in:
parent
4f4cbf3064
commit
576f0b67bb
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=426382
@ -17,7 +17,7 @@ COMMENT= Audio recording and tick/scratch reduction for e.g. vinyl records
|
||||
LIB_DEPENDS= libfftw.so:math/fftw
|
||||
|
||||
ALL_TARGET= gramofile
|
||||
USES= gmake perl5
|
||||
USES= alias gmake ncurses perl5
|
||||
USE_CSTD= gnu89
|
||||
MAKE_ARGS= CC="${CC}" \
|
||||
CXX="${CXX}" \
|
||||
@ -35,11 +35,12 @@ post-patch:
|
||||
for i in `${LS} ${FILESDIR}/post-patch-* |${SED} /.orig$$/d`; do \
|
||||
${PATCH} -d ${WRKSRC} --forward --quiet <$$i ;\
|
||||
done
|
||||
.for file in bplay.c sndfunc.c
|
||||
@${SED} -e 's,machine/soundcard.h,sys/soundcard.h,' < \
|
||||
${WRKSRC}/bplaysrc/${file} > ${WRKSRC}/bplaysrc/${file}.new
|
||||
@${MV} ${WRKSRC}/bplaysrc/${file}.new ${WRKSRC}/bplaysrc/${file}
|
||||
.endfor
|
||||
${REINPLACE_CMD} -e "s@-lncurses@-L${LOCALBASE}/lib -lncurses@g" \
|
||||
-e "s|CFLAGS =|CFLAGS +=|" \
|
||||
${WRKSRC}/bplaysrc/Makefile
|
||||
${REINPLACE_CMD} -e 's,machine/soundcard.h,sys/soundcard.h,' \
|
||||
${WRKSRC}/bplaysrc/bplay.c \
|
||||
${WRKSRC}/bplaysrc/sndfunc.c
|
||||
|
||||
do-install:
|
||||
${INSTALL_PROGRAM} ${WRKSRC}/gramofile ${WRKSRC}/bplay_gramo \
|
||||
|
18
audio/gramofile/files/patch-bplaysrc_shmbuf.c
Normal file
18
audio/gramofile/files/patch-bplaysrc_shmbuf.c
Normal file
@ -0,0 +1,18 @@
|
||||
--- bplaysrc/shmbuf.c.orig 2000-03-27 21:38:56 UTC
|
||||
+++ bplaysrc/shmbuf.c
|
||||
@@ -142,6 +142,7 @@ void init_shm(void)
|
||||
if(shmctl(shmid2, IPC_RMID, NULL))
|
||||
ErrDie("shmctl");
|
||||
|
||||
+#ifndef __DragonFly__
|
||||
#if USEBUFFLOCK
|
||||
/* Ok, go root to lock the buffers down */
|
||||
if(setreuid(geteuid(), getuid()) == -1)
|
||||
@@ -173,6 +174,7 @@ void init_shm(void)
|
||||
}
|
||||
|
||||
#endif
|
||||
+#endif
|
||||
/* Set up the appropriate number of semaphore blocks */
|
||||
numsemblks = numbuffs/SEMMSL;
|
||||
if((numsemblks * SEMMSL) < numbuffs)
|
Loading…
Reference in New Issue
Block a user