1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-28 05:29:48 +00:00

- Update to 1.14.0

- Fix build on FreeBSD 12+ (lot of extra patch files)
- Remove obsolete patch file
- Update LLVM dependency to 7.0

Changelog at: https://github.com/ldc-developers/ldc/releases/tag/v1.14.0
This commit is contained in:
Jose Alonso Cardenas Marquez 2019-03-07 06:08:46 +00:00
parent 9a33226e6a
commit 290e722e92
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=494891
13 changed files with 277 additions and 62 deletions

View File

@ -1,7 +1,7 @@
# $FreeBSD$
PORTNAME= ldc
PORTVERSION= 1.12.0
PORTVERSION= 1.14.0
DISTVERSIONPREFIX= v
CATEGORIES= lang
@ -10,8 +10,8 @@ COMMENT= The LLVM-based D compiler
LICENSE= BSD3CLAUSE
BUILD_DEPENDS= llvm60>0:devel/llvm60
RUN_DEPENDS= llvm60>0:devel/llvm60
BUILD_DEPENDS= llvm70>0:devel/llvm70
RUN_DEPENDS= llvm70>0:devel/llvm70
LIB_DEPENDS= libconfig.so:devel/libconfig
BROKEN_aarch64= fails to compile: Error: undefined identifier _jmp_buf, did you mean alias jmp_buf?
@ -26,17 +26,17 @@ GH_PROJECT= ldc
GH_TUPLE= ldc-developers:ldc:911589c:tree/ltsmaster \
ldc-developers:druntime:694089c:druntimelts/ltsmaster/runtime/druntime \
ldc-developers:phobos:1d758b2:phoboslts/ltsmaster/runtime/phobos \
ldc-developers:druntime:b96540e:druntime/runtime/druntime \
ldc-developers:phobos:1c8a152:phobos/runtime/phobos
ldc-developers:druntime:54cb25c:druntime/runtime/druntime \
ldc-developers:phobos:71cf74f:phobos/runtime/phobos
CMAKE_ARGS+= -DD_COMPILER:STRING="${WRKSRC}/ltsmaster/bin/ldmd2" \
-DBUILD_SHARED_LIBS:STRING="BOTH"
CC= clang60
CXX= clang++60
CC= clang70
CXX= clang++70
BOOTVER= 0.17.6
LLVM_CONFIG= llvm-config60
LLVM_CONFIG= llvm-config70
LDCVER= ${PORTVERSION}
.include <bsd.port.pre.mk>
@ -45,6 +45,10 @@ LDCVER= ${PORTVERSION}
CFLAGS+= -fPIC
.endif
.if ${OPSYS} == FreeBSD && ${OSVERSION} > 1200029
EXTRA_PATCHES= ${PATCHDIR}/fbsd12-*
.endif
post-patch:
${REINPLACE_CMD} -e 's|$${llvm_config_names}|${LLVM_CONFIG}|g' \
${WRKSRC}/ltsmaster/cmake/Modules/FindLLVM.cmake \

View File

@ -1,13 +1,13 @@
TIMESTAMP = 1541394246
SHA256 (ldc-developers-ldc-v1.12.0_GH0.tar.gz) = cfa31cd1606b709c918d5e3d780e8a8e2912313e79b2d532174a14bebc3c1266
SIZE (ldc-developers-ldc-v1.12.0_GH0.tar.gz) = 1646050
TIMESTAMP = 1551800863
SHA256 (ldc-developers-ldc-v1.14.0_GH0.tar.gz) = daa7876ce846861cd9feb92f35dc0ca537a845492ca8a3eebecc9d166bc324b3
SIZE (ldc-developers-ldc-v1.14.0_GH0.tar.gz) = 1664660
SHA256 (ldc-developers-ldc-911589c_GH0.tar.gz) = c10ee47d857358ea97eccd14b49b4152c7b2621c0129eee1e8f98988f1d13f5e
SIZE (ldc-developers-ldc-911589c_GH0.tar.gz) = 1231073
SHA256 (ldc-developers-druntime-694089c_GH0.tar.gz) = 29b1a27f767ac9c8a0c30926991d9abcda119aaf923b05caa686a6c396ac0a83
SIZE (ldc-developers-druntime-694089c_GH0.tar.gz) = 953726
SHA256 (ldc-developers-phobos-1d758b2_GH0.tar.gz) = af70f2d4b09e0062ba986e215677f484c1cec2977a74ca1a73d3534a120992e9
SIZE (ldc-developers-phobos-1d758b2_GH0.tar.gz) = 1923043
SHA256 (ldc-developers-druntime-b96540e_GH0.tar.gz) = dbfadf3fa8790fe1c952c685103f08c8d995ce8d0253fa0b900553b462be55a9
SIZE (ldc-developers-druntime-b96540e_GH0.tar.gz) = 1643696
SHA256 (ldc-developers-phobos-1c8a152_GH0.tar.gz) = 7f630f36326687d2881935d0a8cbd05e03bf02c0f55ed8966a60f3b15b5bdf24
SIZE (ldc-developers-phobos-1c8a152_GH0.tar.gz) = 2344413
SHA256 (ldc-developers-druntime-54cb25c_GH0.tar.gz) = 47a71942f9f6d4c36d867eb2526a72aece36fb959cf99619e525cacb4951e864
SIZE (ldc-developers-druntime-54cb25c_GH0.tar.gz) = 1665530
SHA256 (ldc-developers-phobos-71cf74f_GH0.tar.gz) = fe01cb3decccde3c5aa0defcba715c283a1f11bf2bed6aedd0e33e43030c9c72
SIZE (ldc-developers-phobos-71cf74f_GH0.tar.gz) = 2355367

