Skip to content

Commit f33bcb4

Browse files
committed
chore: add ci embedtest and fix errors
Signed-off-by: Daeyeon Jeong <[email protected]>
1 parent 9559ad2 commit f33bcb4

File tree

4 files changed

+30
-0
lines changed

4 files changed

+30
-0
lines changed

.github/workflows/actions.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,3 +130,29 @@ jobs:
130130
- name: Lint CC
131131
run: |
132132
tools/check_tidy.py --filter=$(paste -sd, tools/lint-filters.txt)
133+
134+
embedtest:
135+
runs-on: ubuntu-20.04
136+
timeout-minutes: 30
137+
strategy:
138+
fail-fast: false
139+
steps:
140+
- name: Checkout source
141+
uses: actions/checkout@v2
142+
with:
143+
submodules: true
144+
- name: Checkout Escargot
145+
run: |
146+
pushd deps/escargot
147+
git submodule update --init third_party
148+
popd
149+
- name: Install Packages
150+
run: |
151+
sudo apt update
152+
sudo apt install -y ninja-build gcc-multilib g++-multilib sed
153+
- name: Build liblwnode and embedtest
154+
run: |
155+
tools/build-embedtest.sh
156+
- name: Run embedtest
157+
run: |
158+
out/linux/Release/embedtest.x

src/api/stack-trace.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ class StackTrace {
4848
bool hasStackValue() { return stackValue_ != nullptr; }
4949

5050
void* operator new(size_t size) { return GC_MALLOC(size); }
51+
void operator delete(void* ptr) { GC_FREE(ptr); }
5152

5253
private:
5354
ArrayObjectRef* stackTrace_ = nullptr;

src/api/utils/logger/logger-util.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,10 @@
2323

2424
#define __FUNCTION_NAME__ getPrettyFunctionName(__PRETTY_FUNCTION__)
2525

26+
#ifndef __CODE_LOCATION__
2627
#define __CODE_LOCATION__ \
2728
createCodeLocation(__PRETTY_FUNCTION__, __FILE_NAME__, __LINE__).c_str()
29+
#endif
2830

2931
std::string createCodeLocation(const char* functionName,
3032
const char* filename,

test/embedding/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ project(embedtest)
44

55
include_directories("../../include/lwnode")
66
link_libraries(lwnode)
7+
add_compile_options(-std=c++17)
78

89
if (CMAKE_BUILD_TYPE STREQUAL "Debug")
910
add_compile_options(-O2 -g)

0 commit comments

Comments
 (0)