1
0
mirror of https://github.com/Ylianst/MeshAgent synced 2025-12-10 13:23:41 +00:00

Updated for OpenBSD

This commit is contained in:
Bryan Roe
2021-08-30 12:06:36 -07:00
parent b496e192d9
commit 67a949207f
5 changed files with 43 additions and 1 deletions

View File

@@ -34,6 +34,11 @@ limitations under the License.
#include "microscript/ILibDuktape_Commit.h"
MeshAgentHostContainer *agentHost = NULL;
#ifdef _OPENBSD
#include <stdlib.h>
char __agentExecPath[1024] = { 0 };
#endif
#ifdef WIN32
BOOL CtrlHandler(DWORD fdwCtrlType)
@@ -81,6 +86,10 @@ int wmain(int argc, char **wargv)
int main(int argc, char **argv)
#endif
{
#ifdef _OPENBSD
realpath(argv[0], __agentExecPath);
#endif
// Check if .JS file is integrated with executable
char *integratedJavaScript = NULL;
int integratedJavaScriptLen = 0;