ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
i'm new in java I would like to convert my c++ progarmes to java
but I faced some proplem because most of my programes linked to c/c++ libs as will as use the headers of these libs .
any one can help to make port for some c/c++ libs to java
thnx
BR,
SIS
I too am new to Java but I would think that most libraries are ported to Java. If not you could check if Java has some standard library solution for it already.
hey
i dont talking about standred lib for example if used rpm or parted lib in my original c++ pro
how can i link to them from java (using of headers and dynamic linking of libs )
thnx for replay
BR,
SIS
Thank you guys for replaying … I Don't traying such techinque but I think this may be heavy and may cause dealying .
I Meant how to convert C/C++ LIBS To Native JAVA Class
(I SAW SOME THING LIKE THAT IN PYTHON "you can see source code of parted for example you will find python dir check it ") and Dealing with them as java class .
THNX
BR,
SIS
Really, I've run into situations like this before, where I would to make use of a certain library in Java, but don't want to "native" it.
My solution, at the time, was to rewrite it, in Java. Also, if you do a Google search for "java" + the library you might be able to find someone's unofficial package for that library. The two biggest problems with this would be (1) you hope the author documents everything properly - but this won't be much of an issue if you use an IDE like Netbeans or Eclipse - and (2) the method structures would be completely different - even moreso if written in C. I can't think of how many times I've tried to rewrite C/C++ libraries in Java, and just given up due to the convilution of some of them.
It's not possible to rewrite some libs into "native" java (most of them deals with hardware).
Oh, I know - I should have been a little more specific with my comment - I was referring to things like graphics libraries, and some compression libraries.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.