Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F148179232
D42978.1785669986.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D42978.1785669986.diff
View Options
diff --git a/math/stp/Makefile b/math/stp/Makefile
--- a/math/stp/Makefile
+++ b/math/stp/Makefile
@@ -1,6 +1,6 @@
PORTNAME= stp
DISTVERSION= 2.3.3
-PORTREVISION= 11
+PORTREVISION= 12
PORTEPOCH= 1
CATEGORIES= math
@@ -11,9 +11,6 @@
LICENSE= MIT
LICENSE_FILE= ${WRKSRC}/LICENSE
-BROKEN_aarch64= fails to link: missing sbrk
-BROKEN_riscv64= fails to link: missing sbrk
-
LIB_DEPENDS= libboost_program_options.so:devel/boost-libs \
libminisat.so:math/minisat \
libcryptominisat5.so:math/cryptominisat
diff --git a/math/stp/files/patch-tools_stp_main__common.cpp b/math/stp/files/patch-tools_stp_main__common.cpp
new file mode 100644
--- /dev/null
+++ b/math/stp/files/patch-tools_stp_main__common.cpp
@@ -0,0 +1,45 @@
+--- tools/stp/main_common.cpp.orig
++++ tools/stp/main_common.cpp
+@@ -27,16 +27,8 @@
+ #include "stp/Parser/parser.h"
+ #include "stp/cpp_interface.h"
+
+-//for srbk() function
+-#if !defined(__MINGW32__) && !defined(__MINGW64__) && !defined(_MSC_VER)
+-#include <unistd.h>
+-#endif
+-
+ extern void errorHandler(const char* error_msg);
+
+-// Amount of memory to ask for at beginning of main.
+-extern const intptr_t INITIAL_MEMORY_PREALLOCATION_SIZE;
+-
+ using namespace stp;
+ using std::unique_ptr;
+ using std::cout;
+@@ -49,9 +41,6 @@
+ exit(-1);
+ }
+
+-// Amount of memory to ask for at beginning of main.
+-const intptr_t INITIAL_MEMORY_PREALLOCATION_SIZE = 4000000;
+-
+ Main::Main() : onePrintBack(false)
+ {
+ bm = NULL;
+@@ -62,15 +51,6 @@
+
+ // Register the error handler
+ vc_error_hdlr = errorHandler;
+-
+-#if !defined(__MINGW32__) && !defined(__MINGW64__) && !defined(_MSC_VER)
+- // Grab some memory from the OS upfront to reduce system time when
+- // individual hash tables are being allocated
+- if (sbrk(INITIAL_MEMORY_PREALLOCATION_SIZE) == ((void*)-1))
+- {
+- FatalError("Initial allocation of memory failed.");
+- }
+-#endif
+
+ bm = new STPMgr();
+ GlobalParserBM = bm;
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Aug 2, 11:26 AM (19 h, 52 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
29336052
Default Alt Text
D42978.1785669986.diff (1 KB)
Attached To
Mode
D42978: math/stp: remove nonsensical sbrk use
Attached
Detach File
Event Timeline
Log In to Comment