[Insight-users] Building release

Luis Ibanez luis.ibanez at kitware.com
Sun Aug 5 13:34:33 EDT 2007


Hi Dan,

Congratulations, it is always great to be ready to deploy   :-)

About your questions:

1) Yes, your assumption is correct, if you build ITK with Static
    libraries, it will make easier to move your executable elsewhere.

2) Yes, if you use ITK with shared libraries, then you will have
    to copy the shared libraries to the destination machine.

3) Yes, in general, unless you are wrapping ITK for Tcl, Python
    or Java, there is NO good reason for building ITK as Shared
    libraries.

    Most of ITK is templated code, that will get instantiated into
    your application. The eventual shared libraries will be very
    small, containing the few non-templated classes of ITK, and
    will only produce annoyances, pain and unnecessary suffering.

4) Yes, simply coping shared libraries is a fragile way of moving
    your code around. Stay away from shared libraries as much as
    you can.

5) Yes, the 32 bits executable "should" run fine in a 64 bits
    machine.

6) This one, I just don't know...


   Regards,


       Luis


----------------------
Dan Homerick wrote:
> Hi Insight-users,
>  
> My project is finally to the point where I want to build a release 
> version that can run on a computer other than the one it was developed 
> on. I'm developing on a 32-bit x86 Linux distribution (Ubuntu) and my 
> target is a 64-bit x86 Linux. I'm compiling with g++. I have a set of 
> basic questions/assumptions that I think know the answers to, but I'd 
> like to make sure. Let me know if any of the following seem wrong to you 
> -- let me know if everything looks pretty much accurate, too. =)
>  
> 1. If ITK is compiled using static libraries, I can build a single 
> executable for my project that does not require any ITK Libraries to be 
> present on the target machine.
>  
> 2. If ITK is compiled using shared libraries, then ITK must be built on 
> the target machine to provide the appropriate libraries.
>  
> 3. Compiling ITK with shared libraries is required if you are using Java 
> or Python wrappings.
>  
> 4. Simply copying shared libraries built on one machine to another 
> machine is probably a pretty bad idea.
>  
> 5. A 32-bit executable should run fine on a 64-bit OS, although won't 
> take advantage of the extra registers and larger memory address space 
> offered.
>  
> 6. Compiling on a Intel x86 processor for a AMD x86 processor doesn't 
> require any special flags, and the executable should "just work" on both 
> platforms (other issues aside).
>  
> Cheers,
>  - Dan
>  
>  
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Insight-users mailing list
> Insight-users at itk.org
> http://www.itk.org/mailman/listinfo/insight-users


More information about the Insight-users mailing list