Skip to content

Commit 296b975

Browse files
authored
Merge pull request #19326 from ararslan/aa/freebsd
Patch the libunwind tests on FreeBSD
2 parents 75d982d + 2eebdf7 commit 296b975

File tree

3 files changed

+17
-2
lines changed

3 files changed

+17
-2
lines changed

README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,6 @@ You must use the `gmake` command on FreeBSD instead of `make`.
245245
Note that Julia is community-supported and we have little control over our upstream dependencies, you may still run into issues with dependencies and YMMV. Current known issues include:
246246

247247
- The x86 arch doesn't support threading due to lack of compiler runtime library support (set `JULIA_THREADS=0`).
248-
- libunwind needs a small patch to its tests to compile.
249248
- OpenBLAS patches in pkg haven't been upstreamed.
250249
- gfortran can't link binaries. Set `FFLAGS=-Wl,-rpath,/usr/local/lib/gcc6` to work around this (upstream bug submitted to FreeBSD pkg maintainers).
251250
- System libraries installed by pkg are not on the compiler path by default. You may need to add `LDFLAGS=-L/usr/local/lib` and `CPPFLAGS=-I/usr/local/include` to your environment or `Make.user` file to build successfully.
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
--- tests/mapper.c 2014-10-06 14:46:27.000000000 -0400
2+
+++ tests/mapper.c 2014-10-06 14:47:00.000000000 -0400
3+
@@ -39,6 +39,9 @@ WITH THE SOFTWARE OR THE USE OR OTHER DE
4+
#if !defined(MAP_ANONYMOUS) && defined(MAP_ANON)
5+
# define MAP_ANONYMOUS MAP_ANON
6+
#endif
7+
+#if !defined(MAP_NORESERVE)
8+
+# define MAP_NORESERVE 0
9+
+#endif
10+
11+
int
12+
main (void)

deps/unwind.mk

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,11 @@ $(SRCDIR)/srccache/libunwind-$(UNWIND_VER)/libunwind-arm-pc-offset.patch-applied
2828
cd $(SRCDIR)/srccache/libunwind-$(UNWIND_VER) && patch -p1 -f < $(SRCDIR)/patches/libunwind-arm-pc-offset.patch
2929
echo 1 > $@
3030

31-
$(BUILDDIR)/libunwind-$(UNWIND_VER)/build-configured: $(SRCDIR)/srccache/libunwind-$(UNWIND_VER)/source-extracted $(SRCDIR)/srccache/libunwind-$(UNWIND_VER)/libunwind-arm-pc-offset.patch-applied
31+
$(SRCDIR)/srccache/libunwind-$(UNWIND_VER)/libunwind-freebsd-mapper.patch-applied: $(SRCDIR)/srccache/libunwind-$(UNWIND_VER)/libunwind-arm-pc-offset.patch-applied
32+
cd $(SRCDIR)/srccache/libunwind-$(UNWIND_VER) && patch -p0 -f < $(SRCDIR)/patches/libunwind-freebsd-mapper.patch
33+
echo 1 > $@
34+
35+
$(BUILDDIR)/libunwind-$(UNWIND_VER)/build-configured: $(SRCDIR)/srccache/libunwind-$(UNWIND_VER)/source-extracted $(SRCDIR)/srccache/libunwind-$(UNWIND_VER)/libunwind-freebsd-mapper.patch-applied
3236
mkdir -p $(dir $@)
3337
cd $(dir $@) && \
3438
$(dir $<)/configure $(CONFIGURE_COMMON) CPPFLAGS="$(CPPFLAGS) $(LIBUNWIND_CPPFLAGS)" CFLAGS="$(CFLAGS) $(LIBUNWIND_CFLAGS)" --disable-shared --disable-minidebuginfo

0 commit comments

Comments
 (0)