View File

@ -0,0 +1,14 @@
--- ltsmaster/runtime/druntime/src/core/sys/freebsd/sys/event.d 2018-08-21 18:55:47.000000000 +0000
+++ ltsmaster/runtime/druntime/src/core/sys/freebsd/sys/event.d 2019-03-06 04:06:16.750660000 +0000
@@ -46,8 +46,9 @@
short filter; /* filter for event */
ushort flags;
uint fflags;
- intptr_t data;
- void *udata; /* opaque user data identifier */
+ long data;
+ void* udata; /* opaque user data identifier */
+ ulong[4] ext;
}
enum

View File

@ -0,0 +1,59 @@
--- ltsmaster/runtime/druntime/src/core/sys/posix/sys/stat.d 2018-08-21 18:55:47.000000000 +0000
+++ ltsmaster/runtime/druntime/src/core/sys/posix/sys/stat.d 2019-03-06 04:13:18.999142000 +0000
@@ -714,32 +714,42 @@
{
struct stat_t
{
- dev_t st_dev;
- ino_t st_ino;
- mode_t st_mode;
- nlink_t st_nlink;
- uid_t st_uid;
- gid_t st_gid;
- dev_t st_rdev;
+ dev_t st_dev;
+ ino_t st_ino;
+ nlink_t st_nlink;
+ mode_t st_mode;
+ short st_padding0;
+ uid_t st_uid;
+ gid_t st_gid;
+ int st_padding1;
+ dev_t st_rdev;
+ version(X86) int st_atim_ext;
+
time_t st_atime;
c_long __st_atimensec;
+
+ version(X86) int st_mtim_ext;
+
time_t st_mtime;
c_long __st_mtimensec;
+
+ version(X86) int st_ctim_ext;
+
time_t st_ctime;
c_long __st_ctimensec;
- off_t st_size;
- blkcnt_t st_blocks;
- blksize_t st_blksize;
- fflags_t st_flags;
- uint st_gen;
- int st_lspare;
+ version(X86) int st_btim_ext;
time_t st_birthtime;
c_long st_birthtimensec;
- ubyte[16 - timespec.sizeof] padding;
+ off_t st_size;
+ blkcnt_t st_blocks;
+ blksize_t st_blksize;
+ fflags_t st_flags;
+ ulong st_gen;
+ ulong[10] st_spare;
}
enum S_IRUSR = 0x100; // octal 0000400

View File

@ -0,0 +1,19 @@
--- ltsmaster/runtime/druntime/src/core/sys/posix/sys/types.d 2019-03-06 04:17:35.909692000 +0000
+++ ltsmaster/runtime/druntime/src/core/sys/posix/sys/types.d 2019-03-06 04:18:41.162430000 +0000
@@ -124,12 +124,12 @@
else version( FreeBSD )
{
alias long blkcnt_t;
- alias uint blksize_t;
- alias uint dev_t;
+ alias ulong blksize_t;
+ alias ulong dev_t;
alias uint gid_t;
- alias uint ino_t;
+ alias ulong ino_t;
alias ushort mode_t;
- alias ushort nlink_t;
+ alias ulong nlink_t;
alias long off_t;
alias int pid_t;
//size_t (defined in core.stdc.stddef)

View File

@ -0,0 +1,17 @@
--- ltsmaster/runtime/druntime/src/core/sys/posix/dirent.d 2019-03-06 04:07:06.836421000 +0000
+++ ltsmaster/runtime/druntime/src/core/sys/posix/dirent.d 2019-03-06 04:08:34.306001000 +0000
@@ -131,10 +131,12 @@
align(4)
struct dirent
{
- uint d_fileno;
+ ino_t d_fileno;
+ off_t d_off;
ushort d_reclen;
ubyte d_type;
- ubyte d_namlen;
+ ushort d_namlen;
+ ushort d_pad1;
char[256] d_name;
}

View File

@ -0,0 +1,14 @@
--- runtime/druntime/src/core/sys/freebsd/sys/event.d 2019-02-15 17:20:40.000000000 +0000
+++ runtime/druntime/src/core/sys/freebsd/sys/event.d 2019-03-05 17:57:03.552667000 +0000
@@ -49,8 +49,9 @@
short filter; /* filter for event */
ushort flags;
uint fflags;
- intptr_t data;
- void *udata; /* opaque user data identifier */
+ long data;
+ void* udata; /* opaque user data identifier */
+ ulong[4] ext;
}
enum

View File

@ -0,0 +1,13 @@
--- runtime/druntime/src/core/sys/freebsd/sys/mount.d 2019-03-05 17:38:00.882617000 +0000
+++ runtime/druntime/src/core/sys/freebsd/sys/mount.d 2019-03-05 17:38:53.720464000 +0000
@@ -32,8 +32,8 @@
}
enum MFSNAMELEN = 16;
-enum MNAMELEN = 88;
-enum STATFS_VERSION = 0x20030518;
+enum MNAMELEN = 1024;
+enum STATFS_VERSION = 0x20140518;
struct statfs_t
{

View File

@ -0,0 +1,58 @@
--- runtime/druntime/src/core/sys/posix/sys/stat.d 2019-02-15 17:20:40.000000000 +0000
+++ runtime/druntime/src/core/sys/posix/sys/stat.d 2019-03-05 17:49:41.528876000 +0000
@@ -930,32 +930,41 @@
struct stat_t
{
- dev_t st_dev;
- ino_t st_ino;
- mode_t st_mode;
- nlink_t st_nlink;
- uid_t st_uid;
- gid_t st_gid;
- dev_t st_rdev;
+ dev_t st_dev;
+ ino_t st_ino;
+ nlink_t st_nlink;
+ mode_t st_mode;
+ short st_padding0;
+ uid_t st_uid;
+ gid_t st_gid;
+ int st_padding1;
+ dev_t st_rdev;
+ version(X86) int st_atim_ext;
time_t st_atime;
c_long __st_atimensec;
+
+ version(X86) int st_mtim_ext;
+
time_t st_mtime;
c_long __st_mtimensec;
+
+ version(X86) int st_ctim_ext;
+
time_t st_ctime;
c_long __st_ctimensec;
- off_t st_size;
- blkcnt_t st_blocks;
- blksize_t st_blksize;
- fflags_t st_flags;
- uint st_gen;
- int st_lspare;
+ version(X86) int st_btim_ext;
time_t st_birthtime;
c_long st_birthtimensec;
- ubyte[16 - timespec.sizeof] padding;
+ off_t st_size;
+ blkcnt_t st_blocks;
+ blksize_t st_blksize;
+ fflags_t st_flags;
+ ulong st_gen;
+ ulong[10] st_spare;
}
enum S_IRUSR = 0x100; // octal 0000400

View File

@ -0,0 +1,21 @@
--- runtime/druntime/src/core/sys/posix/sys/types.d 2019-02-15 17:20:40.000000000 +0000
+++ runtime/druntime/src/core/sys/posix/sys/types.d 2019-03-05 17:51:58.972306000 +0000
@@ -145,14 +145,13 @@
}
else version (FreeBSD)
{
- // https://github.com/freebsd/freebsd/blob/master/sys/sys/_types.h
alias long blkcnt_t;
- alias uint blksize_t;
- alias uint dev_t;
+ alias ulong blksize_t;
+ alias ulong dev_t;
alias uint gid_t;
- alias uint ino_t;
+ alias ulong ino_t;
alias ushort mode_t;
- alias ushort nlink_t;
+ alias ulong nlink_t;
alias long off_t;
alias int pid_t;
//size_t (defined in core.stdc.stddef)

View File

@ -0,0 +1,21 @@
--- runtime/druntime/src/core/sys/posix/dirent.d 2019-03-05 17:39:54.822687000 +0000
+++ runtime/druntime/src/core/sys/posix/dirent.d 2019-03-05 17:41:19.267583000 +0000
@@ -152,11 +152,13 @@
align(4)
struct dirent
{
- uint d_fileno;
- ushort d_reclen;
- ubyte d_type;
- ubyte d_namlen;
- char[256] d_name;
+ ino_t d_fileno;
+ off_t d_off;
+ ushort d_reclen;
+ ubyte d_type;
+ ushort d_namlen;
+ ushort d_pad1;
+ char[256] d_name;
}
alias void* DIR;

View File

@ -1,17 +0,0 @@
--- runtime/CMakeLists.txt 2018-11-05 00:21:57.581109000 -0500
+++ runtime/CMakeLists.txt 2018-11-05 00:24:29.799281000 -0500
@@ -436,10 +436,13 @@
# Sets up the targets for building the Phobos D object files, appending the
# names of the (bitcode) files to link into the library to outlist_o (outlist_bc).
macro(compile_phobos2 d_flags lib_suffix path_suffix emit_bc all_at_once outlist_o outlist_bc)
+ if(NOT ${BUILD_SHARED_LIBS} STREQUAL "OFF")
+ set(RELOCATION_FLAGS -relocation-model=pic)
+ endif()
get_target_suffix("${lib_suffix}" "${path_suffix}" target_suffix)
dc("${PHOBOS2_D}"
"${PHOBOS2_DIR}"
- "-conf=;${d_flags};-I${RUNTIME_DIR}/src;-I${PHOBOS2_DIR}"
+ "-conf=;${d_flags};${RELOCATION_FLAGS};-I${RUNTIME_DIR}/src;-I${PHOBOS2_DIR}"
"${PROJECT_BINARY_DIR}/objects${target_suffix}"
"${emit_bc}"
"${all_at_once}"

View File

@ -19,6 +19,7 @@ include/d/core/internal/parseoptions.d
include/d/core/internal/spinlock.d
include/d/core/internal/string.d
include/d/core/internal/traits.d
include/d/core/internal/utf.d
include/d/core/math.d
include/d/core/memory.d
include/d/core/runtime.d
@ -27,7 +28,6 @@ include/d/core/stdc/assert_.d
include/d/core/stdc/complex.d
include/d/core/stdc/config.d
include/d/core/stdc/ctype.d
include/d/core/stdc/errno.c
include/d/core/stdc/errno.d
include/d/core/stdc/fenv.d
include/d/core/stdc/float_.d
@ -46,8 +46,11 @@ include/d/core/stdc/tgmath.d
include/d/core/stdc/time.d
include/d/core/stdc/wchar_.d
include/d/core/stdc/wctype.d
include/d/core/stdcpp/array.d
include/d/core/stdcpp/exception.d
include/d/core/stdcpp/string_view.d
include/d/core/stdcpp/typeinfo.d
include/d/core/stdcpp/xutility.d
include/d/core/sync/barrier.d
include/d/core/sync/condition.d
include/d/core/sync/config.d
@ -57,6 +60,7 @@ include/d/core/sync/rwmutex.d
include/d/core/sync/semaphore.d
include/d/core/sys/bionic/fcntl.d
include/d/core/sys/bionic/unistd.d
include/d/core/sys/darwin/crt_externs.d
include/d/core/sys/darwin/dlfcn.d
include/d/core/sys/darwin/execinfo.d
include/d/core/sys/darwin/mach/dyld.d
@ -102,6 +106,7 @@ include/d/core/sys/freebsd/sys/link_elf.d
include/d/core/sys/freebsd/sys/mman.d
include/d/core/sys/freebsd/sys/mount.d
include/d/core/sys/freebsd/time.d
include/d/core/sys/freebsd/unistd.d
include/d/core/sys/linux/config.d
include/d/core/sys/linux/dlfcn.d
include/d/core/sys/linux/elf.d
@ -143,19 +148,6 @@ include/d/core/sys/netbsd/sys/link_elf.d
include/d/core/sys/netbsd/sys/mman.d
include/d/core/sys/netbsd/time.d
include/d/core/sys/openbsd/dlfcn.d
include/d/core/sys/osx/dlfcn.d
include/d/core/sys/osx/execinfo.d
include/d/core/sys/osx/mach/dyld.d
include/d/core/sys/osx/mach/getsect.d
include/d/core/sys/osx/mach/kern_return.d
include/d/core/sys/osx/mach/loader.d
include/d/core/sys/osx/mach/port.d
include/d/core/sys/osx/mach/semaphore.d
include/d/core/sys/osx/mach/thread_act.d
include/d/core/sys/osx/pthread.d
include/d/core/sys/osx/sys/cdefs.d
include/d/core/sys/osx/sys/event.d
include/d/core/sys/osx/sys/mman.d
include/d/core/sys/posix/aio.d
include/d/core/sys/posix/arpa/inet.d
include/d/core/sys/posix/config.d
@ -178,6 +170,7 @@ include/d/core/sys/posix/sched.d
include/d/core/sys/posix/semaphore.d
include/d/core/sys/posix/setjmp.d
include/d/core/sys/posix/signal.d
include/d/core/sys/posix/spawn.d
include/d/core/sys/posix/stdio.d
include/d/core/sys/posix/stdlib.d
include/d/core/sys/posix/sys/filio.d
@ -387,7 +380,6 @@ include/d/core/sys/windows/winver.d
include/d/core/sys/windows/wtsapi32.d
include/d/core/sys/windows/wtypes.d
include/d/core/thread.d
include/d/core/threadasm.S
include/d/core/time.d
include/d/core/vararg.d
include/d/etc/c/curl.d
@ -398,13 +390,10 @@ include/d/etc/c/odbc/sqlucode.d
include/d/etc/c/sqlite3.d
include/d/etc/c/zlib.d
include/d/etc/linux/memoryerror.d
include/d/ldc/arm_unwind.c
include/d/ldc/arrayinit.d
include/d/ldc/asan.d
include/d/ldc/attributes.d
include/d/ldc/dcompute.d
include/d/ldc/dynamic_compile.d
include/d/ldc/eh_asm.S
include/d/ldc/eh_msvc.d
include/d/ldc/gccbuiltins_aarch64.di
include/d/ldc/gccbuiltins_arm.di
@ -416,10 +405,11 @@ include/d/ldc/internal/vararg.di
include/d/ldc/intrinsics.di
include/d/ldc/libfuzzer.di
include/d/ldc/llvmasm.di
include/d/ldc/msvc.c
include/d/ldc/object.d
include/d/ldc/profile.di
include/d/ldc/sanitizer_common.d
include/d/ldc/sanitizers_optionally_linked.d
include/d/ldc/simd.di
include/d/object.d
include/d/std/algorithm/comparison.d
include/d/std/algorithm/internal.d
include/d/std/algorithm/iteration.d
@ -498,6 +488,7 @@ include/d/std/file.d
include/d/std/format.d
include/d/std/functional.d
include/d/std/getopt.d
include/d/std/internal/attributes.d
include/d/std/internal/cstring.d
include/d/std/internal/digest/sha_SSSE3.d
include/d/std/internal/math/biguintarm.d
@ -506,6 +497,7 @@ include/d/std/internal/math/biguintnoasm.d
include/d/std/internal/math/biguintx86.d
include/d/std/internal/math/errorfunction.d
include/d/std/internal/math/gammafunction.d
include/d/std/internal/memory.d
include/d/std/internal/scopebuffer.d
include/d/std/internal/test/dummyrange.d
include/d/std/internal/test/range.d
@ -562,23 +554,23 @@ include/d/std/xml.d
include/d/std/zip.d
include/d/std/zlib.d
lib/libdruntime-ldc-debug-shared.so
lib/libdruntime-ldc-debug-shared.so.2.0.82
lib/libdruntime-ldc-debug-shared.so.82
lib/libdruntime-ldc-debug-shared.so.2.0.84
lib/libdruntime-ldc-debug-shared.so.84
lib/libdruntime-ldc-debug.a
lib/libdruntime-ldc-shared.so
lib/libdruntime-ldc-shared.so.2.0.82
lib/libdruntime-ldc-shared.so.82
lib/libdruntime-ldc-shared.so.2.0.84
lib/libdruntime-ldc-shared.so.84
lib/libdruntime-ldc.a
lib/libldc-jit-rt.a
lib/libldc-jit.so
lib/libldc-jit.so.2.0.82
lib/libldc-jit.so.82
lib/libldc-jit.so.2.0.84
lib/libldc-jit.so.84
lib/libphobos2-ldc-debug-shared.so
lib/libphobos2-ldc-debug-shared.so.2.0.82
lib/libphobos2-ldc-debug-shared.so.82
lib/libphobos2-ldc-debug-shared.so.2.0.84
lib/libphobos2-ldc-debug-shared.so.84
lib/libphobos2-ldc-debug.a
lib/libphobos2-ldc-shared.so
lib/libphobos2-ldc-shared.so.2.0.82
lib/libphobos2-ldc-shared.so.82
lib/libphobos2-ldc-shared.so.2.0.84
lib/libphobos2-ldc-shared.so.84
lib/libphobos2-ldc.a
@dir include/d/etc/c/zlib