LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Compiling and moving a program (https://www.linuxquestions.org/questions/linux-software-2/compiling-and-moving-a-program-673391/)

cornsnap 09-30-2008 04:31 PM

Compiling and moving a program
 
I recently compiled the program "curl" on a RH Ent 4 server. Is there a way of moving that program to another Linux server without compiling?

Thanks.

i92guboj 09-30-2008 05:34 PM

Provided that they other boxes have all the needed libraries, then just copying the program to the relevant directory should work ok. The problem with curl is that it links against a number of different libraries, optionally. So, you might need to have kerberos, ssl, com_err and a number of other libraries (if you compiled your binary with support for that libs).

Another problems might be the architecture and the versions. If they do not match then you can't take your binary to the other machines easily. The easy way would be to install curl using the red hat repositories. I find it hard to believe that rhel doesn't count with a package for curl on it's official repository...

cornsnap 09-30-2008 07:03 PM

Thanks
 
RHE does come with the rpm but we are getting an error when running it. Our developer suggested getting a new version of the program. We are currently at 7.12 which is RH latest version. I compiled it on our test box but wanted to move it in prod without recompiling fearing it may cause problems.

jailbait 09-30-2008 07:08 PM

If both machines are running the same version of Red Hat then you should be able to copy the program over and have it work OK.

-------------------
Steve Stites

i92guboj 10-01-2008 07:08 AM

Quote:

Originally Posted by jailbait (Post 3296461)
If both machines are running the same version of Red Hat then you should be able to copy the program over and have it work OK.

-------------------
Steve Stites

Yes. If all the installations are the same hrel version you will not have problems (again, provided that the architecture of all of them is the same, i.e. all x86 machines).

You could also make an rpm package from your compiled version to make it the clean way. I never was an rpm guy so I can't help you with that.

Valery Reznic 10-02-2008 02:00 AM

Quote:

Originally Posted by cornsnap (Post 3296373)
I recently compiled the program "curl" on a RH Ent 4 server. Is there a way of moving that program to another Linux server without compiling?

Thanks.

If "another Linux server" has same libraries needed by curl as your build box, then you can move it. If not, or if in doubt you can download curl from here:

http://www.magicermine.com/demos/curl/curl/curl.html

This is self-contained executable packed with Ermine (http://magicErmine.com)
It's supposed to run on nearly any x86 or x86_64 Linux box.


All times are GMT -5. The time now is 09:20 PM.