Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NLopt CMakeLists.txt #2 #762

Merged
merged 3 commits into from
Feb 16, 2015
Merged

Conversation

cbames
Copy link

@cbames cbames commented Feb 10, 2015

include files weren't properly included and the pattern matching for nlopt libraries needed to be fixed

@k-okada
Copy link
Member

k-okada commented Feb 11, 2015

@s-noda please check this

@s-noda
Copy link
Contributor

s-noda commented Feb 12, 2015

Error occurred.

leus@cygnus:~/ros/hydro$ catkin build nlopt
-----------------------------------------------------------------------------
Profile:                     default
Extending:          [cached] /home/leus/ros/hydro_parent/devel:/opt/ros/hydro
Workspace:                   /home/leus/ros/hydro
Source Space:       [exists] /home/leus/ros/hydro/src
Build Space:        [exists] /home/leus/ros/hydro/build
Devel Space:        [exists] /home/leus/ros/hydro/devel
Install Space:     [missing] /home/leus/ros/hydro/install
DESTDIR:                     None
-----------------------------------------------------------------------------
Isolate Develspaces:         False
Install Packages:            False
Isolate Installs:            False
-----------------------------------------------------------------------------
Additional CMake Args:       None
Additional Make Args:        None
Additional catkin Make Args: None
-----------------------------------------------------------------------------
Workspace configuration appears valid.
----------------------------------------------------------------------------- 
Found '251' packages in 0.3 seconds. 
Starting ==> nlopt                                                                                   

[nlopt] ==> '/home/leus/ros/hydro/build/nlopt/build_env.sh /usr/bin/cmake /home/leus/ros/hydro/src/jsk-ros-pkg/jsk_common/3rdparty/nlopt -DCATKIN_DEVEL_PREFIX=/home/leus/ros/hydro/devel -DCMAKE_INSTALL_PREFIX=/home/leus/ros/hydro/install' in '/home/leus/ros/hydro/build/nlopt'
-- Using CATKIN_DEVEL_PREFIX: /home/leus/ros/hydro/devel
-- Using CMAKE_PREFIX_PATH: /home/leus/ros/hydro/devel;/home/leus/ros/hydro_parent/devel;/opt/ros/hydro
-- This workspace overlays: /home/leus/ros/hydro/devel;/home/leus/ros/hydro_parent/devel;/opt/ros/hydro
-- Using PYTHON_EXECUTABLE: /usr/bin/python
-- Python version: 2.7
-- Using Debian Python package layout
-- Using CATKIN_ENABLE_TESTING: ON
-- Call enable_testing()
-- Using CATKIN_TEST_RESULTS_DIR: /home/leus/ros/hydro/build/nlopt/test_results
-- Found gtest sources under '/usr/src/gtest': gtests will be built
-- catkin 0.5.90
CMake Error at /opt/ros/hydro/share/catkin/cmake/catkin_package.cmake:291 (message):
  catkin_package() absolute include dir '/home/leus/ros/hydro/devel/include'
  does not exist
Call Stack (most recent call first):
  /opt/ros/hydro/share/catkin/cmake/catkin_package.cmake:98 (_catkin_package)
  CMakeLists.txt:14 (catkin_package)

-- Configuring incomplete, errors occurred!
[nlopt] <== '/home/leus/ros/hydro/build/nlopt/build_env.sh /usr/bin/cmake /home/leus/ros/hydro/src/jsk-ros-pkg/jsk_common/3rdparty/nlopt -DCATKIN_DEVEL_PREFIX=/home/leus/ros/hydro/devel -DCMAKE_INSTALL_PREFIX=/home/leus/ros/hydro/install' failed with return code '1'

[build] There were errors:                                                                           

    Failed to build package 'nlopt' because the following command:

        # Command run in directory: /home/leus/ros/hydro/build/nlopt
        /home/leus/ros/hydro/build/nlopt/build_env.sh /usr/bin/cmake /home/leus/ros/hydro/src/jsk-ros-pkg/jsk_common/3rdparty/nlopt -DCATKIN_DEVEL_PREFIX=/home/leus/ros/hydro/devel -DCMAKE_INSTALL_PREFIX=/home/leus/ros/hydro/install

    Exited with return code: 1 
[build] Runtime: 1.3 seconds 
leus@cygnus:~/ros/hydro$ 

/home/leus/ros/hydro/devel/include was missing because of the following change:

17 +    INCLUDE_DIRS  ${CATKIN_DEVEL_PREFIX}/include

Besides, lib directory has no .hpp files. You mean *.so?

37 +  FILES_MATCHING PATTERN "*.h" PATTERN "*.hpp" PATTERN ".svn" EXCLUDE)

@garaemon
Copy link
Member

But It's strange because the test is passed.

@s-noda
Copy link
Contributor

s-noda commented Feb 12, 2015

Because travis builds jsk_common's packages separately?

The other package excepting nlopt package creates devel/include directory?

@garaemon
Copy link
Member

The other package excepting nlopt package creates devel/include directory?

It may be.

@cbames
Copy link
Author

cbames commented Feb 13, 2015

Good catch, I did have the lib and include install directives flipped. Just pushed a commit to fix that.

@s-noda
Copy link
Contributor

s-noda commented Feb 15, 2015

Great.

However, I think that the destinations of installing are also opposite.
it seams to me that the header files install into ${CATKIN_PACKAGE_LIB_DESTINATION} and the library files install into ${CATKIN_PACKAGE_INCLUDE_DESTINATION}.

Besides, I think it is not desirable that catkin_make fails if ${CATKIN_DEVEL_PREFIX}/include directory does not exist. But, sorry. I have no idea to fix this problem.

@cbames
Copy link
Author

cbames commented Feb 15, 2015

Ok, fixed install destinations, hopefully this fixes the catkin_make fail on ${CATKIN_DEVEL_PREFIX}/include not existing. If it doesn't we might want to bring it up as a bug with Catkin.

@s-noda
Copy link
Contributor

s-noda commented Feb 16, 2015

OK, lib and include files are correctly installed.

( ${CATKIN_DEVEL_PREFIX}/include problem is alive even now...)

It's ok to merge? > @k-okada
Although I have no permission to do so.

k-okada added a commit that referenced this pull request Feb 16, 2015
@k-okada k-okada merged commit 6a13a9d into jsk-ros-pkg:master Feb 16, 2015
@garaemon
Copy link
Member

https://travis-ci.org/jsk-ros-pkg/jsk_common/jobs/51037581

[nlopt] -- catkin 0.5.90 
[bayesian_belief_networks] -- catkin 0.5.90 
[nlopt] CMake Error at /opt/ros/hydro/share/catkin/cmake/catkin_package.cmake:291 (message): 
[nlopt]   catkin_package() absolute include dir 
[nlopt]   '/home/travis/ros/ws_jsk_common/devel/include' does not exist 
[nlopt] Call Stack (most recent call first): 
[nlopt]   /opt/ros/hydro/share/catkin/cmake/catkin_package.cmake:98 (_catkin_package) 
[nlopt]   CMakeLists.txt:14 (catkin_package) 
[nlopt]  
[nlopt]  
[nlopt] <== '/home/travis/ros/ws_jsk_common/build/nlopt/build_env.sh /usr/bin/cmake /home/travis/ros/ws_jsk_common/src/jsk_common/3rdparty/nlopt -DCATKIN_DEVEL_PREFIX=/home/travis/ros/ws_jsk_common/devel -DCMAKE_INSTALL_PREFIX=/home/travis/ros/ws_jsk_common/install' failed with return code '1' 

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants