IDE for Win/Raspberry Pi/Linux/Arduino

Hello Everyone,

Just a general question - Is there an IDE which programs in C/C++ that works across these various platforms: Windows, Raspberry Pi, Linux, Arduino. Meaning to write the code once and compile for other operating systems?

After trying many languages and writing many books on the topics, I am tending to see the trend that each platform tends to have its own preferred language. Example, Raspberry Pi tends to favour Python, Arduino tends to use C, Windows/Linux uses C/C++ and many other possible languages.

Visual Studio 2019 is pretty good, and I haven't performed much work with cross-OS compiling yet, and have used the local programming languages for each system.

I am just reaching out to the community for your thoughts, as there is no need for me to reinvent the wheel. Is there an IDE that can perform a code-once and compile to many other operating systems?

Thanks a bunch!
Visual Studio 2017/2019, for one. Have to manually set up the install packages for mobile and C/C++ desktop development. That can be done during the initial installation or as a modification later.

C# and Windows Forms looks to be a better bet for cross-platform development, mobile/desktop, though I don't do that so have zero experience in the particulars.

Arduino AFAIK is a one-off platform that pretty much requires its own stripped-down compiler.
Thanks @Furry Guy,

I'll look into manually setting up the install packages and try a few 'Hello World' programs just to make sure I get the concept of Visual Studio 2019 with mobile programs.

I have heard that C# is good at cross-platform work, although I have had problems supporting the latest versions of OpenGL/Vulkan and DirectX with C#. There are good libraries for both OpenGL/Vulkan and DirectX with C++. I have only made a few simple graphics programs with C# as most people tend to use Unity with C# and the Unreal Engine with C++. I haven't seen support directly for OpenGL/Vulkan or DirectX in C#, at least not the latest versions.

I have been getting many requests for embedded systems where electronics are designed and talk to computer programs, and C/C++ is the programming language that tends to be heavily used. One request is to design sensor inputs, retrieve Transistor-Transistor-Logic data, and then show the data in Virtual Reality. As you mentioned, I may just need to use Arduino's stripped-down compiler, as the running code is very efficient.

Tanks for your helpful comments!
You might look at Universal Windows Platform (UWP) development, that is the latest shiny object that MS is pimping.

https://docs.microsoft.com/en-us/windows/uwp/get-started/universal-application-platform-guide

With a UWP app you can use DirectX to create games it seems.

https://docs.microsoft.com/en-us/windows/uwp/gaming/directx-programming

Even port OpenGL to Direct3D.
Yes, UWP looks good and I'll need to learn a little more about it. The sales-like information seems nice, just not sure how it programs in the real-world :) When programming cross-platform there are always a bunch of unique programming-gotchas.

Your answers are very helpful. Thanks again.

Edit: Remove grammatical errors
Last edited on
Topic archived. No new replies allowed.