3

I want to compile and install a software on a new VM. The software was installed successfully on a different VM by a different admin, but I want to duplicate the exact command with the options that he used. Is this possible? BTW, the folder from where he ran ./configure is still intact.

5

If the whole directory where ./configure was previously run is wholly intact, then within that directory will be a file called config.status. The config.status file is generated when ./configure +args is run, and it records the arguments that are run. If you want to do everything exactly the same, and the new system has all the dependencies in place, you have several options.

  • you can tar/gzip the whole directory, copy the tarball to the new system, unpack it, and run make install to simply re-install the previously made objects. This should work if the system is similar enough (architecture/OS).
  • you can tar/gzip the whole directory, copy the tarball to the new system, unpack it, and run the ./config.status script redo all the previous ./configure work, allowing you to run a clean make, make test, and make install.
  • you can also do a completely clean build using the previous admin's exact arguments, by running cp config.status myconfigure, make clean, make distclean, and then running ./myconfigure to redo all the work.

The last option would work even if you were going between different linux distros, or from linux to solaris or freebsd, or 32-bit to 64-bit, provided that all the software's dependencies were met beforehand.

By copying config.status to a new filename like myconfigure, you preserve that file through any make clean, or make distclean commands.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.