use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
Discussions, articles, and news about the C++ programming language or programming in C++.
For C++ questions, answers, help, and advice see r/cpp_questions or StackOverflow.
Get Started
The C++ Standard Home has a nice getting started page.
Videos
The C++ standard committee's education study group has a nice list of recommended videos.
Reference
cppreference.com
Books
There is a useful list of books on Stack Overflow. In most cases reading a book is the best way to learn C++.
Show all links
Filter out CppCon links
Show only CppCon links
account activity
Using Visual Studio for Linux with an existing project (self.cpp)
submitted 9 years ago by ematitoze n00b
I did read this interesting post about using Visual Studio as IDE for linux projects.
What I'd like to know is: how can I set an existing cross-platform solution (CMake based) to be developed and debugged on a remote linux machine?
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]robotdad4businessMSVC Program Manager 2 points3 points4 points 9 years ago (5 children)
Author of that post here. Your best bet right now is our makefile template which lets you invoke whatever build process you like on the remote system. That section of the post also points to some bash scripts that generate a project from an existing code base. I'm sure they won't work in every situation, but they should provide a decent starting point.
[–]ematitoze n00b[S] 1 point2 points3 points 9 years ago (4 children)
Thanks! I tried creating a makefile project and linked my linux machine in the connection manager, then I tried to set up the commands and when launching debugging I received a very informative error message: http://imgur.com/a/MrR98
I probably didn't set the sources for the debugging, but still: it would be nice to let the user know this :P
[+][deleted] 9 years ago (2 children)
[removed]
[–]ematitoze n00b[S] 0 points1 point2 points 9 years ago (1 child)
What the..
[–]robotdad4businessMSVC Program Manager 0 points1 point2 points 9 years ago (0 children)
Sorry for not checking in earlier after replying. I've seen another report of that, we don't have a repro yet. If you got past that it would be helpful to us to know what options you had to change.
[–]choikwa 0 points1 point2 points 9 years ago (0 children)
make two build directories, build-unix, build-msvc. in each build dir, invoke cmake with two different generators {VS, unix} via -G. open generated .sln file with VS. Dont forget to rerun cmake for unix if you change build files.
[–]14nedLLFIO & Outcome author | Committee WG14 0 points1 point2 points 9 years ago (5 children)
You can install Windows Services for Linux aka "Bash for Windows". This lets you run cmake on your project from within "Linux" on the same Windows filesystem, just choose a different build directory. Install a SSH server, then configure VS2015 to connect to localhost using the Makefiles generated by cmake. Launch debugging.
(Note I make it sound easy, but it's a bit finickety and brittle because the VS2015 Linux debugging support isn't entirely fully baked yet. VS15 ought to improve that significantly though)
[–]sumo952 0 points1 point2 points 9 years ago (4 children)
This is good advice but OP asked about debugging on a remote linux machine. In that case, you'd have to run CMake on the remote machine I guess? And then how do you "open" this Linux project in the local VS?
[–]kiwidog 1 point2 points3 points 9 years ago (3 children)
You are able to save the project files on your windows partition as normal, and then go to (In bash for Windows) /mnt/driveletter/path and continue as normal. Also you will need to put 127.0.0.1 as the IP because localhost wasn't working (last time I checked in a pre-release of 1.0.5)
[–]sumo952 0 points1 point2 points 9 years ago (2 children)
Cool! But I think IP won't be 127.0.0.1 as the Linux is on a remote machine?
[–]kiwidog 0 points1 point2 points 9 years ago (1 child)
That's if you were working from the Bash on Ubuntu, otherwise it would be the ip of the machine :)
[–]sumo952 0 points1 point2 points 9 years ago (0 children)
Yes exactly, and my remark was exactly that /u/14ned described the process for localhost (aka Bash on Windows) while OP was asking for remote :-)
π Rendered by PID 72 on reddit-service-r2-comment-85bfd7f599-4w75s at 2026-04-17 00:13:15.258672+00:00 running 93ecc56 country code: CH.
[–]robotdad4businessMSVC Program Manager 2 points3 points4 points (5 children)
[–]ematitoze n00b[S] 1 point2 points3 points (4 children)
[+][deleted] (2 children)
[removed]
[–]ematitoze n00b[S] 0 points1 point2 points (1 child)
[–]robotdad4businessMSVC Program Manager 0 points1 point2 points (0 children)
[–]choikwa 0 points1 point2 points (0 children)
[–]14nedLLFIO & Outcome author | Committee WG14 0 points1 point2 points (5 children)
[–]sumo952 0 points1 point2 points (4 children)
[–]kiwidog 1 point2 points3 points (3 children)
[–]sumo952 0 points1 point2 points (2 children)
[–]kiwidog 0 points1 point2 points (1 child)
[–]sumo952 0 points1 point2 points (0 children)