aboutsummaryrefslogtreecommitdiffstats
path: root/testing/lowjs/lib-path.patch
diff options
context:
space:
mode:
authorJakub Jirutka <jakub@jirutka.cz>2019-12-25 20:32:29 +0100
committerJakub Jirutka <jakub@jirutka.cz>2019-12-25 20:30:55 +0100
commited20640a04872f7ab58e6e4428e1536b81141213 (patch)
tree94a4695dbd68d66d7df3350e3b02e9813de0fc3e /testing/lowjs/lib-path.patch
parent0f5e8e387acadcca36686b7ba0be4225c2b6518b (diff)
downloadaports-ed20640a04872f7ab58e6e4428e1536b81141213.tar.bz2
aports-ed20640a04872f7ab58e6e4428e1536b81141213.tar.xz
testing/lowjs: new aport
Diffstat (limited to 'testing/lowjs/lib-path.patch')
-rw-r--r--testing/lowjs/lib-path.patch33
1 files changed, 33 insertions, 0 deletions
diff --git a/testing/lowjs/lib-path.patch b/testing/lowjs/lib-path.patch
new file mode 100644
index 0000000000..e6711783e3
--- /dev/null
+++ b/testing/lowjs/lib-path.patch
@@ -0,0 +1,33 @@
+--- a/app/low_config.h
++++ b/app/low_config.h
+@@ -25,4 +25,8 @@
+
+ #define LOW_ESP32_LWIP_SPECIALITIES 0
+
++#ifndef LOW_LIB_PATH
++#define LOW_LIB_PATH "../lib/"
++#endif
++
+ #endif /* __LOW_CONFIG_H__ */
+--- a/app/main.cpp
++++ b/app/main.cpp
+@@ -37,7 +37,7 @@
+ if(*argc < 2)
+ return;
+
+- const char postfix[] = "../lib/low-exe";
++ const char postfix[] = LOW_LIB_PATH "/low-exe";
+ int len = strlen((*argv)[0]);
+ if(len < sizeof(postfix) || strcmp((*argv)[0] + len - (sizeof(postfix) - 1), postfix) != 0)
+ return;
+--- a/src/low_system.cpp
++++ b/src/low_system.cpp
+@@ -129,7 +129,7 @@
+
+ g_low_system.lib_path = NULL;
+
+- const char lib_add_path[] = "../lib/";
++ const char lib_add_path[] = LOW_LIB_PATH;
+ int lib_add_path_len = sizeof(lib_add_path) - 1;
+
+ #ifdef __APPLE__