954,492 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Developing C++ app on Linux

Hi, I need to develop a C++ application for Linux, and I am worried about its compatibility with between different distros, for example if I develop it on Kubuntu, is it possible that I may have compatibility issues if I run it on Gentoo or Open SUSE for example?

In other words, what should I keep in mind to make my application compatible with other Linux distros?

Thanks,
Komyg

komyg
Light Poster
29 posts since Aug 2009
Reputation Points: 10
Solved Threads: 1
 

Hi, I need to develop a C++ application for Linux, and I am worried about its compatibility with between different distros, for example if I develop it on Kubuntu, is it possible that I may have compatibility issues if I run it on Gentoo or Open SUSE for example?

In other words, what should I keep in mind to make my application compatible with other Linux distros?

Thanks, Komyg

Well As Far As I Know, that depends on what application you are making and what libraries you will be using. If you are going to make your application using just the Standard C++ stuff using the GCC compiler, then it should compile and run anywhere the GCC compiler has been ported to.
In case you are using some extra stuff like the Posix thread libraries or cURL or one of the many Boost libraries for C++, then you application will be restricted to run only to those platforms where those libraries have been ported to.

stephen84s
Nearly a Posting Virtuoso
1,443 posts since Jul 2007
Reputation Points: 668
Solved Threads: 154
 
Well As Far As I Know, that depends on what application you are making and what libraries you will be using. If you are going to make your application using just the Standard C++ stuff using the GCC compiler, then it should compile and run anywhere the GCC compiler has been ported to. In case you are using some extra stuff like the Posix thread libraries or cURL or one of the many Boost libraries for C++, then you application will be restricted to run only to those platforms where those libraries have been ported to.

Well, I think that I won't be writing anything that isn't supported by GCC or GPP, however I will also need to use some drivers to access a fingerprint scanner that is connected via USB. Do you think that the differences between the Kernel present in different distros could cause me problems while using those drivers?

Thanks,
Komyg

komyg
Light Poster
29 posts since Aug 2009
Reputation Points: 10
Solved Threads: 1
 

The same answer applies to that and is specific to the driver you are talking about.

If the driver only has one version, for Linux, then you probably wont run into any problems, if there exist different versions for different distros then you might run into problems, but in this case I guess you can only be sure by testing, maybe there aren't any differences that apply to you.

thelamb
Posting Pro in Training
426 posts since Aug 2008
Reputation Points: 193
Solved Threads: 75
 

Well, I think that I won't be writing anything that isn't supported by GCC or GPP, however I will also need to use some drivers to access a fingerprint scanner that is connected via USB. Do you think that the differences between the Kernel present in different distros could cause me problems while using those drivers?

Thanks, Komyg

I'm using a scanner inside linux , and that was /dev/usb/scanner0
so it's a file in the linux. what I just doing is use the scanimage utility
in the liunx. So you can read from the scanner using that scanimage
utility.Here is the man page http://linux.die.net/man/1/scanimage

just Create another child of scanimage. It will make you're things
easy.You can even do this using shell script.

so for the GUI development you can use the Xlib , if you heavily
needs the independent among the distros. Xlib is everywhere on
evey distro's.But the life with Xlib is going to be hard.

NicAx64
Posting Pro
536 posts since Mar 2009
Reputation Points: 86
Solved Threads: 43
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You