mirror of
https://github.com/pine64/blisp.git
synced 2025-01-18 03:30:13 +00:00
Fix Windows CI build
This commit is contained in:
parent
5a6cd281c3
commit
5e09eca00d
4
.github/workflows/build.yml
vendored
4
.github/workflows/build.yml
vendored
@ -3,7 +3,7 @@ on: [push, pull_request]
|
||||
|
||||
jobs:
|
||||
build-windows:
|
||||
runs-on: windows-2019
|
||||
runs-on: windows-2022
|
||||
defaults:
|
||||
run:
|
||||
shell: cmd
|
||||
@ -22,7 +22,7 @@ jobs:
|
||||
with:
|
||||
name: blisp Windows x64 build
|
||||
path: |
|
||||
build/tools/blisp/blisp.exe
|
||||
build/tools/blisp/Release/blisp.exe
|
||||
if-no-files-found: error
|
||||
|
||||
build-macos:
|
||||
|
@ -39,7 +39,8 @@ target_sources(libblisp_obj PRIVATE
|
||||
target_include_directories(libblisp_obj PRIVATE ${CMAKE_SOURCE_DIR}/vendor/libserialport)
|
||||
|
||||
if(WIN32)
|
||||
target_link_libraries(libblisp_obj PRIVATE Setupapi.lib)
|
||||
target_link_libraries(libblisp PRIVATE Setupapi.lib)
|
||||
target_link_libraries(libblisp_static PRIVATE Setupapi.lib)
|
||||
target_compile_definitions(libblisp_obj PRIVATE LIBSERIALPORT_MSBUILD)
|
||||
target_sources(libblisp_obj PRIVATE
|
||||
${CMAKE_SOURCE_DIR}/vendor/libserialport/windows.c)
|
||||
|
@ -66,7 +66,11 @@ int32_t blisp_easy_load_segment_data(
|
||||
|
||||
uint32_t sent_data = 0;
|
||||
uint32_t buffer_size = 0;
|
||||
#ifdef _WIN32
|
||||
uint8_t buffer[4092];
|
||||
#else
|
||||
uint8_t buffer[buffer_max_size];
|
||||
#endif
|
||||
|
||||
blisp_easy_report_progress(progress_callback, 0, segment_size);
|
||||
|
||||
@ -333,7 +337,11 @@ int32_t blisp_easy_flash_write(struct blisp_device* device,
|
||||
|
||||
uint32_t sent_data = 0;
|
||||
uint32_t buffer_size = 0;
|
||||
#ifdef _WIN32
|
||||
uint8_t buffer[2052];
|
||||
#else
|
||||
uint8_t buffer[buffer_max_size];
|
||||
#endif
|
||||
blisp_easy_report_progress(progress_callback, 0, data_size);
|
||||
|
||||
while (sent_data < data_size) {
|
||||
|
Loading…
Reference in New Issue
Block a user