mirror of
https://gitee.com/zlgopen/awtk.git
synced 2024-12-02 12:08:16 +08:00
merge
This commit is contained in:
commit
5dbea4fbdb
@ -60,6 +60,7 @@ SConscriptFiles=awtk.NANOVG_BACKEND_PROJS + [
|
||||
'tools/api_doc_lint/SConscript',
|
||||
'tools/preview_ui/SConscript',
|
||||
'tools/fdb/SConscript',
|
||||
'tools/dltest/SConscript',
|
||||
'demos/SConscript',
|
||||
'tests/SConscript',
|
||||
'src/hal/tools/network_shell/SConscript',
|
||||
|
@ -1,6 +1,7 @@
|
||||
# 最新动态
|
||||
|
||||
2023/07/12
|
||||
* add tools/dltest
|
||||
* 修复dialog高亮销毁时没有刷新区域的问题(感谢兆坤提供补丁)
|
||||
* 优化点击事件处理逻辑,确保pointer_down的widget是enable且sensitive的(感谢陈聪提供补丁)
|
||||
|
||||
|
@ -315,7 +315,11 @@ ret_t tk_init(wh_t w, wh_t h, app_type_t app_type, const char* app_name, const c
|
||||
return_value_if_fail(tk_init_internal() == RET_OK, RET_FAIL);
|
||||
|
||||
if (APP_CONSOLE == system_info()->app_type) {
|
||||
#ifndef AWTK_WEB
|
||||
loop = (main_loop_t*)main_loop_console_init();
|
||||
#else
|
||||
assert(!"not supported");
|
||||
#endif/*AWTK_WEB*/
|
||||
} else {
|
||||
loop = main_loop_init(w, h);
|
||||
}
|
||||
|
13
tools/dltest/SConscript
Normal file
13
tools/dltest/SConscript
Normal file
@ -0,0 +1,13 @@
|
||||
import os
|
||||
import copy
|
||||
import awtk_config as awtk
|
||||
|
||||
BIN_DIR=os.environ['BIN_DIR'];
|
||||
LIB_DIR=os.environ['LIB_DIR'];
|
||||
|
||||
env=DefaultEnvironment().Clone()
|
||||
|
||||
|
||||
LIBS=awtk.STATIC_LIBS
|
||||
|
||||
env.Program(os.path.join(BIN_DIR, 'dltest'), ['dltest.c'], LIBS=LIBS);
|
29
tools/dltest/dltest.c
Normal file
29
tools/dltest/dltest.c
Normal file
@ -0,0 +1,29 @@
|
||||
#include "tkc.h"
|
||||
|
||||
ret_t dltest(const char* filename, const char* func) {
|
||||
tk_dl_t* dl = tk_dl_open(filename);
|
||||
if(dl != NULL) {
|
||||
void* p = tk_dl_sym(dl, func);
|
||||
if(p != NULL) {
|
||||
log_debug("load %s %s ok\n", filename, func);
|
||||
} else {
|
||||
log_debug("get func failed:%s\n", tk_dl_error());
|
||||
}
|
||||
} else{
|
||||
log_debug("load dll failed:%s\n", tk_dl_error());
|
||||
}
|
||||
|
||||
return RET_OK;
|
||||
}
|
||||
|
||||
int main(int argc, char* argv[]) {
|
||||
platform_prepare();
|
||||
if(argc != 3) {
|
||||
log_debug("Usage: %s dll func\n", argv[0]);
|
||||
return 0;
|
||||
}
|
||||
|
||||
dltest(argv[1], argv[2]);
|
||||
|
||||
return 0;
|
||||
}
|
Loading…
Reference in New Issue
Block a user