freebsd-ports/archivers/dzip/Makefile
Muhammad Moinur Rahman 95274bf4f9 */*: Fix build with llvm16 on 13.2-STABLE
As like as HEAD(14.0-RELEASE) llvm16 was merged in base for 13.2-STABLE
with the OSVERSION 1302507.

- Utilize USE_CXXSTD=c++14 or similar solution where applicable
- Update conditionals to addtionally check for OSVERSION greater than
  1302507 and less than 1400000

Approved by:	portmgr (blanket)
Sponsored by:	The FreeBSD Foundation
2023-07-26 02:48:20 +02:00

48 lines
1.3 KiB
Makefile

PORTNAME= dzip
PORTVERSION= 2.9
CATEGORIES= archivers games
MASTER_SITES= http://speeddemosarchive.com/dzip/
DISTNAME= dz${PORTVERSION:S/.//g}src
MAINTAINER= danfe@FreeBSD.org
COMMENT= File compression utility specializing in Quake demo compression
WWW= https://speeddemosarchive.com/dzip/
LICENSE= ZLIB
USES= cpe dos2unix zip
CPE_VENDOR= evan_wagner
NO_WRKSUBDIR= yes
MAKEFILE= ${WRKSRC}/Makefile.linux
MAKE_ARGS= CC="${CC}" CFLAGS="${CFLAGS}"
ALL_TARGET= ${PORTNAME}
PLIST_FILES= bin/${PORTNAME}
PORTDOCS= Readme
OPTIONS_DEFINE= DOCS
.include <bsd.port.options.mk>
.if ${OPSYS} == FreeBSD && ( ${OSVERSION} >= 1400091 || ( ${OSVERSION} >= 1302507 && ${OSVERSION} < 1400000 ))
CFLAGS+= -Wno-error=incompatible-function-pointer-types
.endif
post-extract: .SILENT
${REINPLACE_CMD} -e 's/ifdef BIG_ENDIAN/if BYTE_ORDER == BIG_ENDIAN/' \
-e 's/ifndef BIG_ENDIAN/if BYTE_ORDER == LITTLE_ENDIAN/' \
${WRKSRC}/dzip.h ${WRKSRC}/conmain.c
${REINPLACE_CMD} -e '4s,^,#include <machine/endian.h>,' \
${WRKSRC}/dzip.h
${REINPLACE_CMD} -e '21d;23d' ${WRKSRC}/dzipcon.h
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${STAGEDIR}/${PREFIX}/bin
do-install-DOCS-on:
@${MKDIR} ${STAGEDIR}${DOCSDIR}
${INSTALL_DATA} ${PORTDOCS:S,^,${WRKSRC}/,} ${STAGEDIR}${DOCSDIR}
.include <bsd.port.mk>