1

I'm trying to install Simple Encrypted Arithmetic Library (SEAL) v2.3.1 on my Mac (running MacOS High Sierra version 10.13.6).

I was following the instructions in INSTALL.txt and when trying to build SEALExamples, I encountered an error when running cmake. The terminal output is as follows:

Rachels-MacBook-Pro:SEALExamples rachelplayer$ cmake .
-- SEAL detected (version 2.3.1)
-- SEAL build type: Release
-- SEAL debug mode: OFF
-- SEAL using Microsoft GSL: OFF
-- Configuring done
CMake Error at CMakeLists.txt:8 (add_executable):
Target "sealexamples" links to target "Threads::Threads" but the 
target was not found. Perhaps a find_package() call is missing 
for an IMPORTED target, or an ALIAS target is missing?

Please could you let me know how to fix it? I’m not sure if it’s a general bug or just my computer. Thanks!

πάντα ῥεῖ
  • 1
  • 13
  • 116
  • 190

1 Answers1

0

This is a mistake in SEAL/cmake/SEALConfig.cmake.in. For a quick fix, add the following to the beginning of the file:

include(CMakeFindDependencyMacro)
set(CMAKE_THREAD_PREFER_PTHREAD TRUE)
set(THREADS_PREFER_PTHREAD_FLAG TRUE)
find_dependency(Threads REQUIRED)

Then reconfigure, build, and reinstall SEAL and rebuild SEALExamples.

Kim Laine
  • 856
  • 5
  • 10