[ros-users] cannot build a package

Daniel Maturana dimatura at gmail.com
Tue Dec 28 09:09:49 UTC 2010


Hi, at first glance, the text seems fine. Maybe it's some issue with
the file encoding, or some invisible character? Make sure it's in
ASCII encoding.
Daniel

On Tue, Dec 28, 2010 at 1:54 AM, Avinash Thiruvayipati <athiruva at asu.edu> wrote:
> Hi,
> I just edited the contents of the cmake file according to the procedure
> given in the tutorials.Stll I am getting the error as mentioned above.Could
> you please help me in this.I was stuck at this point for a long time.
>
> On Mon, Dec 27, 2010 at 3:48 PM, Avinash Thiruvayipati <athiruva at asu.edu>
> wrote:
>>
>> Hi Tully,
>>
>> Thanks for the reply.The cmake file i used is the following.Could you
>> please let me know my error.
>>
>> cmake_minimum_required(VERSION 2.4.6)
>> #include($ENV{ROS_ROOT}/core/rosbuild/rosbuild.cmake)
>>
>> # Set the build type.  Options are:
>> #  Coverage       : w/ debug symbols, w/o optimization, w/ code-coverage
>> #  Debug          : w/ debug symbols, w/o optimization
>> #  Release        : w/o debug symbols, w/ optimization
>> #  RelWithDebInfo : w/ debug symbols, w/ optimization
>> #  MinSizeRel     : w/o debug symbols, w/ optimization, stripped binaries
>> #set(ROS_BUILD_TYPE RelWithDebInfo)
>>
>> rosbuild_init()
>>
>> #set the default path for built executables to the "bin" directory
>> set(EXECUTABLE_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/bin)
>> #set the default path for built libraries to the "lib" directory
>> set(LIBRARY_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/lib)
>>
>> #uncomment if you have defined messages
>> rosbuild_genmsg()
>> #uncomment if you have defined services
>> #rosbuild_gensrv()
>> rosbuild_add_executable(talker src/talker.cpp)
>> rosbuild_add_executable(listener src/listener.cpp)
>> rosbuild_add_executable(add_two_ints_server src/add_two_ints_server.cpp)
>> rosbuild_add_executable(add_two_ints_client src/add_two_ints_client.cpp)
>> #common commands for building c++ executables and libraries
>> #rosbuild_add_library(${PROJECT_NAME} src/example.cpp)
>> #target_link_libraries(${PROJECT_NAME} another_library)
>> #rosbuild_add_boost_directories()
>> #rosbuild_link_boost(${PROJECT_NAME} thread)
>> #rosbuild_add_executable(example examples/example.cpp)
>> #target_link_libraries(example ${PROJECT_NAME})
>>
>> Hi,
>> This is the Cmake file I edited.
>>
>> cmake_minimum_required(VERSION 2.4.6)
>> #include($ENV{ROS_ROOT}/core/rosbuild/rosbuild.cmake)
>>
>> # Set the build type.  Options are:
>> #  Coverage       : w/ debug symbols, w/o optimization, w/ code-coverage
>> #  Debug          : w/ debug symbols, w/o optimization
>> #  Release        : w/o debug symbols, w/ optimization
>> #  RelWithDebInfo : w/ debug symbols, w/ optimization
>> #  MinSizeRel     : w/o debug symbols, w/ optimization, stripped binaries
>> #set(ROS_BUILD_TYPE RelWithDebInfo)
>>
>> rosbuild_init()
>>
>> #set the default path for built executables to the "bin" directory
>> set(EXECUTABLE_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/bin)
>> #set the default path for built libraries to the "lib" directory
>> set(LIBRARY_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/lib)
>>
>> #uncomment if you have defined messages
>> rosbuild_genmsg()
>> #uncomment if you have defined services
>> #rosbuild_gensrv()
>> rosbuild_add_executable(talker src/talker.cpp)
>> rosbuild_add_executable(listener src/listener.cpp)
>> rosbuild_add_executable(add_two_ints_server src/add_two_ints_server.cpp)
>> rosbuild_add_executable(add_two_ints_client src/add_two_ints_client.cpp)
>> #common commands for building c++ executables and libraries
>> #rosbuild_add_library(${PROJECT_NAME} src/example.cpp)
>> #target_link_libraries(${PROJECT_NAME} another_library)
>> #rosbuild_add_boost_directories()
>> #rosbuild_link_boost(${PROJECT_NAME} thread)
>> #rosbuild_add_executable(example examples/example.cpp)
>> #target_link_libraries(example ${PROJECT_NAME})
>>
>> On Mon, Dec 27, 2010 at 3:37 PM, Tully Foote <tfoote at willowgarage.com>
>> wrote:
>>>
>>> Hi Avinash,
>>> It looks like you have a syntax error in your CMakeLists.txt  If you
>>> could post it to the list we might be able to help you.
>>>
>>> Tully
>>>
>>> On 12/27/2010 02:34 PM, Avinash Thiruvayipati wrote:
>>>
>>> HI,
>>> I am a newbie to ros.While going through the tutorials of subscribing and
>>> publishing a message we add set up executables to the cmake file.when trying
>>> to rebuild the package using make it is giving the following error.Could you
>>> please give a solution to this problem
>>>
>>> mkdir -p bin
>>> cd build && cmake -Wdev -DCMAKE_TOOLCHAIN_FILE=`rospack find
>>> rosbuild`/rostoolchain.cmake  ..
>>> CMake Error: Error in cmake code at
>>> /home/avinash/ros/beginner_tutorials/CMakeLists.txt:1:
>>> Parse error.  Expected a command name, got unquoted argument with text
>>> "cmake_minimum_required".
>>> -- Configuring incomplete, errors occurred!
>>> make: *** [all] Error 1
>>>
>>>
>>> --
>>> Regards
>>> Avinash Thiruvayipati
>>> Graduate Student
>>> Electrical Engineering
>>> Arizona State University
>>> 734-985-1155
>>>
>>> _______________________________________________
>>> ros-users mailing list
>>> ros-users at code.ros.org
>>> https://code.ros.org/mailman/listinfo/ros-users
>>>
>>> _______________________________________________
>>> ros-users mailing list
>>> ros-users at code.ros.org
>>> https://code.ros.org/mailman/listinfo/ros-users
>>>
>>
>>
>>
>> --
>> Regards
>> Avinash Thiruvayipati
>> Graduate Student
>> Electrical Engineering
>> Arizona State University
>> 734-985-1155
>
>
>
> --
> Regards
> Avinash Thiruvayipati
> Graduate Student
> Electrical Engineering
> Arizona State University
> 734-985-1155
>
> _______________________________________________
> ros-users mailing list
> ros-users at code.ros.org
> https://code.ros.org/mailman/listinfo/ros-users
>
>



More information about the ros-users mailing list