# libevent **Repository Path**: chenzhenyu27/libevent ## Basic Information - **Project Name**: libevent - **Description**: No description available - **Primary Language**: Unknown - **License**: MIT - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 4 - **Created**: 2022-05-26 - **Last Updated**: 2024-05-29 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # Libevent 本项目主要是对原libevent库进行ohos版本的编译适配,使其能够在ohos版本上正常使用,不对其原有逻辑进行修改。原项目链接可参考https://github.com/libevent/libevent ### 项目介绍 - 项目名称:libevent - 所属系列:C++库的ohos适配 - 功能:C语言的事件通知库 - 项目适配状态:完成 - 调用差异:无 - 项目作者和维护人:hihope - 联系方式:hihope@hoperun.com - 参考项目地址:https://github.com/libevent/libevent - 原项目版本:master - 编程语言:C/C++ ### 编译方式 准备一套完整的openharmony 3.1beta代码 1. 库代码存放路径:./third_party/libevent 2. 修改添加依赖的编译脚本 在/developtools/bytrace_standard/ohos.build文件中添加修改 "//third_party/libevent:libevent_targets","//third_party/libevent:libevent_test" ``` { "subsystem": "developtools", "parts": { "bytrace_standard": { "module_list": [ "//developtools/bytrace_standard/interfaces/innerkits/native:bytrace_core", "//developtools/bytrace_standard/bin:bytrace_target", "//developtools/bytrace_standard/bin:bytrace.cfg", "//developtools/bytrace_standard/interfaces/kits/js/napi:bytrace", "//third_party/libevent:libevent_targets", "//third_party/libevent:libevent_test" ], "inner_kits": [ { "type": "so", "name": "//developtools/bytrace_standard/interfaces/innerkits/native:bytrace_core", "header": { "header_files": [ "bytrace.h" ], "header_base": "//developtools/bytrace_standard/interfaces/innerkits/native/include" } } ], "test_list": [ "//developtools/bytrace_standard/bin/test:unittest" ] } } } ``` 3. 用命令 ./build.sh --product-name rk3568 --ccache 编译 4. 生成库文件路径: out/rk3568/developtools/profiler(该路径生成库文件) out/rk3568/common/common (该路径生成生成可执行测试文件)