[Fink-users] rebuilding a modified package
I am attempting to modify the C++ code for an application (coot) which effectively requires the use of Fink to build on OS X. At the suggestion of the package maintainer, I tried starting with this command: sudo fink -k -K rebuild coot which leaves the source directory in place. However, any attempt to run make in that directory after modifying the code fails, despite having the Fink environment variables set. I tried searching for additional information, and found some additional suggested environment variables, but those don't help either. Re-running the fink command above simply wipes out the directory and replaces it with a clean copy; I couldn't find any solution for that other than modifying the Perl code for Fink. So, I think I need to start over: what is the recommended mechanism for rebuilding from source? Is there a standard way to set up the environment to be identical to what Fink uses internally when building packages? (PS. OS 10.7, latest Xcode and command-line tools.) thanks, Nat -- Get your SQL database under version control now! Version control is standard for application code, but databases havent caught up. So what steps can you take to put your SQL databases under version control? Why should you start doing it? Read more to find out. http://pubads.g.doubleclick.net/gampad/clk?id=49501711iu=/4140/ostg.clktrk___ Fink-users mailing list Fink-users@lists.sourceforge.net List archive: http://news.gmane.org/gmane.os.macosx.fink.user Subscription management: https://lists.sourceforge.net/lists/listinfo/fink-users
Re: [Fink-users] rebuilding a modified package
On 8/2/2013 1:53 PM, Nat Echols wrote: I am attempting to modify the C++ code for an application (coot) which effectively requires the use of Fink to build on OS X. At the suggestion of the package maintainer, I tried starting with this command: sudo fink -k -K rebuild coot which leaves the source directory in place. However, any attempt to run make in that directory after modifying the code fails, despite having the Fink environment variables set. I tried searching for additional information, and found some additional suggested environment variables, but those don't help either. Re-running the fink command above simply wipes out the directory and replaces it with a clean copy; I couldn't find any solution for that other than modifying the Perl code for Fink. So, I think I need to start over: what is the recommended mechanism for rebuilding from source? Is there a standard way to set up the environment to be identical to what Fink uses internally when building packages? (PS. OS 10.7, latest Xcode and command-line tools.) http://finkers.wordpress.com/2009/07/24/creating-local-packages/ has instructions on how to generate a local copy of the instructions Fink uses to build a package. You can then modify the copied coot.info and coot.patch files with whatever changes you might want. If you're still testing out changes and want to do a quick test on Fink expanded source tree left over after using the -k flag, cd into the build directory (/sw/src/fink.build/coot-0.7.1.0-3/coot-0.7.1, then chown -R YOURID:admin . so that you have write permissions, patch the code, set the flags as needed (don't forget to *prepend* /sw/var/lib/fink/path-prefix-clang to $PATH), and try make again. If something is still failing, please post the error (or the unexpected result) you're getting from that command rather than just saying 'it fails'. It's not identical (especially for non-C based programs) to the internal Fink environment, but when I need to test local changes, I set the following variables during my tests: export FINK_PREFIX=/sw export PATH=${FINK_PREFIX}/var/lib/fink/path-prefix-clang:$PATH export CPPFLAGS=-I${FINK_PREFIX}/include export LDFLAGS=-L${FINK_PREFIX}/lib Hanspeter -- Get your SQL database under version control now! Version control is standard for application code, but databases havent caught up. So what steps can you take to put your SQL databases under version control? Why should you start doing it? Read more to find out. http://pubads.g.doubleclick.net/gampad/clk?id=49501711iu=/4140/ostg.clktrk ___ Fink-users mailing list Fink-users@lists.sourceforge.net List archive: http://news.gmane.org/gmane.os.macosx.fink.user Subscription management: https://lists.sourceforge.net/lists/listinfo/fink-users
Re: [Fink-users] rebuilding a modified package
On Fri, Aug 2, 2013 at 11:30 AM, Hanspeter Niederstrasser f...@snaggledworks.com wrote: If you're still testing out changes and want to do a quick test on Fink expanded source tree left over after using the -k flag, cd into the build directory (/sw/src/fink.build/coot-0.7.1.0-3/coot-0.7.1, then chown -R YOURID:admin . so that you have write permissions, patch the code, set the flags as needed (don't forget to *prepend* /sw/var/lib/fink/path-prefix-clang to $PATH), and try make again. Is there a way to rebuild the .deb files after I do this? Or will make install put everything in the correct place? thanks, Nat -- Get your SQL database under version control now! Version control is standard for application code, but databases havent caught up. So what steps can you take to put your SQL databases under version control? Why should you start doing it? Read more to find out. http://pubads.g.doubleclick.net/gampad/clk?id=49501711iu=/4140/ostg.clktrk___ Fink-users mailing list Fink-users@lists.sourceforge.net List archive: http://news.gmane.org/gmane.os.macosx.fink.user Subscription management: https://lists.sourceforge.net/lists/listinfo/fink-users
Re: [Fink-users] rebuilding a modified package
On 8/2/13 1:33 PM, Nat Echols wrote: On Fri, Aug 2, 2013 at 11:30 AM, Hanspeter Niederstrasser f...@snaggledworks.com mailto:f...@snaggledworks.com wrote: If you're still testing out changes and want to do a quick test on Fink expanded source tree left over after using the -k flag, cd into the build directory (/sw/src/fink.build/coot-0.7.1.0-3/coot-0.7.1, then chown -R YOURID:admin . so that you have write permissions, patch the code, set the flags as needed (don't forget to *prepend* /sw/var/lib/fink/path-prefix-clang to $PATH), and try make again. Is there a way to rebuild the .deb files after I do this? Or will make install put everything in the correct place? thanks, Nat make install would put everything in the root directory (/sw/src/root-packagename-version-revision). You could then run dpkg-deb -b manually on that to generate a .deb. -- Alexander Hansen, Ph.D. Fink User Liaison My package updates: http://finkakh.wordpress.com/ -- Get your SQL database under version control now! Version control is standard for application code, but databases havent caught up. So what steps can you take to put your SQL databases under version control? Why should you start doing it? Read more to find out. http://pubads.g.doubleclick.net/gampad/clk?id=49501711iu=/4140/ostg.clktrk ___ Fink-users mailing list Fink-users@lists.sourceforge.net List archive: http://news.gmane.org/gmane.os.macosx.fink.user Subscription management: https://lists.sourceforge.net/lists/listinfo/fink-users
Re: [Fink-users] rebuilding a modified package
On Fri, 02 Aug 2013 16:01:34 -0700, Alexander Hansen alexanderk.han...@gmail.com wrote: On 8/2/13 1:33 PM, Nat Echols wrote: On Fri, Aug 2, 2013 at 11:30 AM, Hanspeter Niederstrasser f...@snaggledworks.com mailto:f...@snaggledworks.com wrote: If you're still testing out changes and want to do a quick test on Fink expanded source tree left over after using the -k flag, cd into the build directory (/sw/src/fink.build/coot-0.7.1.0-3/coot-0.7.1, then chown -R YOURID:admin . so that you have write permissions, patch the code, set the flags as needed (don't forget to *prepend* /sw/var/lib/fink/path-prefix-clang to $PATH), and try make again. Is there a way to rebuild the .deb files after I do this? Or will make install put everything in the correct place? thanks, Nat make install would put everything in the root directory (/sw/src/root-packagename-version-revision). You could then run dpkg-deb -b manually on that to generate a .deb. 'make install' may well place things live in /sw rather than the .deb staging directory. And especially for coot, there is also a ton of hand-coded stuff in the install phase of the fink package beyond just make-install (see 'fink dumpinfo -finstallscript coot' or browse the 'fink dumpinfo -finfofile coot' package description itself for details). Depending on what changes you make, some of this may have to be re-run if you redo make-install itself after using the -K (capital-K) flag, you might at least have some effects of the original script retained. And you would also have the DEBIAN/ subdir of metadata files needed by 'dpkg-deb -b' (and *hopefully* dpkg would tolerate the changes to your package without requiring you to adjust that metadata manually to account for those changes). dan -- Daniel Macks dma...@netspace.org -- Get your SQL database under version control now! Version control is standard for application code, but databases havent caught up. So what steps can you take to put your SQL databases under version control? Why should you start doing it? Read more to find out. http://pubads.g.doubleclick.net/gampad/clk?id=49501711iu=/4140/ostg.clktrk ___ Fink-users mailing list Fink-users@lists.sourceforge.net List archive: http://news.gmane.org/gmane.os.macosx.fink.user Subscription management: https://lists.sourceforge.net/lists/listinfo/fink-users