Project

General

Profile

Actions

Bug #5210

closed

boost_program_options should not appear in libndn-cxx.pc

Added by Davide Pesavento almost 2 years ago. Updated 8 months ago.

Status:
Closed
Priority:
Normal
Category:
Build
Target version:
Start date:
Due date:
% Done:

100%

Estimated time:

Description

$ grep Libs: /usr/local/lib/pkgconfig/libndn-cxx.pc 
Libs: -L${libdir}  -L/usr/lib/x86_64-linux-gnu -L/usr/lib -lndn-cxx -lboost_system -lboost_program_options -lboost_chrono -lboost_date_time -lboost_filesystem -lboost_thread -lboost_log -lboost_stacktrace_backtrace -lcrypto -lsqlite3 -latomic -lrt -lpthread 

$ scanelf -nq /usr/local/lib/libndn-cxx.so.0.8.0 
libboost_chrono.so.1.74.0,libboost_filesystem.so.1.74.0,libboost_thread.so.1.74.0,libboost_log.so.1.74.0,libboost_stacktrace_backtrace.so.1.74.0,libcrypto.so.3,libsqlite3.so.0,libstdc++.so.6,libm.so.6,libgcc_s.so.1,libc.so.6,ld-linux-x86-64.so.2  /usr/local/lib/libndn-cxx.so.0.8.0

boost_program_options is not required to compile against the ndn-cxx library, it's used only by the ndnsec tool, so it should not be listed in the pkgconfig file.

Actions #1

Updated by Junxiao Shi 8 months ago

  • Status changed from New to Resolved
  • Assignee set to Junxiao Shi
Actions #2

Updated by Davide Pesavento 8 months ago

  • Status changed from Resolved to In Progress
  • Target version set to 0.9.0
Actions #3

Updated by Davide Pesavento 8 months ago

Junxiao Shi wrote in #note-1:

https://gerrit.named-data.net/c/ndn-cxx/+/7174

This is just papering over the real problem, which is that we're lumping all Boost libraries together in one big group and linking all targets against all libraries. Moreover, we're trying to detect boost_program_options (and fail hard if not present) even when tools are disabled.

Actions #4

Updated by Davide Pesavento 8 months ago

Needs more testing, but this is hopefully a more comprehensive solution: https://gerrit.named-data.net/c/ndn-cxx/+/7177

Actions #5

Updated by Junxiao Shi 8 months ago

  • Assignee changed from Junxiao Shi to Davide Pesavento

Davide Pesavento wrote in #note-3:

This is just papering over the real problem, which is that we're lumping all Boost libraries together in one big group and linking all targets against all libraries.

This "real problem" should have been stated when you created the bug.

Actions #6

Updated by Davide Pesavento 8 months ago

  • Status changed from In Progress to Code review
  • % Done changed from 0 to 50

Junxiao Shi wrote in #note-5:

This "real problem" should have been stated when you created the bug.

Well, I would've done that if I knew what the root cause was. I didn't do any investigation when I opened the bug.

Generally speaking, finding the root cause of a bug is part of the resolution process, not the reporting process.

Actions #7

Updated by Davide Pesavento 8 months ago

  • Status changed from Code review to Closed
  • % Done changed from 50 to 100
Actions

Also available in: Atom PDF