Skip to content

Commit

Permalink
devel/got-portable: fix building on Linux.
Browse files Browse the repository at this point in the history
The compat <sha2.h> header provided by got-portable 0.85+ gets wrongly
included by libmd's <sha256.h>,	leading to SHA2_CTX type redefinition.
  • Loading branch information
vins committed Jul 18, 2023
1 parent 05cf9f1 commit 9860b2a
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions devel/got-portable/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.9 2023/07/06 15:18:36 vins Exp $
# $NetBSD: Makefile,v 1.10 2023/07/18 09:33:18 vins Exp $

DISTNAME= got-portable-0.90
PKGREVISION= 2
Expand All @@ -18,6 +18,8 @@ ONLY_FOR_PLATFORM+= Linux-*-*
ONLY_FOR_PLATFORM+= FreeBSD-*-*
ONLY_FOR_PLATFORM+= DragonFly-*-*

LDFLAGS+= -lmd -lbsd

USE_TOOLS+= pkg-config yacc

.include "../../mk/bsd.prefs.mk"
Expand All @@ -32,7 +34,9 @@ INSTALLATION_DIRS= bin libexec
INSTALLATION_DIRS+= ${PKGMANDIR}/man1 ${PKGMANDIR}/man5

.if ${OPSYS} == "Linux"
USE_TOOLS+= bison
post-patch:
# let libmd include the correct header.
${RM} -f ${WRKSRC}/compat/sha2.h
# compatibility macros and functions for Linux.
. include "../../devel/libbsd/buildlink3.mk"
.endif
Expand Down

0 comments on commit 9860b2a

Please sign in to comment.