Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F135491805
D22960.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
34 KB
Referenced Files
None
Subscribers
None
D22960.diff
View Options
Index: head/devel/Makefile
===================================================================
--- head/devel/Makefile
+++ head/devel/Makefile
@@ -6809,6 +6809,9 @@
SUBDIR += vxlog
SUBDIR += wand-libconfig
SUBDIR += wandio
+ SUBDIR += wasi-compiler-rt11
+ SUBDIR += wasi-libc
+ SUBDIR += wasi-libcxx
SUBDIR += websocketpp
SUBDIR += websvn
SUBDIR += wf-config
Index: head/devel/wasi-compiler-rt11/Makefile
===================================================================
--- head/devel/wasi-compiler-rt11/Makefile
+++ head/devel/wasi-compiler-rt11/Makefile
@@ -0,0 +1,55 @@
+# $FreeBSD$
+
+PORTNAME= compiler-rt
+PKGNAMEPREFIX= wasi-
+PKGNAMESUFFIX= ${LLVM_SUFFIX}
+DISTVERSION= 11.0.0
+CATEGORIES= devel lang
+.if ${DISTVERSION:M*rc*}
+MASTER_SITES= https://prereleases.llvm.org/${LLVM_RELEASE}/${RCDIR}
+.else
+MASTER_SITES= https://releases.llvm.org/${LLVM_RELEASE}/
+.endif
+PKGNAMESUFFIX= ${LLVM_SUFFIX}
+DISTNAME= ${PORTNAME}-${DISTVERSION}.src
+DISTFILES= ${PORTNAME}-${DISTVERSION}.src${EXTRACT_SUFX}
+
+MAINTAINER= greg@unrelenting.technology
+COMMENT= Clang builtins library for WebAssembly System Interface
+
+LICENSE= LLVM2
+LICENSE_FILE= ${WRKSRC}/LICENSE.TXT
+LICENSE_NAME= Apache License 2.0 with LLVM Exceptions
+LICENSE_PERMS= dist-mirror dist-sell pkg-mirror pkg-sell auto-accept
+
+LLVM_RELEASE= ${DISTVERSION:C/rc.*//}
+LLVM_SUFFIX= ${LLVM_RELEASE:C/\.[0-9]\.[0-9]$//}
+LLVM_PREFIX= ${PREFIX}/llvm${LLVM_SUFFIX}
+
+WASI_SYSROOT= ${LOCALBASE}/share/wasi-sysroot
+
+BUILD_DEPENDS= ${WASI_SYSROOT}/include/stdarg.h:devel/wasi-libc \
+ clang${LLVM_SUFFIX}:devel/llvm${LLVM_SUFFIX}
+
+USES= cmake tar:xz
+NO_ARCH= yes
+
+PLIST_FILES= llvm${LLVM_SUFFIX}/lib/clang/${LLVM_RELEASE}/lib/wasi/libclang_rt.builtins-wasm32.a
+
+CC= ${LOCALBASE}/bin/clang${LLVM_SUFFIX}
+CXX= ${LOCALBASE}/bin/clang++${LLVM_SUFFIX}
+
+CMAKE_SOURCE_PATH= ${WRKSRC}/lib/builtins
+CMAKE_INSTALL_PREFIX= ${LLVM_PREFIX}/lib/clang/${LLVM_RELEASE}
+CMAKE_ARGS= -DCMAKE_C_COMPILER_WORKS=1 \
+ -DCMAKE_SYSROOT=${WASI_SYSROOT} \
+ -DLLVM_CONFIG_PATH=${LOCALBASE}/bin/llvm-config${LLVM_SUFFIX} \
+ -DCOMPILER_RT_OS_DIR=wasi \
+ -DCOMPILER_RT_BAREMETAL_BUILD=TRUE \
+ -DCOMPILER_RT_DEFAULT_TARGET_TRIPLE=wasm32-wasi \
+ -DCOMPILER_RT_EXCLUDE_ATOMIC_BUILTIN=TRUE
+
+post-build:
+ ${LOCALBASE}/bin/llvm-ranlib${LLVM_SUFFIX} ${CONFIGURE_WRKSRC}/lib/wasi/*.a
+
+.include <bsd.port.mk>
Index: head/devel/wasi-compiler-rt11/distinfo
===================================================================
--- head/devel/wasi-compiler-rt11/distinfo
+++ head/devel/wasi-compiler-rt11/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1603452200
+SHA256 (compiler-rt-11.0.0.src.tar.xz) = 374aff82ff573a449f9aabbd330a5d0a441181c535a3599996127378112db234
+SIZE (compiler-rt-11.0.0.src.tar.xz) = 2141408
Index: head/devel/wasi-compiler-rt11/pkg-descr
===================================================================
--- head/devel/wasi-compiler-rt11/pkg-descr
+++ head/devel/wasi-compiler-rt11/pkg-descr
@@ -0,0 +1,7 @@
+The LLVM Project is a collection of modular and reusable compiler and
+toolchain technologies.
+
+This port includes Clang builtins for WASI
+(WebAssembly System Interface).
+
+WWW: http://llvm.org/
Index: head/devel/wasi-libc/Makefile
===================================================================
--- head/devel/wasi-libc/Makefile
+++ head/devel/wasi-libc/Makefile
@@ -0,0 +1,51 @@
+# $FreeBSD$
+
+PORTNAME= wasi-libc
+DISTVERSION= g20201005
+CATEGORIES= devel
+
+MAINTAINER= greg@unrelenting.technology
+COMMENT= C standard library for WebAssembly System Interface
+
+LICENSE= APACHE20 MIT LLVM2
+LICENSE_COMB= multi
+LICENSE_FILE_APACHE20= ${WRKSRC}/LICENSE-APACHE
+LICENSE_FILE_MIT= ${WRKSRC}/LICENSE-MIT
+LICENSE_FILE_LLVM2= ${WRKSRC}/LICENSE-APACHE-LLVM
+LICENSE_NAME_LLVM2= Apache License 2.0 with LLVM Exceptions
+LICENSE_PERMS_LLVM2= dist-mirror dist-sell pkg-mirror pkg-sell auto-accept
+
+BUILD_DEPENDS= clang${LLVM_VERSION}:devel/llvm${LLVM_VERSION}
+
+USES= gmake
+USE_GITHUB= yes
+GH_ACCOUNT= WebAssembly
+GH_TAGNAME= 9083fe84568fb4de76152757abfd216ba34ad908
+GH_TUPLE= WebAssembly:WASI:54a8be9:wasi/tools/wasi-headers/WASI
+NO_ARCH= yes
+LLVM_VERSION?= 11
+
+ALL_TARGET= finish
+
+# NOTE: matches the https://github.com/CraneStation/wasi-sdk
+WASI_SYSROOT= ${PREFIX}/share/wasi-sysroot
+
+# NOTE: our llvm ports don't ship stdarg/stddef clang headers, so they're in FILESDIR
+# and we install them to the sysroot
+
+MAKE_ENV= INSTALL_DIR=${STAGEDIR}${WASI_SYSROOT} \
+ WASM_AR=${LOCALBASE}/bin/llvm-ar${LLVM_VERSION} \
+ WASM_CC=${LOCALBASE}/bin/clang${LLVM_VERSION} \
+ WASM_CFLAGS="-O2 -DNDEBUG -I${FILESDIR}" \
+ WASM_NM=${LOCALBASE}/bin/llvm-nm${LLVM_VERSION}
+
+# NOTE: phony targets cause make install to rebuild everything
+# https://github.com/CraneStation/wasi-libc/issues/156
+post-patch:
+ ${REINPLACE_CMD} -e 's|install: finish|install:|' ${WRKSRC}/Makefile
+
+post-install:
+ ${INSTALL_DATA} ${FILESDIR}/stdarg.h ${STAGEDIR}${WASI_SYSROOT}/include/
+ ${INSTALL_DATA} ${FILESDIR}/stddef.h ${STAGEDIR}${WASI_SYSROOT}/include/
+
+.include <bsd.port.mk>
Index: head/devel/wasi-libc/distinfo
===================================================================
--- head/devel/wasi-libc/distinfo
+++ head/devel/wasi-libc/distinfo
@@ -0,0 +1,5 @@
+TIMESTAMP = 1603452634
+SHA256 (WebAssembly-wasi-libc-g20201005-9083fe84568fb4de76152757abfd216ba34ad908_GH0.tar.gz) = 9311ab7117b26bda1bc7ae98335ea85186f769beba21bb2718b943c9eaaf7818
+SIZE (WebAssembly-wasi-libc-g20201005-9083fe84568fb4de76152757abfd216ba34ad908_GH0.tar.gz) = 1222481
+SHA256 (WebAssembly-WASI-54a8be9_GH0.tar.gz) = 88dc40a1919223f16ce2e495a05c72991f2aa39d0ada1a89abf069f914517a6c
+SIZE (WebAssembly-WASI-54a8be9_GH0.tar.gz) = 273430
Index: head/devel/wasi-libc/files/patch-Makefile
===================================================================
--- head/devel/wasi-libc/files/patch-Makefile
+++ head/devel/wasi-libc/files/patch-Makefile
@@ -0,0 +1,13 @@
+complains about: __arraycount
+
+--- Makefile.orig 2020-05-16 19:12:43 UTC
++++ Makefile
+@@ -515,7 +515,7 @@ finish: startup_files libc
+
+ # Check that the computed metadata matches the expected metadata.
+ # This ignores whitespace because on Windows the output has CRLF line endings.
+- diff -wur "$(CURDIR)/expected/$(MULTIARCH_TRIPLE)" "$(SYSROOT_SHARE)"
++ # diff -wur "$(CURDIR)/expected/$(MULTIARCH_TRIPLE)" "$(SYSROOT_SHARE)"
+
+ #
+ # The build succeeded! The generated sysroot is in $(SYSROOT).
Index: head/devel/wasi-libc/files/stdarg.h
===================================================================
--- head/devel/wasi-libc/files/stdarg.h
+++ head/devel/wasi-libc/files/stdarg.h
@@ -0,0 +1,35 @@
+/*===---- stdarg.h - Variable argument handling ----------------------------===
+ *
+ * Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
+ * See https://llvm.org/LICENSE.txt for license information.
+ * SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+ *
+ *===-----------------------------------------------------------------------===
+ */
+
+#ifndef __STDARG_H
+#define __STDARG_H
+
+#ifndef _VA_LIST
+typedef __builtin_va_list va_list;
+#define _VA_LIST
+#endif
+#define va_start(ap, param) __builtin_va_start(ap, param)
+#define va_end(ap) __builtin_va_end(ap)
+#define va_arg(ap, type) __builtin_va_arg(ap, type)
+
+/* GCC always defines __va_copy, but does not define va_copy unless in c99 mode
+ * or -ansi is not specified, since it was not part of C90.
+ */
+#define __va_copy(d,s) __builtin_va_copy(d,s)
+
+#if __STDC_VERSION__ >= 199901L || __cplusplus >= 201103L || !defined(__STRICT_ANSI__)
+#define va_copy(dest, src) __builtin_va_copy(dest, src)
+#endif
+
+#ifndef __GNUC_VA_LIST
+#define __GNUC_VA_LIST 1
+typedef __builtin_va_list __gnuc_va_list;
+#endif
+
+#endif /* __STDARG_H */
Index: head/devel/wasi-libc/files/stddef.h
===================================================================
--- head/devel/wasi-libc/files/stddef.h
+++ head/devel/wasi-libc/files/stddef.h
@@ -0,0 +1,121 @@
+/*===---- stddef.h - Basic type definitions --------------------------------===
+ *
+ * Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
+ * See https://llvm.org/LICENSE.txt for license information.
+ * SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+ *
+ *===-----------------------------------------------------------------------===
+ */
+
+#if !defined(__STDDEF_H) || defined(__need_ptrdiff_t) || \
+ defined(__need_size_t) || defined(__need_wchar_t) || \
+ defined(__need_NULL) || defined(__need_wint_t)
+
+#if !defined(__need_ptrdiff_t) && !defined(__need_size_t) && \
+ !defined(__need_wchar_t) && !defined(__need_NULL) && \
+ !defined(__need_wint_t)
+/* Always define miscellaneous pieces when modules are available. */
+#if !__has_feature(modules)
+#define __STDDEF_H
+#endif
+#define __need_ptrdiff_t
+#define __need_size_t
+#define __need_wchar_t
+#define __need_NULL
+#define __need_STDDEF_H_misc
+/* __need_wint_t is intentionally not defined here. */
+#endif
+
+#if defined(__need_ptrdiff_t)
+#if !defined(_PTRDIFF_T) || __has_feature(modules)
+/* Always define ptrdiff_t when modules are available. */
+#if !__has_feature(modules)
+#define _PTRDIFF_T
+#endif
+typedef __PTRDIFF_TYPE__ ptrdiff_t;
+#endif
+#undef __need_ptrdiff_t
+#endif /* defined(__need_ptrdiff_t) */
+
+#if defined(__need_size_t)
+#if !defined(_SIZE_T) || __has_feature(modules)
+/* Always define size_t when modules are available. */
+#if !__has_feature(modules)
+#define _SIZE_T
+#endif
+typedef __SIZE_TYPE__ size_t;
+#endif
+#undef __need_size_t
+#endif /*defined(__need_size_t) */
+
+#if defined(__need_STDDEF_H_misc)
+/* ISO9899:2011 7.20 (C11 Annex K): Define rsize_t if __STDC_WANT_LIB_EXT1__ is
+ * enabled. */
+#if (defined(__STDC_WANT_LIB_EXT1__) && __STDC_WANT_LIB_EXT1__ >= 1 && \
+ !defined(_RSIZE_T)) || __has_feature(modules)
+/* Always define rsize_t when modules are available. */
+#if !__has_feature(modules)
+#define _RSIZE_T
+#endif
+typedef __SIZE_TYPE__ rsize_t;
+#endif
+#endif /* defined(__need_STDDEF_H_misc) */
+
+#if defined(__need_wchar_t)
+#ifndef __cplusplus
+/* Always define wchar_t when modules are available. */
+#if !defined(_WCHAR_T) || __has_feature(modules)
+#if !__has_feature(modules)
+#define _WCHAR_T
+#if defined(_MSC_EXTENSIONS)
+#define _WCHAR_T_DEFINED
+#endif
+#endif
+typedef __WCHAR_TYPE__ wchar_t;
+#endif
+#endif
+#undef __need_wchar_t
+#endif /* defined(__need_wchar_t) */
+
+#if defined(__need_NULL)
+#undef NULL
+#ifdef __cplusplus
+# if !defined(__MINGW32__) && !defined(_MSC_VER)
+# define NULL __null
+# else
+# define NULL 0
+# endif
+#else
+# define NULL ((void*)0)
+#endif
+#ifdef __cplusplus
+#if defined(_MSC_EXTENSIONS) && defined(_NATIVE_NULLPTR_SUPPORTED)
+namespace std { typedef decltype(nullptr) nullptr_t; }
+using ::std::nullptr_t;
+#endif
+#endif
+#undef __need_NULL
+#endif /* defined(__need_NULL) */
+
+#if defined(__need_STDDEF_H_misc)
+#if __STDC_VERSION__ >= 201112L || __cplusplus >= 201103L
+#include "__stddef_max_align_t.h"
+#endif
+#define offsetof(t, d) __builtin_offsetof(t, d)
+#undef __need_STDDEF_H_misc
+#endif /* defined(__need_STDDEF_H_misc) */
+
+/* Some C libraries expect to see a wint_t here. Others (notably MinGW) will use
+__WINT_TYPE__ directly; accommodate both by requiring __need_wint_t */
+#if defined(__need_wint_t)
+/* Always define wint_t when modules are available. */
+#if !defined(_WINT_T) || __has_feature(modules)
+#if !__has_feature(modules)
+#define _WINT_T
+#endif
+typedef __WINT_TYPE__ wint_t;
+#endif
+#undef __need_wint_t
+#endif /* __need_wint_t */
+
+#endif
Index: head/devel/wasi-libc/pkg-descr
===================================================================
--- head/devel/wasi-libc/pkg-descr
+++ head/devel/wasi-libc/pkg-descr
@@ -0,0 +1,8 @@
+libc/sysroot for WASI (WebAssembly System Interface)
+
+WASI Libc is a libc for WebAssembly programs built on top of WASI system calls.
+It provides a wide array of POSIX-compatible C APIs, including support
+for standard I/O, file I/O, filesystem manipulation, memory management, time,
+string, environment variables, program startup, and many other APIs.
+
+WWW: https://github.com/CraneStation/wasi-libc
Index: head/devel/wasi-libc/pkg-plist
===================================================================
--- head/devel/wasi-libc/pkg-plist
+++ head/devel/wasi-libc/pkg-plist
@@ -0,0 +1,219 @@
+share/wasi-sysroot/include/__errno.h
+share/wasi-sysroot/include/__errno_values.h
+share/wasi-sysroot/include/__fd_set.h
+share/wasi-sysroot/include/__function___isatty.h
+share/wasi-sysroot/include/__functions_malloc.h
+share/wasi-sysroot/include/__functions_memcpy.h
+share/wasi-sysroot/include/__header_dirent.h
+share/wasi-sysroot/include/__header_fcntl.h
+share/wasi-sysroot/include/__header_inttypes.h
+share/wasi-sysroot/include/__header_netinet_in.h
+share/wasi-sysroot/include/__header_poll.h
+share/wasi-sysroot/include/__header_stdlib.h
+share/wasi-sysroot/include/__header_string.h
+share/wasi-sysroot/include/__header_sys_ioctl.h
+share/wasi-sysroot/include/__header_sys_resource.h
+share/wasi-sysroot/include/__header_sys_socket.h
+share/wasi-sysroot/include/__header_sys_stat.h
+share/wasi-sysroot/include/__header_time.h
+share/wasi-sysroot/include/__header_unistd.h
+share/wasi-sysroot/include/__macro_FD_SETSIZE.h
+share/wasi-sysroot/include/__macro_PAGESIZE.h
+share/wasi-sysroot/include/__mode_t.h
+share/wasi-sysroot/include/__seek.h
+share/wasi-sysroot/include/__struct_dirent.h
+share/wasi-sysroot/include/__struct_in6_addr.h
+share/wasi-sysroot/include/__struct_in_addr.h
+share/wasi-sysroot/include/__struct_iovec.h
+share/wasi-sysroot/include/__struct_msghdr.h
+share/wasi-sysroot/include/__struct_pollfd.h
+share/wasi-sysroot/include/__struct_rusage.h
+share/wasi-sysroot/include/__struct_sockaddr.h
+share/wasi-sysroot/include/__struct_sockaddr_in.h
+share/wasi-sysroot/include/__struct_sockaddr_in6.h
+share/wasi-sysroot/include/__struct_sockaddr_storage.h
+share/wasi-sysroot/include/__struct_sockaddr_un.h
+share/wasi-sysroot/include/__struct_stat.h
+share/wasi-sysroot/include/__struct_timespec.h
+share/wasi-sysroot/include/__struct_timeval.h
+share/wasi-sysroot/include/__struct_tm.h
+share/wasi-sysroot/include/__struct_tms.h
+share/wasi-sysroot/include/__typedef_DIR.h
+share/wasi-sysroot/include/__typedef_blkcnt_t.h
+share/wasi-sysroot/include/__typedef_blksize_t.h
+share/wasi-sysroot/include/__typedef_clock_t.h
+share/wasi-sysroot/include/__typedef_clockid_t.h
+share/wasi-sysroot/include/__typedef_dev_t.h
+share/wasi-sysroot/include/__typedef_fd_set.h
+share/wasi-sysroot/include/__typedef_gid_t.h
+share/wasi-sysroot/include/__typedef_in_addr_t.h
+share/wasi-sysroot/include/__typedef_in_port_t.h
+share/wasi-sysroot/include/__typedef_ino_t.h
+share/wasi-sysroot/include/__typedef_mode_t.h
+share/wasi-sysroot/include/__typedef_nfds_t.h
+share/wasi-sysroot/include/__typedef_nlink_t.h
+share/wasi-sysroot/include/__typedef_off_t.h
+share/wasi-sysroot/include/__typedef_sa_family_t.h
+share/wasi-sysroot/include/__typedef_sigset_t.h
+share/wasi-sysroot/include/__typedef_socklen_t.h
+share/wasi-sysroot/include/__typedef_ssize_t.h
+share/wasi-sysroot/include/__typedef_suseconds_t.h
+share/wasi-sysroot/include/__typedef_time_t.h
+share/wasi-sysroot/include/__typedef_uid_t.h
+share/wasi-sysroot/include/alloca.h
+share/wasi-sysroot/include/ar.h
+share/wasi-sysroot/include/arpa/ftp.h
+share/wasi-sysroot/include/arpa/inet.h
+share/wasi-sysroot/include/arpa/nameser.h
+share/wasi-sysroot/include/arpa/nameser_compat.h
+share/wasi-sysroot/include/arpa/telnet.h
+share/wasi-sysroot/include/arpa/tftp.h
+share/wasi-sysroot/include/assert.h
+share/wasi-sysroot/include/bits/alltypes.h
+share/wasi-sysroot/include/bits/dirent.h
+share/wasi-sysroot/include/bits/fcntl.h
+share/wasi-sysroot/include/bits/fenv.h
+share/wasi-sysroot/include/bits/float.h
+share/wasi-sysroot/include/bits/hwcap.h
+share/wasi-sysroot/include/bits/io.h
+share/wasi-sysroot/include/bits/ioctl.h
+share/wasi-sysroot/include/bits/ioctl_fix.h
+share/wasi-sysroot/include/bits/ipcstat.h
+share/wasi-sysroot/include/bits/limits.h
+share/wasi-sysroot/include/bits/mman.h
+share/wasi-sysroot/include/bits/poll.h
+share/wasi-sysroot/include/bits/posix.h
+share/wasi-sysroot/include/bits/reg.h
+share/wasi-sysroot/include/bits/resource.h
+share/wasi-sysroot/include/bits/signal.h
+share/wasi-sysroot/include/bits/socket.h
+share/wasi-sysroot/include/bits/stat.h
+share/wasi-sysroot/include/bits/stdint.h
+share/wasi-sysroot/include/byteswap.h
+share/wasi-sysroot/include/complex.h
+share/wasi-sysroot/include/cpio.h
+share/wasi-sysroot/include/crypt.h
+share/wasi-sysroot/include/ctype.h
+share/wasi-sysroot/include/dirent.h
+share/wasi-sysroot/include/endian.h
+share/wasi-sysroot/include/err.h
+share/wasi-sysroot/include/errno.h
+share/wasi-sysroot/include/fcntl.h
+share/wasi-sysroot/include/features.h
+share/wasi-sysroot/include/fenv.h
+share/wasi-sysroot/include/float.h
+share/wasi-sysroot/include/fmtmsg.h
+share/wasi-sysroot/include/fnmatch.h
+share/wasi-sysroot/include/ftw.h
+share/wasi-sysroot/include/getopt.h
+share/wasi-sysroot/include/glob.h
+share/wasi-sysroot/include/iconv.h
+share/wasi-sysroot/include/ifaddrs.h
+share/wasi-sysroot/include/inttypes.h
+share/wasi-sysroot/include/iso646.h
+share/wasi-sysroot/include/langinfo.h
+share/wasi-sysroot/include/libgen.h
+share/wasi-sysroot/include/limits.h
+share/wasi-sysroot/include/locale.h
+share/wasi-sysroot/include/malloc.h
+share/wasi-sysroot/include/math.h
+share/wasi-sysroot/include/memory.h
+share/wasi-sysroot/include/monetary.h
+share/wasi-sysroot/include/mqueue.h
+share/wasi-sysroot/include/netinet/icmp6.h
+share/wasi-sysroot/include/netinet/igmp.h
+share/wasi-sysroot/include/netinet/in.h
+share/wasi-sysroot/include/netinet/in_systm.h
+share/wasi-sysroot/include/netinet/ip.h
+share/wasi-sysroot/include/netinet/ip6.h
+share/wasi-sysroot/include/netinet/ip_icmp.h
+share/wasi-sysroot/include/netinet/tcp.h
+share/wasi-sysroot/include/netinet/udp.h
+share/wasi-sysroot/include/netpacket/packet.h
+share/wasi-sysroot/include/nl_types.h
+share/wasi-sysroot/include/poll.h
+share/wasi-sysroot/include/regex.h
+share/wasi-sysroot/include/sched.h
+share/wasi-sysroot/include/search.h
+share/wasi-sysroot/include/semaphore.h
+share/wasi-sysroot/include/signal.h
+share/wasi-sysroot/include/stdalign.h
+share/wasi-sysroot/include/stdarg.h
+share/wasi-sysroot/include/stdbool.h
+share/wasi-sysroot/include/stdc-predef.h
+share/wasi-sysroot/include/stddef.h
+share/wasi-sysroot/include/stdint.h
+share/wasi-sysroot/include/stdio.h
+share/wasi-sysroot/include/stdio_ext.h
+share/wasi-sysroot/include/stdlib.h
+share/wasi-sysroot/include/stdnoreturn.h
+share/wasi-sysroot/include/string.h
+share/wasi-sysroot/include/strings.h
+share/wasi-sysroot/include/stropts.h
+share/wasi-sysroot/include/sys/dir.h
+share/wasi-sysroot/include/sys/errno.h
+share/wasi-sysroot/include/sys/eventfd.h
+share/wasi-sysroot/include/sys/fcntl.h
+share/wasi-sysroot/include/sys/file.h
+share/wasi-sysroot/include/sys/ioctl.h
+share/wasi-sysroot/include/sys/mman.h
+share/wasi-sysroot/include/sys/param.h
+share/wasi-sysroot/include/sys/poll.h
+share/wasi-sysroot/include/sys/random.h
+share/wasi-sysroot/include/sys/reg.h
+share/wasi-sysroot/include/sys/resource.h
+share/wasi-sysroot/include/sys/select.h
+share/wasi-sysroot/include/sys/signal.h
+share/wasi-sysroot/include/sys/socket.h
+share/wasi-sysroot/include/sys/stat.h
+share/wasi-sysroot/include/sys/stropts.h
+share/wasi-sysroot/include/sys/syscall.h
+share/wasi-sysroot/include/sys/sysinfo.h
+share/wasi-sysroot/include/sys/time.h
+share/wasi-sysroot/include/sys/timeb.h
+share/wasi-sysroot/include/sys/times.h
+share/wasi-sysroot/include/sys/timex.h
+share/wasi-sysroot/include/sys/ttydefaults.h
+share/wasi-sysroot/include/sys/types.h
+share/wasi-sysroot/include/sys/uio.h
+share/wasi-sysroot/include/sys/un.h
+share/wasi-sysroot/include/sys/utsname.h
+share/wasi-sysroot/include/syscall.h
+share/wasi-sysroot/include/sysexits.h
+share/wasi-sysroot/include/tar.h
+share/wasi-sysroot/include/tgmath.h
+share/wasi-sysroot/include/threads.h
+share/wasi-sysroot/include/time.h
+share/wasi-sysroot/include/uchar.h
+share/wasi-sysroot/include/unistd.h
+share/wasi-sysroot/include/utime.h
+share/wasi-sysroot/include/values.h
+share/wasi-sysroot/include/wasi/api.h
+share/wasi-sysroot/include/wasi/libc-environ.h
+share/wasi-sysroot/include/wasi/libc-find-relpath.h
+share/wasi-sysroot/include/wasi/libc.h
+share/wasi-sysroot/include/wchar.h
+share/wasi-sysroot/include/wctype.h
+share/wasi-sysroot/lib/wasm32-wasi/crt1-command.o
+share/wasi-sysroot/lib/wasm32-wasi/crt1-reactor.o
+share/wasi-sysroot/lib/wasm32-wasi/crt1.o
+share/wasi-sysroot/lib/wasm32-wasi/libc-printscan-long-double.a
+share/wasi-sysroot/lib/wasm32-wasi/libc-printscan-no-floating-point.a
+share/wasi-sysroot/lib/wasm32-wasi/libc.a
+share/wasi-sysroot/lib/wasm32-wasi/libc.imports
+share/wasi-sysroot/lib/wasm32-wasi/libcrypt.a
+share/wasi-sysroot/lib/wasm32-wasi/libdl.a
+share/wasi-sysroot/lib/wasm32-wasi/libm.a
+share/wasi-sysroot/lib/wasm32-wasi/libpthread.a
+share/wasi-sysroot/lib/wasm32-wasi/libresolv.a
+share/wasi-sysroot/lib/wasm32-wasi/librt.a
+share/wasi-sysroot/lib/wasm32-wasi/libutil.a
+share/wasi-sysroot/lib/wasm32-wasi/libwasi-emulated-mman.a
+share/wasi-sysroot/lib/wasm32-wasi/libwasi-emulated-signal.a
+share/wasi-sysroot/lib/wasm32-wasi/libxnet.a
+share/wasi-sysroot/share/wasm32-wasi/defined-symbols.txt
+share/wasi-sysroot/share/wasm32-wasi/include-all.c
+share/wasi-sysroot/share/wasm32-wasi/predefined-macros.txt
+share/wasi-sysroot/share/wasm32-wasi/undefined-symbols.txt
+@dir share/wasi-sysroot/include/net
+@dir share/wasi-sysroot/include/scsi
Index: head/devel/wasi-libcxx/Makefile
===================================================================
--- head/devel/wasi-libcxx/Makefile
+++ head/devel/wasi-libcxx/Makefile
@@ -0,0 +1,86 @@
+# $FreeBSD$
+
+PORTNAME= libcxx
+DISTVERSION= 11.0.0
+CATEGORIES= devel lang
+MASTER_SITES= https://github.com/llvm/llvm-project/releases/download/llvmorg-${DISTVERSION}/
+PKGNAMEPREFIX= wasi-
+DISTNAME= llvm-project-${DISTVERSION}
+
+MAINTAINER= greg@unrelenting.technology
+COMMENT= C++ standard library for WebAssembly System Interface
+
+LICENSE= LLVM2
+LICENSE_NAME= Apache License 2.0 with LLVM Exceptions
+LICENSE_FILE= ${WRKSRC}/LICENSE.TXT
+LICENSE_PERMS= dist-mirror dist-sell pkg-mirror pkg-sell auto-accept
+
+BUILD_DEPENDS= ${WASI_SYSROOT}/include/stdarg.h:devel/wasi-libc \
+ clang${LLVM_SUFFIX}:devel/llvm${LLVM_SUFFIX}
+
+USES= cmake tar:xz
+NO_ARCH= yes
+
+SSP_UNSAFE= yes
+CC= ${LOCALBASE}/bin/clang${LLVM_SUFFIX}
+CXX= ${LOCALBASE}/bin/clang++${LLVM_SUFFIX}
+LLVM_RELEASE= ${DISTVERSION:C/rc.*//}
+LLVM_SUFFIX= ${LLVM_RELEASE:C/\.[0-9]\.[0-9]$//}
+LLVM_PREFIX= ${PREFIX}/llvm${LLVM_SUFFIX}
+WASI_SYSROOT= ${LOCALBASE}/share/wasi-sysroot
+WRKSRC= ${WRKDIR}/${DISTNAME}/libcxx
+
+CMAKE_INSTALL_PREFIX= ${PREFIX}/share/wasi-sysroot
+CMAKE_ARGS= -DCMAKE_C_COMPILER_WORKS=1 \
+ -DCMAKE_CXX_COMPILER_WORKS=1 \
+ -DCXX_SUPPORTS_CXX11=ON \
+ -DLLVM_COMPILER_CHECKED=ON \
+ -DUNIX:BOOL=ON \
+ -DCMAKE_SYSROOT=${WASI_SYSROOT} \
+ -DLLVM_CONFIG_PATH=${LOCALBASE}/bin/llvm-config${LLVM_SUFFIX} \
+ -DLIBCXX_LIBDIR_SUFFIX=/wasm32-wasi \
+ -DLIBCXX_INCLUDE_BENCHMARKS:BOOL=FALSE \
+ -DLIBCXX_INCLUDE_TESTS:BOOL=FALSE \
+ -DLIBCXX_TARGET_TRIPLE=wasm32-wasi \
+ -DLIBCXX_ENABLE_THREADS:BOOL=OFF \
+ -DLIBCXX_HAS_PTHREAD_API:BOOL=OFF \
+ -DLIBCXX_HAS_EXTERNAL_THREAD_API:BOOL=OFF \
+ -DLIBCXX_BUILD_EXTERNAL_THREAD_LIBRARY:BOOL=OFF \
+ -DLIBCXX_HAS_WIN32_THREAD_API:BOOL=OFF \
+ -DLIBCXX_ENABLE_SHARED:BOOL=OFF \
+ -DLIBCXX_ENABLE_EXPERIMENTAL_LIBRARY:BOOL=OFF \
+ -DLIBCXX_ENABLE_EXCEPTIONS:BOOL=OFF \
+ -DLIBCXX_ENABLE_FILESYSTEM:BOOL=OFF \
+ -DLIBCXX_CXX_ABI=libcxxabi \
+ -DLIBCXX_HAS_MUSL_LIBC:BOOL=ON \
+ -DLIBCXX_ABI_VERSION=2 \
+ -DLIBCXXABI_LIBDIR_SUFFIX=/wasm32-wasi \
+ -DLIBCXXABI_TARGET_TRIPLE=wasm32-wasi \
+ -DLIBCXXABI_ENABLE_EXCEPTIONS:BOOL=OFF \
+ -DLIBCXXABI_ENABLE_SHARED:BOOL=OFF \
+ -DLIBCXXABI_SILENT_TERMINATE:BOOL=ON \
+ -DLIBCXXABI_ENABLE_THREADS:BOOL=OFF \
+ -DLIBCXXABI_HAS_PTHREAD_API:BOOL=OFF \
+ -DLIBCXXABI_HAS_EXTERNAL_THREAD_API:BOOL=OFF \
+ -DLIBCXXABI_BUILD_EXTERNAL_THREAD_LIBRARY:BOOL=OFF \
+ -DLIBCXXABI_HAS_WIN32_THREAD_API:BOOL=OFF \
+ -DLIBCXXABI_LIBCXX_INCLUDES=${CONFIGURE_WRKSRC}/include/c++/v1
+
+post-extract:
+ @${MKDIR} ${WRKDIR}/.build_cxxabi
+
+post-configure:
+ @cd ${WRKDIR}/.build_cxxabi && \
+ ${SETENV} ${CONFIGURE_ENV} ${CMAKE_BIN} ${CMAKE_ARGS} ${WRKDIR}/${DISTNAME}/libcxxabi
+
+post-build:
+ @${LOCALBASE}/bin/llvm-ranlib${LLVM_SUFFIX} ${CONFIGURE_WRKSRC}/lib/wasm32-wasi/*.a
+ @cd ${WRKDIR}/.build_cxxabi && \
+ ${SETENV} ${MAKE_ENV} ${MAKE_CMD} ${MAKE_ARGS} ${ALL_TARGET}
+ @${LOCALBASE}/bin/llvm-ranlib${LLVM_SUFFIX} ${WRKDIR}/.build_cxxabi/lib/wasm32-wasi/*.a
+
+post-install:
+ @cd ${WRKDIR}/.build_cxxabi && \
+ ${SETENV} ${MAKE_ENV} ${MAKE_CMD} ${MAKE_ARGS} ${INSTALL_TARGET}
+
+.include <bsd.port.mk>
Index: head/devel/wasi-libcxx/distinfo
===================================================================
--- head/devel/wasi-libcxx/distinfo
+++ head/devel/wasi-libcxx/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1603454401
+SHA256 (llvm-project-11.0.0.tar.xz) = b7b639fc675fa1c86dd6d0bc32267be9eb34451748d2efd03f674b773000e92b
+SIZE (llvm-project-11.0.0.tar.xz) = 84792772
Index: head/devel/wasi-libcxx/pkg-descr
===================================================================
--- head/devel/wasi-libcxx/pkg-descr
+++ head/devel/wasi-libcxx/pkg-descr
@@ -0,0 +1,7 @@
+The LLVM Project is a collection of modular and reusable compiler and
+toolchain technologies.
+
+This port includes Clang builting for WASI
+(WebAssembly System Interface).
+
+WWW: http://llvm.org/
Index: head/devel/wasi-libcxx/pkg-plist
===================================================================
--- head/devel/wasi-libcxx/pkg-plist
+++ head/devel/wasi-libcxx/pkg-plist
@@ -0,0 +1,182 @@
+share/wasi-sysroot/include/c++/v1/__bit_reference
+share/wasi-sysroot/include/c++/v1/__bsd_locale_defaults.h
+share/wasi-sysroot/include/c++/v1/__bsd_locale_fallbacks.h
+share/wasi-sysroot/include/c++/v1/__config
+share/wasi-sysroot/include/c++/v1/__cxxabi_config.h
+share/wasi-sysroot/include/c++/v1/__debug
+share/wasi-sysroot/include/c++/v1/__errc
+share/wasi-sysroot/include/c++/v1/__functional_03
+share/wasi-sysroot/include/c++/v1/__functional_base
+share/wasi-sysroot/include/c++/v1/__functional_base_03
+share/wasi-sysroot/include/c++/v1/__hash_table
+share/wasi-sysroot/include/c++/v1/__libcpp_version
+share/wasi-sysroot/include/c++/v1/__locale
+share/wasi-sysroot/include/c++/v1/__mutex_base
+share/wasi-sysroot/include/c++/v1/__node_handle
+share/wasi-sysroot/include/c++/v1/__nullptr
+share/wasi-sysroot/include/c++/v1/__split_buffer
+share/wasi-sysroot/include/c++/v1/__sso_allocator
+share/wasi-sysroot/include/c++/v1/__std_stream
+share/wasi-sysroot/include/c++/v1/__string
+share/wasi-sysroot/include/c++/v1/__threading_support
+share/wasi-sysroot/include/c++/v1/__tree
+share/wasi-sysroot/include/c++/v1/__tuple
+share/wasi-sysroot/include/c++/v1/__undef_macros
+share/wasi-sysroot/include/c++/v1/algorithm
+share/wasi-sysroot/include/c++/v1/any
+share/wasi-sysroot/include/c++/v1/array
+share/wasi-sysroot/include/c++/v1/atomic
+share/wasi-sysroot/include/c++/v1/barrier
+share/wasi-sysroot/include/c++/v1/bit
+share/wasi-sysroot/include/c++/v1/bitset
+share/wasi-sysroot/include/c++/v1/cassert
+share/wasi-sysroot/include/c++/v1/ccomplex
+share/wasi-sysroot/include/c++/v1/cctype
+share/wasi-sysroot/include/c++/v1/cerrno
+share/wasi-sysroot/include/c++/v1/cfenv
+share/wasi-sysroot/include/c++/v1/cfloat
+share/wasi-sysroot/include/c++/v1/charconv
+share/wasi-sysroot/include/c++/v1/chrono
+share/wasi-sysroot/include/c++/v1/cinttypes
+share/wasi-sysroot/include/c++/v1/ciso646
+share/wasi-sysroot/include/c++/v1/climits
+share/wasi-sysroot/include/c++/v1/clocale
+share/wasi-sysroot/include/c++/v1/cmath
+share/wasi-sysroot/include/c++/v1/codecvt
+share/wasi-sysroot/include/c++/v1/compare
+share/wasi-sysroot/include/c++/v1/complex
+share/wasi-sysroot/include/c++/v1/complex.h
+share/wasi-sysroot/include/c++/v1/concepts
+share/wasi-sysroot/include/c++/v1/condition_variable
+share/wasi-sysroot/include/c++/v1/csetjmp
+share/wasi-sysroot/include/c++/v1/csignal
+share/wasi-sysroot/include/c++/v1/cstdarg
+share/wasi-sysroot/include/c++/v1/cstdbool
+share/wasi-sysroot/include/c++/v1/cstddef
+share/wasi-sysroot/include/c++/v1/cstdint
+share/wasi-sysroot/include/c++/v1/cstdio
+share/wasi-sysroot/include/c++/v1/cstdlib
+share/wasi-sysroot/include/c++/v1/cstring
+share/wasi-sysroot/include/c++/v1/ctgmath
+share/wasi-sysroot/include/c++/v1/ctime
+share/wasi-sysroot/include/c++/v1/ctype.h
+share/wasi-sysroot/include/c++/v1/cwchar
+share/wasi-sysroot/include/c++/v1/cwctype
+share/wasi-sysroot/include/c++/v1/cxxabi.h
+share/wasi-sysroot/include/c++/v1/deque
+share/wasi-sysroot/include/c++/v1/errno.h
+share/wasi-sysroot/include/c++/v1/exception
+share/wasi-sysroot/include/c++/v1/execution
+share/wasi-sysroot/include/c++/v1/experimental/__config
+share/wasi-sysroot/include/c++/v1/experimental/__memory
+share/wasi-sysroot/include/c++/v1/experimental/algorithm
+share/wasi-sysroot/include/c++/v1/experimental/coroutine
+share/wasi-sysroot/include/c++/v1/experimental/deque
+share/wasi-sysroot/include/c++/v1/experimental/filesystem
+share/wasi-sysroot/include/c++/v1/experimental/forward_list
+share/wasi-sysroot/include/c++/v1/experimental/functional
+share/wasi-sysroot/include/c++/v1/experimental/iterator
+share/wasi-sysroot/include/c++/v1/experimental/list
+share/wasi-sysroot/include/c++/v1/experimental/map
+share/wasi-sysroot/include/c++/v1/experimental/memory_resource
+share/wasi-sysroot/include/c++/v1/experimental/propagate_const
+share/wasi-sysroot/include/c++/v1/experimental/regex
+share/wasi-sysroot/include/c++/v1/experimental/set
+share/wasi-sysroot/include/c++/v1/experimental/simd
+share/wasi-sysroot/include/c++/v1/experimental/string
+share/wasi-sysroot/include/c++/v1/experimental/type_traits
+share/wasi-sysroot/include/c++/v1/experimental/unordered_map
+share/wasi-sysroot/include/c++/v1/experimental/unordered_set
+share/wasi-sysroot/include/c++/v1/experimental/utility
+share/wasi-sysroot/include/c++/v1/experimental/vector
+share/wasi-sysroot/include/c++/v1/ext/__hash
+share/wasi-sysroot/include/c++/v1/ext/hash_map
+share/wasi-sysroot/include/c++/v1/ext/hash_set
+share/wasi-sysroot/include/c++/v1/fenv.h
+share/wasi-sysroot/include/c++/v1/filesystem
+share/wasi-sysroot/include/c++/v1/float.h
+share/wasi-sysroot/include/c++/v1/forward_list
+share/wasi-sysroot/include/c++/v1/fstream
+share/wasi-sysroot/include/c++/v1/functional
+share/wasi-sysroot/include/c++/v1/future
+share/wasi-sysroot/include/c++/v1/initializer_list
+share/wasi-sysroot/include/c++/v1/inttypes.h
+share/wasi-sysroot/include/c++/v1/iomanip
+share/wasi-sysroot/include/c++/v1/ios
+share/wasi-sysroot/include/c++/v1/iosfwd
+share/wasi-sysroot/include/c++/v1/iostream
+share/wasi-sysroot/include/c++/v1/istream
+share/wasi-sysroot/include/c++/v1/iterator
+share/wasi-sysroot/include/c++/v1/latch
+share/wasi-sysroot/include/c++/v1/limits
+share/wasi-sysroot/include/c++/v1/limits.h
+share/wasi-sysroot/include/c++/v1/list
+share/wasi-sysroot/include/c++/v1/locale
+share/wasi-sysroot/include/c++/v1/locale.h
+share/wasi-sysroot/include/c++/v1/map
+share/wasi-sysroot/include/c++/v1/math.h
+share/wasi-sysroot/include/c++/v1/memory
+share/wasi-sysroot/include/c++/v1/module.modulemap
+share/wasi-sysroot/include/c++/v1/mutex
+share/wasi-sysroot/include/c++/v1/new
+share/wasi-sysroot/include/c++/v1/numbers
+share/wasi-sysroot/include/c++/v1/numeric
+share/wasi-sysroot/include/c++/v1/optional
+share/wasi-sysroot/include/c++/v1/ostream
+share/wasi-sysroot/include/c++/v1/queue
+share/wasi-sysroot/include/c++/v1/random
+share/wasi-sysroot/include/c++/v1/ratio
+share/wasi-sysroot/include/c++/v1/regex
+share/wasi-sysroot/include/c++/v1/scoped_allocator
+share/wasi-sysroot/include/c++/v1/semaphore
+share/wasi-sysroot/include/c++/v1/set
+share/wasi-sysroot/include/c++/v1/setjmp.h
+share/wasi-sysroot/include/c++/v1/shared_mutex
+share/wasi-sysroot/include/c++/v1/span
+share/wasi-sysroot/include/c++/v1/sstream
+share/wasi-sysroot/include/c++/v1/stack
+share/wasi-sysroot/include/c++/v1/stdbool.h
+share/wasi-sysroot/include/c++/v1/stddef.h
+share/wasi-sysroot/include/c++/v1/stdexcept
+share/wasi-sysroot/include/c++/v1/stdint.h
+share/wasi-sysroot/include/c++/v1/stdio.h
+share/wasi-sysroot/include/c++/v1/stdlib.h
+share/wasi-sysroot/include/c++/v1/streambuf
+share/wasi-sysroot/include/c++/v1/string
+share/wasi-sysroot/include/c++/v1/string.h
+share/wasi-sysroot/include/c++/v1/string_view
+share/wasi-sysroot/include/c++/v1/strstream
+share/wasi-sysroot/include/c++/v1/support/android/locale_bionic.h
+share/wasi-sysroot/include/c++/v1/support/fuchsia/xlocale.h
+share/wasi-sysroot/include/c++/v1/support/ibm/limits.h
+share/wasi-sysroot/include/c++/v1/support/ibm/locale_mgmt_aix.h
+share/wasi-sysroot/include/c++/v1/support/ibm/support.h
+share/wasi-sysroot/include/c++/v1/support/ibm/xlocale.h
+share/wasi-sysroot/include/c++/v1/support/musl/xlocale.h
+share/wasi-sysroot/include/c++/v1/support/newlib/xlocale.h
+share/wasi-sysroot/include/c++/v1/support/solaris/floatingpoint.h
+share/wasi-sysroot/include/c++/v1/support/solaris/wchar.h
+share/wasi-sysroot/include/c++/v1/support/solaris/xlocale.h
+share/wasi-sysroot/include/c++/v1/support/win32/limits_msvc_win32.h
+share/wasi-sysroot/include/c++/v1/support/win32/locale_win32.h
+share/wasi-sysroot/include/c++/v1/support/xlocale/__nop_locale_mgmt.h
+share/wasi-sysroot/include/c++/v1/support/xlocale/__posix_l_fallback.h
+share/wasi-sysroot/include/c++/v1/support/xlocale/__strtonum_fallback.h
+share/wasi-sysroot/include/c++/v1/system_error
+share/wasi-sysroot/include/c++/v1/tgmath.h
+share/wasi-sysroot/include/c++/v1/thread
+share/wasi-sysroot/include/c++/v1/tuple
+share/wasi-sysroot/include/c++/v1/type_traits
+share/wasi-sysroot/include/c++/v1/typeindex
+share/wasi-sysroot/include/c++/v1/typeinfo
+share/wasi-sysroot/include/c++/v1/unordered_map
+share/wasi-sysroot/include/c++/v1/unordered_set
+share/wasi-sysroot/include/c++/v1/utility
+share/wasi-sysroot/include/c++/v1/valarray
+share/wasi-sysroot/include/c++/v1/variant
+share/wasi-sysroot/include/c++/v1/vector
+share/wasi-sysroot/include/c++/v1/version
+share/wasi-sysroot/include/c++/v1/wchar.h
+share/wasi-sysroot/include/c++/v1/wctype.h
+share/wasi-sysroot/lib/wasm32-wasi/libc++.a
+share/wasi-sysroot/lib/wasm32-wasi/libc++abi.a
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Nov 11, 7:14 AM (12 h, 23 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
25147128
Default Alt Text
D22960.diff (34 KB)
Attached To
Mode
D22960: New ports for WebAssembly System Interface (WASI) libc, clang builtins (compiler-rt), libc++, libcxxabi
Attached
Detach File
Event Timeline
Log In to Comment