File tree Expand file tree Collapse file tree
linux64ARMv8/squeak.cog.spur/build
linux64x64/squeak.cog.spur/build Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -9,6 +9,10 @@ OPT="-g -O2 -DNDEBUG -DDEBUGVM=0 -D_GNU_SOURCE -DUSEEVDEV"
99# #OPT="-g -O3 -DMUSL -DNDEBUG -DDEBUGVM=0"
1010
1111if [ ` uname` = " OpenBSD" ]; then
12+ OPT=" $OPT -DMUSL"
13+ CFLAGS=" $CFLAGS $OPT -I/usr/local/include"
14+ LIBS=" $LIBS -lexecinfo"
15+ LDFLAGS=" $LDFLAGS -L/usr/local/lib"
1216 DUALMAP=" -DDUAL_MAPPED_CODE_ZONE=0"
1317# librt and libpthread functions now supplied by libc.
1418# Many Linux systems supply empty library files but
Original file line number Diff line number Diff line change @@ -13,15 +13,16 @@ if [ -n "$(command -v clang || true)" ]; then CC=clang; else CC=gcc; fi
1313# but OpenBSD does not.
1414if [ ` uname` = " OpenBSD" ]; then LIBRT=" " ; else LIBRT=" -lrt" ; fi
1515
16- CFLAGS=" $OPT -msse2 -DCOGMTVM=0"
17- LIBS=$LIBRT
18- LDFLAGS=" "
19-
2016# Special treatment for OpenBSD Linux
2117if [ ` uname` = " OpenBSD" ]; then
22- CFLAGS=" $CFLAGS -I/usr/local/include"
18+ OPT=" $OPT -DMUSL"
19+ CFLAGS=" $CFLAGS $OPT -I/usr/local/include"
2320 LIBS=" $LIBS -lexecinfo"
2421 LDFLAGS=" $LDFLAGS -L/usr/local/lib"
22+ else
23+ CFLAGS=" $CFLAGS $OPT -msse2 -DCOGMTVM=0"
24+ LIBS=" $LIBS -lrt"
25+ LDFLAGS=" $LDFLAGS "
2526fi
2627
2728if [ $# -ge 1 ]; then
Original file line number Diff line number Diff line change @@ -87,7 +87,11 @@ int mmapErrno = 0;
8787#endif
8888
8989#define MAP_PROT (PROT_READ | PROT_WRITE)
90+ #ifdef __OpenBSD__
91+ #define MAP_FLAGS (MAP_ANON | MAP_PRIVATE | MAP_STACK)
92+ #else
9093#define MAP_FLAGS (MAP_ANON | MAP_PRIVATE)
94+ #endif
9195
9296extern int useMmap ;
9397/* Since Cog needs to make memory executable via mprotect, and since mprotect
You can’t perform that action at this time.
0 commit comments