head	1.38;
access;
symbols
	pkgsrc-2026Q1:1.35.0.2
	pkgsrc-2026Q1-base:1.35
	pkgsrc-2025Q4:1.34.0.6
	pkgsrc-2025Q4-base:1.34
	pkgsrc-2025Q3:1.34.0.4
	pkgsrc-2025Q3-base:1.34
	pkgsrc-2025Q2:1.34.0.2
	pkgsrc-2025Q2-base:1.34
	pkgsrc-2025Q1:1.31.0.4
	pkgsrc-2025Q1-base:1.31
	pkgsrc-2024Q4:1.31.0.2
	pkgsrc-2024Q4-base:1.31
	pkgsrc-2024Q3:1.28.0.2
	pkgsrc-2024Q3-base:1.28
	pkgsrc-2024Q2:1.26.0.2
	pkgsrc-2024Q2-base:1.26
	pkgsrc-2024Q1:1.24.0.4
	pkgsrc-2024Q1-base:1.24
	pkgsrc-2023Q4:1.24.0.2
	pkgsrc-2023Q4-base:1.24
	pkgsrc-2023Q3:1.21.0.4
	pkgsrc-2023Q3-base:1.21
	pkgsrc-2023Q2:1.21.0.2
	pkgsrc-2023Q2-base:1.21
	pkgsrc-2023Q1:1.20.0.2
	pkgsrc-2023Q1-base:1.20
	pkgsrc-2022Q4:1.17.0.2
	pkgsrc-2022Q4-base:1.17
	pkgsrc-2022Q3:1.14.0.2
	pkgsrc-2022Q3-base:1.14
	pkgsrc-2022Q2:1.12.0.2
	pkgsrc-2022Q2-base:1.12
	pkgsrc-2022Q1:1.11.0.2
	pkgsrc-2022Q1-base:1.11
	pkgsrc-2021Q4:1.3.0.2
	pkgsrc-2021Q4-base:1.3;
locks; strict;
comment	@# @;


1.38
date	2026.04.19.18.40.46;	author ktnb;	state Exp;
branches;
next	1.37;
commitid	jHebssWSowPogBCG;

1.37
date	2026.04.16.06.33.52;	author wiz;	state Exp;
branches;
next	1.36;
commitid	i9b6qrM84IuOk9CG;

1.36
date	2026.03.25.22.56.28;	author wiz;	state Exp;
branches;
next	1.35;
commitid	29BuEbar9GuKtpzG;

1.35
date	2026.01.07.08.47.42;	author wiz;	state Exp;
branches;
next	1.34;
commitid	1wQ3ICD8eebefrpG;

1.34
date	2025.05.09.19.37.14;	author wiz;	state Exp;
branches;
next	1.33;
commitid	WCR78K3U9f0aFgUF;

1.33
date	2025.05.09.05.51.26;	author adam;	state Exp;
branches;
next	1.32;
commitid	gd9WBpmGiiwY5cUF;

1.32
date	2025.04.17.21.51.24;	author wiz;	state Exp;
branches;
next	1.31;
commitid	xcIXAVA292fk6sRF;

1.31
date	2024.11.14.22.20.32;	author wiz;	state Exp;
branches;
next	1.30;
commitid	JmuDYqwL4erbdFxF;

1.30
date	2024.11.01.12.53.17;	author wiz;	state Exp;
branches;
next	1.29;
commitid	QB4Wk02mZPuBuWvF;

1.29
date	2024.11.01.00.52.31;	author wiz;	state Exp;
branches;
next	1.28;
commitid	QT27BdVP362gvSvF;

1.28
date	2024.08.25.06.18.58;	author wiz;	state Exp;
branches;
next	1.27;
commitid	BcrSL94SO85mvanF;

1.27
date	2024.07.06.15.45.09;	author adam;	state Exp;
branches;
next	1.26;
commitid	9KpFpYTi5zNpfNgF;

1.26
date	2024.05.29.16.33.18;	author adam;	state Exp;
branches;
next	1.25;
commitid	n8aFyEjEVZA0JUbF;

1.25
date	2024.04.22.07.26.42;	author adam;	state Exp;
branches;
next	1.24;
commitid	iCmbPjQYdlj0U67F;

1.24
date	2023.11.08.13.19.53;	author wiz;	state Exp;
branches;
next	1.23;
commitid	PsuHTklAIsF4bOLE;

1.23
date	2023.10.11.03.43.49;	author ryoon;	state Exp;
branches;
next	1.22;
commitid	kea5D8EFOmD5U9IE;

1.22
date	2023.10.06.19.18.15;	author adam;	state Exp;
branches;
next	1.21;
commitid	BMXgu5CLxEDLeBHE;

1.21
date	2023.04.19.08.10.36;	author adam;	state Exp;
branches;
next	1.20;
commitid	B8gCWhWtMX9vZGlE;

1.20
date	2023.01.30.02.52.02;	author gutteridge;	state Exp;
branches;
next	1.19;
commitid	Evx7PyDaGd5cLvbE;

1.19
date	2023.01.24.23.42.49;	author wiz;	state Exp;
branches;
next	1.18;
commitid	uJ4t82By5iEETQaE;

