View Issue Details

IDProjectCategoryView StatusLast Update
0002492Slicer4Core: Building (CMake, Superbuild)public2012-10-06 04:17
Reporterlassoan Assigned Tojcfr  
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
Product Version 
Target VersionSlicer 4.2.0Fixed in VersionSlicer 4.2.0 
Summary0002492: Continuous build configuration error on factory.kitwarein.com for Perknav
Description

http://slicer.cdash.org/viewConfigure.php?buildid=38858

CMake Error at /Users/kitware/Dashboards/Continuous/Slicer4/CMake/SlicerExtensionCPack.cmake:142 (add_subdirectory):
The binary directory

/Users/kitware/Dashboards/Continuous/SlicerExtensions-build-64bits-QT4.7.4-PythonQt-With-Tcl-CLI-Release-continuous-master/PerkNav-build/SlicerExtensionBundle-binary

is already used to build a source directory. It cannot be used to build
source directory

/Users/kitware/Dashboards/Continuous/SlicerExtensions-build-64bits-QT4.7.4-PythonQt-With-Tcl-CLI-Release-continuous-master/PerkNav-build/SlicerExtensionBundle

Specify a unique binary directory name.

TagsNo tags attached.

Activities

jcfr

jcfr

2012-09-10 13:56

administrator   ~0006022

Should this issue be assigned to the maintainer of PerkNav instead ?

ungi

ungi

2012-09-10 14:32

developer   ~0006024

This is a CMake configuration setting problem. I don't think the problem is on my side (PerkNav developer). PerkNav builds successfully on other platforms and on my PC.

The nightly builder wants to configure the build into a binary folder that has been already used before for another build.

Or if you have any suggestions what could I check on my side, please let me know.
Thanks,
Tamas

ungi

ungi

2012-09-29 04:51

developer   ~0006274

This error seems to go away if I remove these lines from the end of my module CMakeLists.txt files:

#-----------------------------------------------------------------------------
if(NOT Slicer_SOURCE_DIR)
include(${Slicer_EXTENSION_CPACK})
endif()

I don't know what these lines do. Is it OK just to remove them?

jcfr

jcfr

2012-10-02 06:48

administrator   ~0006318

These lines are required so that the packaging of the extension works:
if(NOT Slicer_SOURCE_DIR)
include(${Slicer_EXTENSION_CPACK})
endif()

Could you provide me with the dashboard script you are using to build your extension ?

ungi

ungi

2012-10-02 07:14

developer   ~0006322

Yes, but I don't know where to look for it. Could you please tell me what is the name of the file you need?

jcfr

jcfr

2012-10-02 07:17

administrator   ~0006323

From the title of the issue, I assumed you created a dashboard scripts based on [1] and that then you were having issue setting up a continuous build.

Would it be possible to described the steps leading to the reported error so that I have a better understanding of the context ?

Thanks

[1] https://github.com/Slicer/Slicer/blob/master/Extensions/CMake/SlicerExtensionsDashboardScript.TEMPLATE.cmake

ungi

ungi

2012-10-02 07:48

developer   ~0006328

It started with a configuration error on Mac only in the nightly extension builds (probably continuous too, but I didn't set that up on my computer). The error messages included "...binary is already used to build a source directory".

Then the same error started to appear on Win nightly extension builds. (I've never set up continuous build.) And finally the same error appeared on my computer (Win) too, so I couldn't build my own extension.

Finally, I figured out that if I remove these lines
... include(${Slicer_EXTENSION_CPACK}) ...
from the CMakeLists.txt files inside each module folder (they are subfolders of my extension) then the PerkNav extension successfully builds on my computer.

So I committed the CMakeLists.txt files in my repository (without these lines
... include(${Slicer_EXTENSION_CPACK}) ...
regenerated the PerkNav.s4ext file and requested a pull to Slicer/ExtensionsIndex/

Since then the PerkNav extension apparently builds on every platform, so my problem is solved (see Dashboard). I'm just a little worried, because I don't know if I was supposed to remove those lines from the CMakeLists.txt files.

This is the full story from my perspective.

jcfr

jcfr

2012-10-02 08:14

administrator   ~0006330

I had a look at the code and observed the following:

"include(${Slicer_EXTENSION_CPACK})" where (1) commented in the CMakeLists.txt proper to each modules belonging to the extension. Additionally, "include(${Slicer_EXTENSION_CPACK})" was already (2) added in the top-level CMakeLists.txt

Only (2) is required and expected to have the extension properly package. The one that was in the CMakeLists of each module was invalid and the source of error.

You will find enclosed a patch where I removed unused CMake code and fix some stylistic issue.

Let me know if you have any other questions.

2012-10-02 08:14

 

lassoan

lassoan

2012-10-06 04:17

developer   ~0006406

Thank you, it's all good now (http://slicer.cdash.org/index.php?project=Slicer4&date=2012-10-05)

Issue History

Date Modified Username Field Change
2012-09-10 06:57 lassoan New Issue
2012-09-10 06:57 lassoan Status new => assigned
2012-09-10 06:57 lassoan Assigned To => jcfr
2012-09-10 13:56 jcfr Note Added: 0006022
2012-09-10 14:32 ungi Note Added: 0006024
2012-09-29 04:51 ungi Note Added: 0006274
2012-10-01 11:18 jcfr Target Version => Slicer 4.2.0 - coming release
2012-10-02 06:48 jcfr Note Added: 0006318
2012-10-02 06:48 jcfr Status assigned => feedback
2012-10-02 07:14 ungi Note Added: 0006322
2012-10-02 07:17 jcfr Note Added: 0006323
2012-10-02 07:48 ungi Note Added: 0006328
2012-10-02 08:14 jcfr Note Added: 0006330
2012-10-02 08:14 jcfr Status feedback => resolved
2012-10-02 08:14 jcfr Fixed in Version => Slicer 4.2.0 - coming release
2012-10-02 08:14 jcfr Resolution open => fixed
2012-10-02 08:14 jcfr File Added: perknav-fix-style-and-remove-extra-cmake-code.diff
2012-10-06 04:17 lassoan Note Added: 0006406
2012-10-06 04:17 lassoan Status resolved => closed