Skip to content

Commit

Permalink
compile heifio subs with C linkage
Browse files Browse the repository at this point in the history
  • Loading branch information
farindk committed Sep 22, 2024
1 parent 11bf5c7 commit dd08810
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion heifio/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ target_compile_definitions(heifio
LIBHEIF_EXPORTS
HAVE_VISIBILITY)

find_package(TIFF)
find_package(TIFFq)
if (TIFF_FOUND)
target_sources(heifio PRIVATE decoder_tiff.cc decoder_tiff.h encoder_tiff.h encoder_tiff.cc)
target_link_libraries(heifio PRIVATE TIFF::TIFF)
Expand Down
3 changes: 3 additions & 0 deletions heifio/stubs.cc
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
#include "libheif/heif.h"
#include "decoder.h"

extern "C" {

#if !HAVE_LIBJPEG
heif_error loadJPEG(const char *filename, InputImage *input_image)
Expand Down Expand Up @@ -62,3 +63,5 @@ heif_error loadTIFF(const char *filename, InputImage *input_image)
return err;
}
#endif

}

0 comments on commit dd08810

Please sign in to comment.