1.18
date	2023.01.24.18.36.29;	author wiz;	state Exp;
branches;
next	1.17;
commitid	ve7xOYU4T11xcPaE;

1.17
date	2022.11.30.19.55.00;	author adam;	state Exp;
branches;
next	1.16;
commitid	FkUfhZM3QnG4pL3E;

1.16
date	2022.11.23.16.20.31;	author adam;	state Exp;
branches;
next	1.15;
commitid	ju2K3LUYlTJKqQ2E;

1.15
date	2022.11.14.18.44.06;	author adam;	state Exp;
branches;
next	1.14;
commitid	D4GB0JeiCAn4wH1E;

1.14
date	2022.08.13.10.07.26;	author tnn;	state Exp;
branches;
next	1.13;
commitid	4rFVZkfJE9VIEHPD;

1.13
date	2022.08.12.13.59.52;	author gutteridge;	state Exp;
branches;
next	1.12;
commitid	53yfujt4oDwlYAPD;

1.12
date	2022.04.18.19.11.31;	author adam;	state Exp;
branches;
next	1.11;
commitid	eC9Na3jrfOOUpIAD;

1.11
date	2022.02.04.12.12.12;	author wiz;	state Exp;
branches;
next	1.10;
commitid	FIOrhqLfFBrdsirD;

1.10
date	2022.02.04.11.01.22;	author wiz;	state Exp;
branches;
next	1.9;
commitid	lnVyzyeIgAGS3irD;

1.9
date	2022.01.08.17.52.09;	author gutteridge;	state Exp;
branches;
next	1.8;
commitid	ozGGVyoerVbrcRnD;

1.8
date	2022.01.07.20.24.39;	author tnn;	state Exp;
branches;
next	1.7;
commitid	6FnExCzRqig15KnD;

1.7
date	2022.01.07.15.49.53;	author tnn;	state Exp;
branches;
next	1.6;
commitid	EmR7b3Ma9K7HyInD;

1.6
date	2022.01.07.14.33.43;	author tnn;	state Exp;
branches;
next	1.5;
commitid	grPWpvOnkX9B8InD;

1.5
date	2022.01.07.13.51.05;	author tnn;	state Exp;
branches;
next	1.4;
commitid	B0K0MC67P3mXTHnD;

1.4
date	2022.01.07.13.32.47;	author tnn;	state Exp;
branches;
next	1.3;
commitid	ogBJhonBBH5ENHnD;

1.3
date	2021.12.22.16.10.08;	author ryoon;	state Exp;
branches
	1.3.2.1;
next	1.2;
commitid	Tu3nEoS9r3LzbFlD;

1.2
date	2021.12.22.12.52.49;	author tnn;	state Exp;
branches;
next	1.1;
commitid	ZoGxxkJz6EcQ5ElD;

1.1
date	2021.12.19.14.05.53;	author ryoon;	state Exp;
branches;
next	;
commitid	qKjBf1DhDifXAglD;

1.3.2.1
date	2022.01.09.20.10.55;	author bsiegert;	state Exp;
branches;
next	;
commitid	7isQ8WJwAFCkWZnD;


desc
@@


1.38
log
@wasi-compiler-rt: fixed compiling on Linux
@
text
@# $NetBSD: Makefile,v 1.37 2026/04/16 06:33:52 wiz Exp $

.include "../../lang/llvm/version.mk"

PKGNAME=	wasi-compiler-rt-${LLVM_VERSION}
CATEGORIES=	lang devel

MAINTAINER=	pkgsrc-users@@NetBSD.org
HOMEPAGE=	https://compiler-rt.llvm.org/
COMMENT=	LLVM runtime libraries for WASI/WebAssembly
LICENSE=	apache-2.0

PATCHDIR=	${.CURDIR}/../../lang/compiler-rt/patches
DISTINFO_FILE=	${.CURDIR}/../../lang/compiler-rt/distinfo

NOT_FOR_PLATFORM=	NetBSD-[0-7].*-*

TOOL_DEPENDS+=	cmake-[0-9]*:../../devel/cmake
TOOL_DEPENDS+=	lld-${LLVM_VERSION}*:../../devel/lld

USE_CC_FEATURES=	c99
USE_CXX_FEATURES=	c++17
USE_LANGUAGES=		c c++
USE_TOOLS+=		ggrep pkg-config

SSP_SUPPORTED=		no
PKGSRC_USE_STACK_CHECK=	no

BUILDLINK_TRANSFORM+=	rm:-I/usr/include
BUILDLINK_TRANSFORM+=	rm:-I${PREFIX}/include

CMAKE_BUILD_DIR=	cmake-pkgsrc-build

