Merge branch 'add-illumos' of http://github.com/luka-devnull/kakoune into master
This commit is contained in:
commit
6a9b34e5c8
|
@ -80,6 +80,9 @@ else ifeq ($(os),OpenBSD)
|
||||||
else ifneq (,$(findstring CYGWIN,$(os)))
|
else ifneq (,$(findstring CYGWIN,$(os)))
|
||||||
CPPFLAGS += -D_XOPEN_SOURCE=700
|
CPPFLAGS += -D_XOPEN_SOURCE=700
|
||||||
LIBS += -lncursesw -ldbghelp
|
LIBS += -lncursesw -ldbghelp
|
||||||
|
else ifeq ($(os),SunOS)
|
||||||
|
LIBS += -lncursesw
|
||||||
|
LDFLAGS += -lsocket -rdynamic
|
||||||
else
|
else
|
||||||
ifeq ($(PKG_CONFIG),)
|
ifeq ($(PKG_CONFIG),)
|
||||||
$(error "pkg-config not found in PATH")
|
$(error "pkg-config not found in PATH")
|
||||||
|
|
|
@ -3,6 +3,10 @@
|
||||||
#include "flags.hh"
|
#include "flags.hh"
|
||||||
#include "ranges.hh"
|
#include "ranges.hh"
|
||||||
|
|
||||||
|
#if defined(__sun__)
|
||||||
|
#include <cstring>
|
||||||
|
#endif
|
||||||
|
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|
||||||
namespace Kakoune
|
namespace Kakoune
|
||||||
|
|
|
@ -654,6 +654,11 @@ String get_kak_binary_path()
|
||||||
return buffer;
|
return buffer;
|
||||||
#elif defined(__OpenBSD__)
|
#elif defined(__OpenBSD__)
|
||||||
return KAK_BIN_PATH;
|
return KAK_BIN_PATH;
|
||||||
|
#elif defined(__sun__)
|
||||||
|
ssize_t res = readlink("/proc/self/path/a.out", buffer, 2048);
|
||||||
|
kak_assert(res != -1);
|
||||||
|
buffer[res] = '\0';
|
||||||
|
return buffer;
|
||||||
#else
|
#else
|
||||||
# error "finding executable path is not implemented on this platform"
|
# error "finding executable path is not implemented on this platform"
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue
Block a user