Skip to content

Commit

Permalink
Update cmake-open-watcom.yml
Browse files Browse the repository at this point in the history
.
  • Loading branch information
jmalak committed Nov 8, 2024
1 parent 6acec23 commit 172f8eb
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 3 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/cmake-open-watcom.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,8 @@ jobs:
# Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make.
# See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type
run: >
cmake -B build -S wolfssl/src -G "Watcom WMake" -D CMAKE_SYSTEM_NAME=${{ matrix.os }} -D CMAKE_SYSTEM_PROCESSOR=x86
mkdir build
cmake -B build -G "Watcom WMake" -D CMAKE_SYSTEM_NAME=${{ matrix.os }} -D CMAKE_SYSTEM_PROCESSOR=x86
- name: Build
# Build your program with the given configuration. Note that --config is needed because the default Windows generator is a multi-config generator (Visual Studio generator).
run: cmake -B build -S wolfssl/src -G "Watcom WMake" --config ${{ matrix.build_type }}
run: cmake -B build -G "Watcom WMake" --config ${{ matrix.build_type }}
15 changes: 14 additions & 1 deletion wolfssl/wolfcrypt/types.h
Original file line number Diff line number Diff line change
Expand Up @@ -1539,6 +1539,19 @@ typedef struct w64wrapper {
typedef unsigned int THREAD_RETURN;
typedef TaskHandle_t THREAD_TYPE;
#define WOLFSSL_THREAD
#elif defined(__WATCOMC__)
typedef unsigned THREAD_RETURN;
typedef uintptr_t THREAD_TYPE;
typedef struct COND_TYPE {
wolfSSL_Mutex mutex;
HANDLE cond;
} COND_TYPE;
#define WOLFSSL_COND
#define INVALID_THREAD_VAL ((THREAD_TYPE)(INVALID_HANDLE_VALUE))
#if defined(USE_WINDOWS_API)
#define WOLFSSL_THREAD __stdcall
#endif
#define WOLFSSL_THREAD_NO_JOIN __watcall
#elif defined(USE_WINDOWS_API)
typedef unsigned THREAD_RETURN;
typedef uintptr_t THREAD_TYPE;
Expand Down Expand Up @@ -1613,7 +1626,7 @@ typedef struct w64wrapper {
/* Create a thread that will be automatically cleaned up. We can't
* return a handle/pointer to the new thread because there are no
* guarantees for how long it will be valid. */
typedef THREAD_RETURN (WOLFSSL_THREAD_NO_JOIN *THREAD_CB_NOJOIN)
typedef void (WOLFSSL_THREAD_NO_JOIN *THREAD_CB_NOJOIN)
(void* arg);
WOLFSSL_API int wolfSSL_NewThreadNoJoin(THREAD_CB_NOJOIN cb,
void* arg);
Expand Down

0 comments on commit 172f8eb

Please sign in to comment.