ports/textproc/apertium-separable/patches/patch-src_lsx_comp_cc

23 lines
481 B
Text

Index: src/lsx_comp.cc
--- src/lsx_comp.cc.orig
+++ src/lsx_comp.cc
@@ -2,6 +2,7 @@
#include <cerrno>
#include <iostream>
#include <stdlib.h>
+#include <unistd.h>
#include <lsx_compiler.h>
#include <lttoolbox/lt_locale.h>
@@ -20,6 +21,11 @@ void endProgram(char *name)
int main (int argc, char** argv)
{
+ if (pledge("stdio rpath wpath cpath", NULL) == -1) {
+ cerr << "pledge" << endl;
+ exit(EXIT_FAILURE);
+ }
+
if(argc < 4)
{
endProgram(argv[0]);