Skip to content

Commit

Permalink
Merge pull request #11 from daisukekoba/fix/decrypt
Browse files Browse the repository at this point in the history
MSVCではmulti2.c, multi2_simd.cを、MinGW/Linuxではmulti2.ccを使う
  • Loading branch information
tsukumijima authored Sep 25, 2024
2 parents bb8b1b7 + deca3c5 commit 42eb8af
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ link_directories(${PCSC_LIBRARY_DIRS})

# ---------- libaribb1 ----------

if(WIN32 AND NOT CMAKE_SYSTEM_PROCESSOR MATCHES "(ARM|ARM64|AARCH64)")
if(CMAKE_C_COMPILER_ID MATCHES "MSVC")
add_library(aribb1-objlib OBJECT aribb25/arib_std_b25.c aribb25/b_cas_card.c aribb25/multi2.c aribb25/multi2_simd.c aribb25/ts_section_parser.c aribb25/version_b1.c)
else()
add_library(aribb1-objlib OBJECT aribb25/arib_std_b25.c aribb25/b_cas_card.c aribb25/multi2.cc aribb25/ts_section_parser.c aribb25/version_b1.c)
Expand Down Expand Up @@ -186,7 +186,7 @@ configure_file(aribb25/version_b1.rc.in version_b1.rc @ONLY)

# ---------- libaribb25 ----------

if(WIN32 AND NOT CMAKE_SYSTEM_PROCESSOR MATCHES "(ARM|ARM64|AARCH64)")
if(CMAKE_C_COMPILER_ID MATCHES "MSVC")
add_library(aribb25-objlib OBJECT aribb25/arib_std_b25.c aribb25/b_cas_card.c aribb25/multi2.c aribb25/multi2_simd.c aribb25/ts_section_parser.c aribb25/version_b25.c)
else()
add_library(aribb25-objlib OBJECT aribb25/arib_std_b25.c aribb25/b_cas_card.c aribb25/multi2.cc aribb25/ts_section_parser.c aribb25/version_b25.c)
Expand Down
2 changes: 1 addition & 1 deletion aribb25/multi2.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ typedef struct {
int (* clear_scramble_key)(void *m2);

int (* encrypt)(void *m2, int32_t type, uint8_t *buf, int32_t size);
#ifdef ENABLE_MULTI2_SIMD
#if defined(_MSC_VER)
int (* decrypt)(void *m2, int32_t type, uint8_t *buf, intptr_t size);
#else
int (* decrypt)(void *m2, int32_t type, uint8_t *buf, int32_t size);
Expand Down

0 comments on commit 42eb8af

Please sign in to comment.