How can I leave this thread?!

From: Dinkelacker, Stefan <s.dinkelac...@dkfz-heidelberg.de>
Sent: 04 February 2020 09:50
To: Ivaylo Angelov <ivaylo_ange...@gmx.de>; mitk-userslists.sourceforge.net 
<mitk-users@lists.sourceforge.net>
Subject: Re: [mitk-users] lib file of module not built


Hi,



PACKAGE_DEPENDS is only for external projects, not for modues. Use DEPENDS for 
modules. You can and should also combine your two PACKAGE_DEPENDS lines in the 
example below. PRIVATE is the default, so if you want to propagate dependencies 
you need to make them PUBLIC. See the mitk_create_module() documentation:

https://github.com/MITK/MITK/blob/v2018.04.2/CMake/mitkFunctionCreateModule.cmake.<https://github.com/MITK/MITK/blob/v2018.04.2/CMake/mitkFunctionCreateModule.cmake>
 There you can also see that you can specify PUBLIC, PRIVATE, INTERFACE 
dependencies in a single PACKAGE_DEPENDS list.



Note that there won't be any binary of your module if it does not contain 
actual source to build, for example, header-only modules won't have a binary.



Best,

Stefan



________________________________
Von: Ivaylo Angelov <ivaylo_ange...@gmx.de<mailto:ivaylo_ange...@gmx.de>>
Gesendet: Dienstag, 4. Februar 2020 10:02
An: mitk-userslists.sourceforge.net
Betreff: [mitk-users] lib file of module not built

Dear all,

I am working on a module that I would also like to use in another module (for 
example in the way the Segmentation module is used within the SegmentationUI 
module). For that, I made use of the Project template's example module by 
building a module right next to it in a similar manner,
though without a command line app, just a bunch of cpp and header files.
Compilation and everything works well, but when I try for another Module to 
depend on that one (PACKAGE_DEPENDS in CMakeLists) it says there is no
.lib file of my module and indeed I looked up in the directory and saw that it 
is never built (the one of your ExampleModule in the ProjectTemplate is built 
though).
I would really appreciate if someone could tell me what to look for in that 
case and what I could have missed.
I am including the CMakeLists file of my module at the end of this mail, in 
case it is necessary.
Thank you in advance!

Kind regards,
Ivaylo Angelov

CMakeLists.txt of my module:

mitk_create_module(MyModule
  INCLUDE_DIRS include
  DEPENDS PUBLIC MitkCore
  PACKAGE_DEPENDS VTK|vtkIOPLY+vtkIOMINC
  PACKAGE_DEPENDS PRIVATE GuidelinesSupportLibrary
)
_______________________________________________
mitk-users mailing list
mitk-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mitk-users

Reply via email to