diff options
-rwxr-xr-x | extantz.sh | 4 | ||||
-rw-r--r-- | lib/skang.lua | 1 | ||||
-rwxr-xr-x | src/GuiLua/test.sh | 1 | ||||
-rw-r--r-- | src/libraries/SledjHamr.c | 13 | ||||
-rw-r--r-- | src/libraries/SledjHamr.h | 3 |
5 files changed, 17 insertions, 5 deletions
@@ -2,6 +2,6 @@ | |||
2 | 2 | ||
3 | wd=$(pwd) | 3 | wd=$(pwd) |
4 | 4 | ||
5 | export LUA_PATH="$wd/lib/?.lua;$wd/src/GuiLua/?.lua" | 5 | export LUA_PATH="$wd/src/GuiLua/?.lua" |
6 | export LUA_CPATH="$wd/lib/lib?.so;$wd/lib/?.so;$wd/src/GuiLua/?.so" | 6 | export LUA_CPATH="$wd/src/GuiLua/?.so" |
7 | ./extantz | 7 | ./extantz |
diff --git a/lib/skang.lua b/lib/skang.lua index 33ae895..0f91e44 100644 --- a/lib/skang.lua +++ b/lib/skang.lua | |||
@@ -1012,7 +1012,6 @@ end | |||
1012 | 1012 | ||
1013 | -- Get our C functions installed into skang. | 1013 | -- Get our C functions installed into skang. |
1014 | -- This has to be after thingasm is defined. | 1014 | -- This has to be after thingasm is defined. |
1015 | package.cpath = package.cpath .. ';./lib/lib?.so;../lib/lib?.so;../../lib/lib?.so' | ||
1016 | local GuiLua = require 'GuiLua' | 1015 | local GuiLua = require 'GuiLua' |
1017 | 1016 | ||
1018 | 1017 | ||
diff --git a/src/GuiLua/test.sh b/src/GuiLua/test.sh index 0cf39d9..30e8742 100755 --- a/src/GuiLua/test.sh +++ b/src/GuiLua/test.sh | |||
@@ -2,5 +2,4 @@ | |||
2 | 2 | ||
3 | wd=$(pwd) | 3 | wd=$(pwd) |
4 | 4 | ||
5 | export LUA_PATH="$wd/../../lib/?.lua;./?.lua" | ||
6 | ../../skang -l test -foo "argy bargy" | 5 | ../../skang -l test -foo "argy bargy" |
diff --git a/src/libraries/SledjHamr.c b/src/libraries/SledjHamr.c index aa68774..6137199 100644 --- a/src/libraries/SledjHamr.c +++ b/src/libraries/SledjHamr.c | |||
@@ -2,6 +2,8 @@ | |||
2 | 2 | ||
3 | void HamrTime(void *elm_main, char *domain) | 3 | void HamrTime(void *elm_main, char *domain) |
4 | { | 4 | { |
5 | char *env, cwd[PATH_MAX], temp[PATH_MAX * 2]; | ||
6 | |||
5 | elm_app_compile_bin_dir_set(PACKAGE_BIN_DIR); | 7 | elm_app_compile_bin_dir_set(PACKAGE_BIN_DIR); |
6 | elm_app_compile_data_dir_set(PACKAGE_DATA_DIR); | 8 | elm_app_compile_data_dir_set(PACKAGE_DATA_DIR); |
7 | elm_app_compile_lib_dir_set(PACKAGE_LIB_DIR); | 9 | elm_app_compile_lib_dir_set(PACKAGE_LIB_DIR); |
@@ -20,4 +22,15 @@ void HamrTime(void *elm_main, char *domain) | |||
20 | elm_app_info_set(elm_main, domain, "checkme.txt"); | 22 | elm_app_info_set(elm_main, domain, "checkme.txt"); |
21 | // Once this is all setup, the code can do - | 23 | // Once this is all setup, the code can do - |
22 | // elm_app_prefix_dir_get(); // or bin, lib, data, locale. | 24 | // elm_app_prefix_dir_get(); // or bin, lib, data, locale. |
25 | |||
26 | getcwd(cwd, PATH_MAX); | ||
27 | env = getenv("LUA_CPATH"); | ||
28 | if (!env) env = ""; | ||
29 | sprintf(temp, "%s;%s/lib?.so;%s/?.so;%s/?.so", env, elm_app_lib_dir_get(), elm_app_lib_dir_get(), cwd); | ||
30 | setenv("LUA_CPATH", temp, 1); | ||
31 | |||
32 | env = getenv("LUA_PATH"); | ||
33 | if (!env) env = ""; | ||
34 | sprintf(temp, "%s;%s/?.lua;%s/?.lua", env, elm_app_lib_dir_get(), cwd); | ||
35 | setenv("LUA_PATH", temp, 1); | ||
23 | } | 36 | } |
diff --git a/src/libraries/SledjHamr.h b/src/libraries/SledjHamr.h index 2351507..956b37e 100644 --- a/src/libraries/SledjHamr.h +++ b/src/libraries/SledjHamr.h | |||
@@ -8,7 +8,8 @@ | |||
8 | /* Enable access to unstable EFL EO API. */ | 8 | /* Enable access to unstable EFL EO API. */ |
9 | #define EFL_EO_API_SUPPORT 1 | 9 | #define EFL_EO_API_SUPPORT 1 |
10 | 10 | ||
11 | #include <ctype.h> | 11 | //#include <ctype.h> |
12 | #include <stdlib.h> | ||
12 | 13 | ||
13 | #include <Elementary.h> | 14 | #include <Elementary.h> |
14 | 15 | ||