Hard time with CMake imported file

Sysprogs forums Forums VisualGDB Hard time with CMake imported file

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #12561
    roy111
    Participant

    Hi,

    I’m having some real hard time with VisualGDB.

    I have the following project structure:
    Local machine: Windows 10 + Visual studio 2017 Community.
    Remote machine: Ubuntu 16.04
    I have an existing CMake based Linux project with sub folders also containing CMake. It all works fine when using Eclipse running on Ubuntu.

    I used VisualGDB (version 5.3) to import the CMake based project to visual studio (running on a local windows machine…) with the following settings:

    a. Source resides on windows, and is automatically coppied (or at least should) to the remote machine.
    b. Build occurs on remote Linux machine.

    I did manage to build and step with the debugger within the project, from VisualStudio, however I encountered some major problems:

    1. I cannot view the CMakeLists.txt files in the project subfolders, only the root folder.

    2. I did not manage to change the debugger from “Local Windows Debugger” to “VisualGDB”  (as seen in screenshots from the visualgdb tutorial found
    at link https://visualgdb.com/tutorials/linux/cmake/ )

    3. This is the worse one: I added a new source files (foo.cpp , foo.h) and updated the relevant CMakeLists.txt file, on the local machine source.
    I cannot make the VisualStudio project explorer to realize that new files were added. It is as if there is some cache of the original imported CMakeLists.txt
    that does not get updated.
    I do not think it would make sense to create the solution from scratch each time a new file is added…
    Any ideas how to add a file to the project?

    Thanks !

    • This topic was modified 6 years, 7 months ago by roy111.
    #12568
    support
    Keymaster

    Hi,

    Just to double-check, are you checking the “use the advanced CMake Project Subsystem” checkbox? If you are not sure, please try attaching a screenshot of the Solution Explorer in your project and we can check if this looks like the advanced CMake subsystem is active.

    #12571
    roy111
    Participant

    Problem solved.

    The “advanced CMake subsystem active” was on.

    I think the solution was to upgrade the CMake on the linux (the ubuntu package installer does not keep up with the CMake versions) and to install it as a server.

    Why do I think and not sure ? Because It worked after some time of going back and forth installing, purging, etc… on the Linux machine. It seems that working under Linux has

    some inherent randomness in results …

    Anyway, very glad problem resolved, most likely will buy the VisualDGB after trial month expires.

    All that is left is to be able to view the content of std::shared_ptr using the debugger.

    Thanks !

    #12578
    support
    Keymaster

    Hi,

    Older version of CMake could have contributed to this indeed. Either way, if you run into this again, feel free to let us know more details and we will help you troubleshoot this.

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.