CMAKE_CONFIGURE_ARGS+=	-DCMAKE_BUILD_TYPE=Release
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_TEST_COMPILER=${CC:Q}
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_OS_DIR:STRING=wasi
CMAKE_CONFIGURE_ARGS+=	-DLLVM_CONFIG_PATH=${LLVM_CONFIG_PATH:Q}
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_DEFAULT_TARGET_TRIPLE=wasm32-wasi
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_BAREMETAL_BUILD=TRUE
CMAKE_CONFIGURE_ARGS+=	-DCMAKE_SYSROOT=${BUILDLINK_DIR}/wasi
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_BAREMETAL_BUILD=TRUE
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_EXCLUDE_ATOMIC_BUILTIN=TRUE
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_FPIC_FLAG:BOOL=ON
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_FPIE_FLAG:BOOL=ON
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_FNO_BUILTIN_FLAG:BOOL=ON
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_STD_C11_FLAG:BOOL=ON
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_VISIBILITY_HIDDEN_FLAG:BOOL=ON
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_FREESTANDING_FLAG:BOOL=ON
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_XRAY_COMPILER_FLAG:BOOL=OFF
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_ATOMIC_KEYWORD:BOOL=ON
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_BFLOAT16:BOOL=OFF
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_FLOAT16:BOOL=OFF
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_ASM_LSE:BOOL=OFF
CMAKE_CONFIGURE_ARGS+=	-DCMAKE_C_COMPILER_WORKS=1 # Do not test clang compile
CMAKE_CONFIGURE_ARGS+=	-DCMAKE_CXX_COMPILER_WORKS=1 # Do not test clang++ compile
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_ENABLE_IOS:BOOL=OFF
CMAKE_CONFIGURE_ARGS+=	-DCMAKE_SYSTEM_NAME=WASI

CMAKE_INSTALL_PREFIX=	${PREFIX}/lib/clang/${LLVM_MAJOR_VERSION}
CMAKE_CONFIGURE_ARGS+=	-DCMAKE_INSTALL_PREFIX=${CMAKE_INSTALL_PREFIX}

GENERATE_PLIST+=	find ${DESTDIR}${PREFIX} \( -type f -o -type l \) -print | \
			sed 's,${DESTDIR}${PREFIX}/,,' | ${SORT} ;

.include "../../mk/bsd.prefs.mk"

pre-configure:
	${RUN} ${MKDIR} ${WRKSRC}/${CMAKE_BUILD_DIR}

do-configure:
	${RUN} cd ${WRKSRC}/${CMAKE_BUILD_DIR} && \
	${SETENV} ${CONFIGURE_ENV} cmake \
		${CMAKE_CONFIGURE_ARGS} \
		${WRKSRC}/lib/builtins

do-build:
	${RUN} cd ${WRKSRC}/${CMAKE_BUILD_DIR} && \
		${SETENV} ${MAKE_ENV} \
		${MAKE} ${CMAKE_CONFIGURE_ARGS} ${BUILD_TARGET}

do-install:
	${RUN} cd ${WRKSRC}/${CMAKE_BUILD_DIR} && \
		${SETENV} ${INSTALL_ENV} \
		${MAKE} ${CMAKE_CONFIGURE_ARGS} ${INSTALL_TARGET}

