Skip to main content
Known Participant
October 23, 2024
Question

Undefined Symbols Error in Xcode 15.2 When Building InDesign SDK 2025

  • October 23, 2024
  • 4 replies
  • 4874 views

Hi All, I am getting below error when trying to build my native c++ plugin in xcode 15.2. 

Can anyone please help.

Thanks

 

Undefined symbols for architecture x86_64:

  "boost::this_thread::interruption_point()", referenced from:

      boost::condition_variable::wait(boost::unique_lock<boost::mutex>&) in HttpUtils.o

  "boost::this_thread::disable_interruption::disable_interruption()", referenced from:

      boost::shared_mutex::lock() in HttpUtils.o

      boost::shared_mutex::lock_shared() in HttpUtils.o

  "boost::this_thread::disable_interruption::~disable_interruption()", referenced from:

      boost::shared_mutex::lock() in HttpUtils.o

      boost::shared_mutex::lock_shared() in HttpUtils.o

  "boost::detail::get_current_thread_data()", referenced from:

      boost::detail::interruption_checker::interruption_checker(_opaque_pthread_mutex_t*, _opaque_pthread_cond_t*) in HttpUtils.o

ld: symbol(s) not found for architecture x86_64

clang: error: linker command failed with exit code 1 (use -v to see invocation)

 

 

<Title renamed by MOD>

This topic has been closed for replies.

4 replies

Legend
October 24, 2024

In both a reference SDK sample project and your own project, create a shell script build phase that outputs all the environment variables to a file – alternatively there's also a "Show environment variables in build log".

Compare both files.

Some of the differences are random IDs that differ per Xcode run.

Ignore those cases; taking an automated approach I use a sed script to clean them up.

Also offload all build setting overrides within the project into xcconfig files.

Alam5EC6Author
Known Participant
October 24, 2024

I compared build settings with previous 19 SDK proj file and every settings are similiar in 20 SDK proj file but still getting the above errors.

Legend
October 24, 2024

Hmm, did you compare build settings in the IDE (multiple places to cover, easy to miss one) or a dump of the environment variables as I suggested?

 

Also have a look SDK docs/html/id_porting_guide.html mentions "Other project changes to note"

Watch out for CLANG_CXX_LANGUAGE_STANDARD and BOOST_SPIRIT_THREADSAFE e.g. if you use own xcconfig and bypass common.xcconfig .

Community Expert
October 24, 2024

I would suggest you first try to build a sample plugin and if that does not build then definitely you have an incorrect setup of dev env. The best way to resolve such an error is to cross check the recommended env in the SDK documentation.

-Manan

-Manan
Alam5EC6Author
Known Participant
October 24, 2024

@Manan Joshi  thanks for the reply.

The samples plugins are building fine without any errors.

Community Expert
October 24, 2024

Then we would need to check it from the Boost end maybe. Did you create the lib you are linking against?

-Manan

-Manan
Alam5EC6Author
Known Participant
October 23, 2024

@Olivier Beltrami  Thanks for reply. 

After went to c++14 now I am getting "Use of undeclared identifier 'LONG_LONG_MIN" see screenshot for reference.

Olivier Beltrami
Legend
October 23, 2024

What version of C++ were you using for your version 19 plugins ?

Try using the exact same settings as for previous versions.

Alam5EC6Author
Known Participant
October 24, 2024

In previous version 19, I was using GNU++14 [-std=gnu++14]. I tried with it as well in SDK version 20 but still it is giving me previos errors. Attached file for reference.

Olivier Beltrami
Legend
October 23, 2024

@Alam5EC6 When the pre-release version 20 SDK came out, there was a lot of mentioning that the version 20 plugins should be compliant with the C++17 standard. I made sure my code was ... but it turned out that the SDK was not ! Are you trying to build using the C++17 standard ? So I went back to C++14 and everything works fine.