# Run llvm-ranlib again on the archive. Fixes mystery build failure
# in Firefox due to missing index (see PR pkg/56590). Might be a MAKE_JOBS
# problem in this package?
.if ${OPSYS} != "Darwin"
post-install:
	${PREFIX}/bin/llvm-ranlib \
	  ${DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/wasi/libclang_rt.builtins-wasm32.a
.endif

ABI=			# 32
CFLAGS+=		-O2 -fno-exceptions
CXXFLAGS+=		-O2
PKGSRC_COMPILER=	clang
CLANGBASE=		${PREFIX}
#.include "../../devel/cmake/build.mk"
BUILDLINK_DEPMETHOD.clang=	build
.include "../../lang/clang/buildlink3.mk"
.include "../../lang/llvm/buildlink3.mk"
.include "../../lang/wasi-libc/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"
@


1.37
log
@*: update llvm and friends to 21.1.8
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.36 2026/03/25 22:56:28 wiz Exp $
d57 1
@


1.36
log
@llvm and friends: update to to 20.1.8

Based on the wip packages and help from adam@@
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.21 2023/04/19 08:10:36 adam Exp $
a99 1
.include "../../devel/editline/buildlink3.mk"
@


1.35
log
@*: recursive bump for icu 78.1
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.34 2025/05/09 19:37:14 wiz Exp $
a2 1
PKGREVISION= 2
d5 1
a5 2
DISTNAME=	compiler-rt-${LLVM_VERSION}.src
PKGNAME=	${DISTNAME:S/.src//:S/compiler-rt-/wasi-compiler-rt-/}
a12 6
LLVM=		llvm-${LLVM_VERSION}.src
EXTRA_DIST+=	${LLVM}${EXTRACT_SUFX}

SITES.${LLVM}${EXTRACT_SUFX}=	\
	${MASTER_SITES:=${GITHUB_PROJECT}/releases/download/${GITHUB_RELEASE}/}

d37 1
a37 2
CMAKE_CONFIGURE_ARGS+=	-DLLVM_CMAKE_DIR=${BUILDLINK_PREFIX.llvm}/lib/cmake/llvm
#CMAKE_CONFIGURE_ARGS+=	-DLLVM_CMAKE_DIR=${LLVM_CONFIG_PATH:Q}
d44 1
a44 1
#CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_FPIE_FLAG:BOOL=ON
d48 2
a49 2
#CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_FREESTANDING_FLAG:BOOL=ON
#CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_XRAY_COMPILER_FLAG:BOOL=OFF
d51 2
a52 2
#CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_BFLOAT16:BOOL=OFF
#CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_FLOAT16:BOOL=OFF
d56 1
a56 1
#CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_ENABLE_IOS:BOOL=OFF
a65 3
post-extract:
	${LN} -f -s ${WRKDIR}/${LLVM} ${WRKDIR}/llvm

@


1.34
log
@*: bump for llvm 19 (shlib major changed)
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.33 2025/05/09 05:51:26 adam Exp $
d3 1
a3 1
PKGREVISION= 1
@


1.33
log
@llvm: updated to 19.1.7

19.1.7
https://releases.llvm.org/19.1.0/docs/ReleaseNotes.html
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.32 2025/04/17 21:51:24 wiz Exp $
d3 1
@


1.32
log
@*: recursive bump for icu 77 and libxml2 2.14
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.31 2024/11/14 22:20:32 wiz Exp $
a2 1
PKGREVISION= 4
d14 6
d31 1
a31 1
USE_TOOLS+=		ggrep
d44 2
a45 1
CMAKE_CONFIGURE_ARGS+=	-DLLVM_CONFIG_PATH=${LLVM_CONFIG_PATH:Q}
d52 1
a52 1
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_FPIE_FLAG:BOOL=ON
d56 2
a57 2
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_FREESTANDING_FLAG:BOOL=ON
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_XRAY_COMPILER_FLAG:BOOL=OFF
d59 2
a60 2
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_BFLOAT16:BOOL=OFF
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_HAS_FLOAT16:BOOL=OFF
d64 1
a64 1
CMAKE_CONFIGURE_ARGS+=	-DCOMPILER_RT_ENABLE_IOS:BOOL=OFF
d74 3
d111 1
@


1.31
log
@*: recursive bump for icu 76 shlib major version bump
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.30 2024/11/01 12:53:17 wiz Exp $
d3 1
a3 1
PKGREVISION= 3
@


1.30
log
@*: revbump for icu downgrade
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.29 2024/11/01 00:52:31 wiz Exp $
d3 1
a3 1
PKGREVISION= 2
@


1.29
log
@*: recursive bump for icu 76.1 shlib bump
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.28 2024/08/25 06:18:58 wiz Exp $
d3 1
a3 1
PKGREVISION= 1
@


1.28
log
@*: replace CMAKE_ARGS with CMAKE_CONFIGURE_ARGS
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.27 2024/07/06 15:45:09 adam Exp $
d3 1
@


1.27
log
@llvm: updated to 18.1.8

https://releases.llvm.org
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.21 2023/04/19 08:10:36 adam Exp $
d35 23
a57 23
CMAKE_ARGS+=	-DCMAKE_BUILD_TYPE=Release
CMAKE_ARGS+=	-DCOMPILER_RT_TEST_COMPILER=${CC:Q}
CMAKE_ARGS+=	-DCOMPILER_RT_OS_DIR:STRING=wasi
CMAKE_ARGS+=	-DLLVM_CONFIG_PATH=${LLVM_CONFIG_PATH:Q}
CMAKE_ARGS+=	-DCOMPILER_RT_DEFAULT_TARGET_TRIPLE=wasm32-wasi
CMAKE_ARGS+=	-DCOMPILER_RT_BAREMETAL_BUILD=TRUE
CMAKE_ARGS+=	-DCMAKE_SYSROOT=${BUILDLINK_DIR}/wasi
CMAKE_ARGS+=	-DCOMPILER_RT_BAREMETAL_BUILD=TRUE
CMAKE_ARGS+=	-DCOMPILER_RT_EXCLUDE_ATOMIC_BUILTIN=TRUE
CMAKE_ARGS+=	-DCOMPILER_RT_HAS_FPIC_FLAG:BOOL=ON
CMAKE_ARGS+=	-DCOMPILER_RT_HAS_FPIE_FLAG:BOOL=ON
CMAKE_ARGS+=	-DCOMPILER_RT_HAS_FNO_BUILTIN_FLAG:BOOL=ON
CMAKE_ARGS+=	-DCOMPILER_RT_HAS_STD_C11_FLAG:BOOL=ON
CMAKE_ARGS+=	-DCOMPILER_RT_HAS_VISIBILITY_HIDDEN_FLAG:BOOL=ON
CMAKE_ARGS+=	-DCOMPILER_RT_HAS_FREESTANDING_FLAG:BOOL=ON
CMAKE_ARGS+=	-DCOMPILER_RT_HAS_XRAY_COMPILER_FLAG:BOOL=OFF
CMAKE_ARGS+=	-DCOMPILER_RT_HAS_ATOMIC_KEYWORD:BOOL=ON
CMAKE_ARGS+=	-DCOMPILER_RT_HAS_BFLOAT16:BOOL=OFF
CMAKE_ARGS+=	-DCOMPILER_RT_HAS_FLOAT16:BOOL=OFF
CMAKE_ARGS+=	-DCOMPILER_RT_HAS_ASM_LSE:BOOL=OFF
CMAKE_ARGS+=	-DCMAKE_C_COMPILER_WORKS=1 # Do not test clang compile
CMAKE_ARGS+=	-DCMAKE_CXX_COMPILER_WORKS=1 # Do not test clang++ compile
CMAKE_ARGS+=	-DCOMPILER_RT_ENABLE_IOS:BOOL=OFF
d60 1
a60 1
CMAKE_ARGS+=	-DCMAKE_INSTALL_PREFIX=${CMAKE_INSTALL_PREFIX}
d73 1
a73 1
		${CMAKE_ARGS} \
d79 1
a79 1
		${MAKE} ${CMAKE_ARGS} ${BUILD_TARGET}
d84 1
a84 1
		${MAKE} ${CMAKE_ARGS} ${INSTALL_TARGET}
@


1.26
log
@revbump after icu and protobuf updates
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.25 2024/04/22 07:26:42 adam Exp $
a2 1
PKGREVISION= 1
d22 4
a25 2
USE_LANGUAGES=	c99 c++17
USE_TOOLS+=	ggrep
d96 1
a96 2
CFLAGS+=		-fno-exceptions
CFLAGS+=		-O2
@


1.25
log
@wasi-compiler-rt wasi-libcxx: updated to 17.0.6

17.0.6
Match LLVM version
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.24 2023/11/08 13:19:53 wiz Exp $
d3 1
@


1.24
log
@*: recursive bump for icu 74.1
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.23 2023/10/11 03:43:49 ryoon Exp $
a2 1
PKGREVISION= 1
@


1.23
log
@wasi-compiler-rt: fix build with llvm 16

* Fix build. Build specific static library only.
* TODO: Do not repeat CMake targets in Makefile.
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.22 2023/10/06 19:18:15 adam Exp $
d3 1
@


1.22
log
@wasi-compiler-rt, wasi-libcxx: update to LLVM 16
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.21 2023/04/19 08:10:36 adam Exp $
d19 4
a22 1
USE_LANGUAGES=	c99 c++11
d31 2
d55 1
a55 1
CMAKE_ARGS+=	-DCOMPILER_RT_ENABLE_IOS=OFF
d58 1
d65 19
d90 1
a90 1
	  ${DESTDIR}${PREFIX}/lib/clang/${LLVM_MAJOR_VERSION}/lib/wasi/libclang_rt.builtins-wasm32.a
d94 3
a96 2
CFLAGS=			-O2
CXXFLAGS=		-O2
d99 1
a99 1
.include "../../devel/cmake/build.mk"
@


1.21
log
@revbump after textproc/icu update
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.20 2023/01/30 02:52:02 gutteridge Exp $
a2 1
PKGREVISION= 1
a18 1
USE_CMAKE=	yes
a24 3
CONFIGURE_DIRS=	build
CMAKE_ARG_PATH=	${WRKSRC}/lib/builtins

d52 1
a52 1
CMAKE_INSTALL_PREFIX=	${PREFIX}/lib/clang/${PKGVERSION_NOREV}
a56 3
post-extract:
	${MKDIR} ${WRKSRC}/build

d65 1
a65 1
	  ${DESTDIR}${PREFIX}/lib/clang/${PKGVERSION_NOREV}/lib/wasi/libclang_rt.builtins-wasm32.a
d73 1
@


1.20
log
@wasi-compiler-rt: fix macOS builds

Don't assume an iOS SDK is present. Reported by John Klos in PR pkg/57196.
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.19 2023/01/24 23:42:49 wiz Exp $
d3 1
@


1.19
log
@wasi-cpmpiler-rt: revert conversion

weird breakage, to be investigated
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.18 2023/01/24 18:36:29 wiz Exp $
d54 1
@


1.18
log
@*: convert to cmake/build.mk
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.17 2022/11/30 19:55:00 adam Exp $
d19 1
d26 1
d60 3
a78 1
.include "../../devel/cmake/build.mk"
@


1.17
log
@llvm: updated to 15.0.6

15.0.6
Bug fixes
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.16 2022/11/23 16:20:31 adam Exp $
a18 1
USE_CMAKE=	yes
a24 1
CONFIGURE_DIRS=	build
a57 3
post-extract:
	${MKDIR} ${WRKSRC}/build

d74 1
@


1.16
log
@massive revision bump after textproc/icu update
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.15 2022/11/14 18:44:06 adam Exp $
a2 1
PKGREVISION= 1
@


1.15
log
@llvm: updated to 15.0.4

LLVM 15.0.4

Changes to the LLVM IR

LLVM now uses opaque pointers. This means that different pointer types like i8*, i32* or void()** are now represented as a single ptr type. See the linked document for migration instructions.
Renamed llvm.experimental.vector.extract intrinsic to llvm.vector.extract.
Renamed llvm.experimental.vector.insert intrinsic to llvm.vector.insert.
The constant expression variants of the following instructions have been removed:
extractvalue
insertvalue
udiv
sdiv
urem
srem
fadd
fsub
fmul
fdiv
frem
Added the support for fmax and fmin in atomicrmw instruction. The comparison is expected to match the behavior of llvm.maxnum.* and llvm.minnum.* respectively.
callbr instructions no longer use blockaddress arguments for labels. Instead, label constraints starting with ! refer directly to entries in the callbr indirect destination list.

Changes to building LLVM

Omitting CMAKE_BUILD_TYPE when using a single configuration generator is now an error. You now have to pass -DCMAKE_BUILD_TYPE=<type> in order to configure LLVM. This is done to help new users of LLVM select the correct type: since building LLVM in Debug mode is very resource intensive, we want to make sure that new users make the choice that lines up with their usage. We have also improved documentation around this setting that should help new users. You can find this documentation here.

Changes to Loop Optimizations

Loop interchange legality and cost model improvements

Changes to the AMDGPU Backend

8 and 16-bit atomic loads and stores are now supported

Changes to the ARM Backend

Added support for the Armv9-A, Armv9.1-A and Armv9.2-A architectures.
Added support for the Armv8.1-M PACBTI-M extension.
Added support for the Armv9-A, Armv9.1-A and Armv9.2-A architectures.
Added support for the Armv8.1-M PACBTI-M extension.
Removed the deprecation of ARMv8-A T32 Complex IT blocks. No deprecation warnings will be generated and -mrestrict-it is now always off by default. Previously it was on by default for Armv8 and off for all other architecture versions.
Added a pass to workaround Cortex-A57 Erratum 1742098 and Cortex-A72 Erratum 1655431. This is enabled by default when targeting either CPU.
Implemented generation of Windows SEH unwind information.
Switched the MinGW target to use SEH instead of DWARF for unwind information.
Added support for the Cortex-M85 CPU.
Added support for a new -mframe-chain=(none|aapcs|aapcs+leaf) command-line option, which controls the generation of AAPCS-compliant Frame Records.

Changes to the DirectX Backend

DirectX has been added as an experimental target. Specify -DLLVM_EXPERIMENTAL_TARGETS_TO_BUILD=DirectX in your CMake configuration to enable it. The target is not packaged in pre-built binaries.
The DirectX backend supports the dxil architecture which is based on LLVM 3.6 IR encoded as bitcode and is the format used for DirectX GPU Shader programs.

Changes to the PowerPC Backend

Common PowerPC improvements: * Add a new post instruction selection pass to generate CTR loops. * Add SSE4 and BMI compatible intrinsics implementation. * Supported 16-byte lock free atomics on PowerPC8 and up. * Supported atomic load/store for pointer types. * Supported stack size larger than 2G * Add __builtin_min/__builtin_max/__abs builtins. * Code generation improvements for splat load/vector shuffle/mulli, etc. * Emit VSX instructions for vector loads and stores regardless of alignment. * The mcpu=future has its own ISA now (FutureISA). * Added the ppc-set-dscr option to set the Data Stream Control Register (DSCR). * Bug fixes.

AIX improvements: * Supported 64 bit XCOFF for integrated-as path. * Supported X86-compatible vector intrinsics. * Program code csect default alignment now is 32-byte. * Supported auxiliary header in integrated-as path. * Improved alias symbol handling.

Changes to the RISC-V Backend

A RISCVRedundantCopyElimination pass was added to remove unnecessary zero copies.
A RISC-V specific CodeGenPrepare pass was added.
The machine outliner was enabled by default for RISC-V at -Oz. Additionally, the newly introduced RISCVMakeCompressible pass will make modify instructions prior to emission at -Oz in order to increase opportunities for the compression with the RISC-V C extension.
Various bug fixes and improvements to code generation for the RISC-V vector extensions.
Various improvements were made to RISC-V specific optimisation passes such as RISCVSExtWRemoval and RISCVMergeBaseOffset.
llc now computes the target ABI based on the target architecture using the same logic as Clang if not explicit ABI is given.
generic is now recognized as a valid CPU name and is mapped to generic-rv32 or generic-rv64 depending on the target triple.
Support for the experimental Zvfh extension was added, enabling half-precision floating point in vectors.
Support for the Zihintpause (Pause Hint) extension.
Assembler and disassembler support for the Zfinx and Zdinx (float / double in integer register) extensions.
Assembler and disassembler support for the Zicbom, Zicboz, and Zicbop cache management operation extensions.
Support for the Zmmul extension (a subextension of the M extension, adding multiplication instructions only).
Assembler and disassembler support for the hypervisor extension and for the Sinval supervisor memory-management extension.

Changes to the X86 Backend

Support half type on SSE2 and above targets following X86 psABI.
Support rdpru instruction on Zen2 and above targets.
During this release, half type has an ABI breaking change to provide the support for the ABI of _Float16 type on SSE2 and above following X86 psABI. (D107082)

The change may affect the current use of half includes (but is not limited to):

Frontends generating half type in function passing and/or returning arguments.
Downstream runtimes providing any half conversion builtins assuming the old ABI.
Projects built with LLVM 15.0 but using early versions of compiler-rt.
When you find failures with half type, check the calling conversion of the code and switch it to the new ABI.

Changes to the LLVM tools

(Experimental) llvm-symbolizer now has --filter-markup to filter Symbolizer Markup into human-readable form.
llvm-objcopy has removed support for the legacy zlib-gnu format.
llvm-objcopy now allows --set-section-flags src=... --rename-section src=tst. --add-section=.foo1=... --rename-section=.foo1=.foo2 now adds .foo1 instead of .foo2.
New features supported on AIX for llvm-ar:
AIX big-format archive write operation (D123949)
A new object mode option, -X , to specify the type of object file llvm-ar should operate upon (D127864)
Read global symbols of AIX big archive (D124865)
New options supported for llvm-nm:
-X, to specify the type of object file that llvm-nm should examine (D118193)
--export-symbols, to create a list of symbols to export (D112735)
The LLVM gold plugin now ignores bitcode from the .llvmbc section of ELF files when doing LTO. https://github.com/llvm/llvm-project/issues/47216
llvm-objcopy now supports 32 bit XCOFF.
llvm-objdump: improved assembly printing for XCOFF.
llc now parses code-model attribute from input file.

Changes to LLDB

The “memory region” command now has a “–all” option to list all memory regions (including unmapped ranges). This is the equivalent of using address 0 then repeating the command until all regions have been listed.
Added “–show-tags” option to the “memory find” command. This is off by default. When enabled, if the target value is found in tagged memory, the tags for that memory will be shown inline with the memory contents.
Various memory related parts of LLDB have been updated to handle non-address bits (such as AArch64 pointer signatures):
“memory read”, “memory write” and “memory find” can now be used with addresses with non-address bits.
All the read and write memory methods on SBProccess and SBTarget can be used with addreses with non-address bits.
When printing a pointer expression, LLDB can now dereference the result even if it has non-address bits.
The memory cache now ignores non-address bits when looking up memory locations. This prevents us reading locations multiple times, or not writing out new values if the addresses have different non-address bits.
LLDB now supports reading memory tags from AArch64 Linux core files.
LLDB now supports the gnu debuglink section for reading debug information from a separate file on Windows
LLDB now allows selecting the C++ ABI to use on Windows (between Itanium, used for MingW, and MSVC) via the plugin.object-file.pe-coff.abi setting. In Windows builds of LLDB, this defaults to the style used for LLVM’s default target.

Other Changes

The code for the LLVM Visual Studio integration has been removed. This had been obsolete and abandoned since Visual Studio started including an integration by default in 2019.
Added the unwinder, personality, and helper functions for exception handling on AIX. (D100132) (D100504)
PGO on AIX: A new implementation that requires linker support (__start_SECTION/__stop_SECTION symbols) available on AIX 7.2 TL5 SP4 and AIX 7.3 TL0 SP2.
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.14 2022/08/13 10:07:26 tnn Exp $
d3 1
@


1.14
log
@wasi-compiler-rt: delint, to extent possible
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.13 2022/08/12 13:59:52 gutteridge Exp $
a31 2
CMAKE_ARGS+=	-DCMAKE_VERBOSE_MAKEFILE=1

a32 2
CMAKE_ARGS+=	-DCMAKE_C_COMPILER=${CC:Q}
CMAKE_ARGS+=	-DCMAKE_CXX_COMPILER=${CXX:Q}
d49 1
d57 3
d63 2
d68 1
d72 1
a72 2

.include "../../mk/bsd.prefs.mk"
@


1.13
log
@wasi-compiler-rt: catch up with LLVM bump
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.12 2022/04/18 19:11:31 adam Exp $
d26 1
a26 1
CONFIGURE_DIRS=	../build
d61 1
a61 1
	${MKDIR} ${WRKDIR}/build
@


1.12
log
@revbump for textproc/icu update
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.11 2022/02/04 12:12:12 wiz Exp $
a6 1
PKGREVISION=	3
@


1.11
log
@wasi-compiler-rt: install into directory matching llvm's version number

Bump PKGREVISION.
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.10 2022/02/04 11:01:22 wiz Exp $
d7 1
a7 1
PKGREVISION=	2
@


1.10
log
@wasi-compiler-rt: fix post-install step after llvm update

XXX: should this use 13.0.1 now?
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.9 2022/01/08 17:52:09 gutteridge Exp $
d7 1
a7 1
PKGREVISION=	1
d59 1
a59 1
CMAKE_INSTALL_PREFIX=	${PREFIX}/lib/clang/13.0.0
d69 1
a69 1
	  ${DESTDIR}${PREFIX}/lib/clang/13.0.0/lib/wasi/libclang_rt.builtins-wasm32.a
@


1.9
log
@wasi-compiler-rt: add PR pkg/56590 reference in comment
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.8 2022/01/07 20:24:39 tnn Exp $
d69 1
a69 1
	  ${DESTDIR}${PREFIX}/lib/clang/${LLVM_VERSION}/lib/wasi/libclang_rt.builtins-wasm32.a
@


1.8
log
@wasi-compiler-rt: apply band-aid for ranlib error in www/firefox
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.7 2022/01/07 15:49:53 tnn Exp $
d65 2
a66 2
# in Firefox due to missing index. Might be a MAKE_JOBS problem in
# this package?
@


1.7
log
@wasi-*: eliminate -march and/or -mcpu CFLAGS user might have set

Random CFLAGS from mk.conf are not a good idea in a cross compile scenario.
Also reset ABI to empty string since -m32 can break some native CMake tests.
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.6 2022/01/07 14:33:43 tnn Exp $
d7 1
d64 7
@


1.6
log
@wasi-*: fix build failure when package already installed

Only use headers that pkgsrc has permitted via buildlink.
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.5 2022/01/07 13:51:05 tnn Exp $
d65 3
a67 1
ABI=			32
@


1.5
log
@wasi-compiler-rt: don't circumvent pkgsrc wrappers

Fixes build failure on Linux due to BUILDLINK_TRANSFORM not kicking in.
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.4 2022/01/07 13:32:47 tnn Exp $
d42 1
a42 1
CMAKE_ARGS+=	-DCMAKE_SYSROOT=${PREFIX}/wasi
@


1.4
log
@wasi-*: force ABI=32

These packages were failing when ABI=64 in mk.conf, because then -m64 is
passed down to clang and WebAssembly currently only supports -m32.
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.3 2021/12/22 16:10:08 ryoon Exp $
d35 3
a37 3
CMAKE_ARGS+=	-DCMAKE_C_COMPILER=${PREFIX}/bin/clang
CMAKE_ARGS+=	-DCMAKE_CXX_COMPILER=${PREFIX}/bin/clang++
CMAKE_ARGS+=	-DCOMPILER_RT_TEST_COMPILER=${PREFIX}/bin/clang
@


1.3
log
@wasi-compiler-rt: Disable stack check explicitly too
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.2 2021/12/22 12:52:49 tnn Exp $
d63 3
@


1.3.2.1
log
@Pullup ticket #6560 - requested by tnn
lang/wasi-compiler-rt: build fix
lang/wasi-libc: build fix
lang/wasi-libcxx: build fix

Revisions pulled up:
- lang/wasi-compiler-rt/Makefile                                1.4-1.8
- lang/wasi-libc/Makefile                                       1.4-1.5
- lang/wasi-libcxx/Makefile                                     1.5-1.7

---
   Module Name:	pkgsrc
   Committed By:	tnn
   Date:		Fri Jan  7 13:32:48 UTC 2022

   Modified Files:
   	pkgsrc/lang/wasi-compiler-rt: Makefile
   	pkgsrc/lang/wasi-libc: Makefile
   	pkgsrc/lang/wasi-libcxx: Makefile

   Log Message:
   wasi-*: force ABI=32

   These packages were failing when ABI=64 in mk.conf, because then -m64 is
   passed down to clang and WebAssembly currently only supports -m32.

---
   Module Name:	pkgsrc
   Committed By:	tnn
   Date:		Fri Jan  7 13:51:05 UTC 2022

   Modified Files:
   	pkgsrc/lang/wasi-compiler-rt: Makefile

   Log Message:
   wasi-compiler-rt: don't circumvent pkgsrc wrappers

   Fixes build failure on Linux due to BUILDLINK_TRANSFORM not kicking in.

---
   Module Name:	pkgsrc
   Committed By:	tnn
   Date:		Fri Jan  7 14:33:43 UTC 2022

   Modified Files:
   	pkgsrc/lang/wasi-compiler-rt: Makefile
   	pkgsrc/lang/wasi-libcxx: Makefile

   Log Message:
   wasi-*: fix build failure when package already installed

   Only use headers that pkgsrc has permitted via buildlink.

---
   Module Name:	pkgsrc
   Committed By:	tnn
   Date:		Fri Jan  7 15:49:53 UTC 2022

   Modified Files:
   	pkgsrc/lang/wasi-compiler-rt: Makefile
   	pkgsrc/lang/wasi-libc: Makefile
   	pkgsrc/lang/wasi-libcxx: Makefile

   Log Message:
   wasi-*: eliminate -march and/or -mcpu CFLAGS user might have set

   Random CFLAGS from mk.conf are not a good idea in a cross compile scenario.
   Also reset ABI to empty string since -m32 can break some native CMake tests.

---
   Module Name:	pkgsrc
   Committed By:	tnn
   Date:		Fri Jan  7 20:24:40 UTC 2022

   Modified Files:
   	pkgsrc/lang/wasi-compiler-rt: Makefile

   Log Message:
   wasi-compiler-rt: apply band-aid for ranlib error in www/firefox
@
text
@d1 1
a1 1
# $NetBSD$
a6 1
PKGREVISION=	1
d35 3
a37 3
CMAKE_ARGS+=	-DCMAKE_C_COMPILER=${CC:Q}
CMAKE_ARGS+=	-DCMAKE_CXX_COMPILER=${CXX:Q}
CMAKE_ARGS+=	-DCOMPILER_RT_TEST_COMPILER=${CC:Q}
d42 1
a42 1
CMAKE_ARGS+=	-DCMAKE_SYSROOT=${BUILDLINK_DIR}/wasi
a62 12
# Run llvm-ranlib again on the archive. Fixes mystery build failure
# in Firefox due to missing index. Might be a MAKE_JOBS problem in
# this package?
post-install:
	${PREFIX}/bin/llvm-ranlib \
	  ${DESTDIR}${PREFIX}/lib/clang/${LLVM_VERSION}/lib/wasi/libclang_rt.builtins-wasm32.a

.include "../../mk/bsd.prefs.mk"

ABI=			# 32
CFLAGS=			-O2
CXXFLAGS=		-O2
@


1.2
log
@wasi-compiler-rt: set CLANGBASE instead of PKG_CC/CXX
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.1 2021/12/19 14:05:53 ryoon Exp $
d22 3
a24 1
SSP_SUPPORTED=	no
@


1.1
log
@lang/wasi-compiler-rt: import wasi-compiler-rt-13.0.0

compiler-rt library for WebAssembly programs built on top of WASI
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.18 2021/09/19 09:12:46 nia Exp $
d62 1
a62 2
PKG_CC=		${PREFIX}/bin/clang
PKG_CXX=	${PREFIX}/bin/clang++
@

