LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (http://www.linuxquestions.org/questions/slackware-14/)
-   -   Install a vanilla SlackBuild and a patched one into two locations? (http://www.linuxquestions.org/questions/slackware-14/install-a-vanilla-slackbuild-and-a-patched-one-into-two-locations-4175439903/)

Z038 12-03-2012 11:53 PM

Install a vanilla SlackBuild and a patched one into two locations?
 
I installed a SlackBuild as written by the maintainer, and now I'd like to install a separate copy of the package into a different set of output directories with some patches applied.

What would be the best way to approach this?

The original SlackBuild installs elements of the package into fairly standard locations, like /usr/bin, /usr/doc, /usr/lib, /usr/share, etc. There are a lot of patches. I think they mainly go against sources for modules that end up in /usr/bin.

Z038 12-04-2012 12:02 AM

To be clear, I want to end up with two separate executable versions of the package, the standard one, and the one with the patches applied. I prefer the standard one to be in the normal PATH, but I want to be able to run the patched version from its installed location as needed.

tuxbg 12-04-2012 06:10 AM

Why don't you make two different slackbuilds,one for normal package,and other one for patch version?

Z038 12-04-2012 07:49 AM

I've started doing that. I'm not adept at creating SlackBuilds, so I'm not sure what all I need to change. I've looked at the templates and read the wiki, but in this case, I'll be modifying a copy of one that someone else built.

The final package name has to be different, or I won't be able to install both packages. So I need to change the name of the SlackBuild script, the names of desktop and png elements that were supplied with it, some of the directories on the configure statement. I think I will need to repackage the tarball so it has a different name and extracts to a differently named directory during the build, since a number of things in the SlackBuild depend on the $PRGNAM variable. There are some directories listed on the configure statement in the script that seem obvious to change, like prefix=, libdir=, sysconfdir=, mandir=, docdir=, localstatedir=.

Once I get the package built, how can I inspect it to ensure that it won't overlay any of the original package once installed?

Is another SlackBuild necessary or even helpful? Would it be better to just extract the tarball, patch it, and do a ./configure and a make and make install? If I do that, how do I control where it installs to?

tuxbg 12-04-2012 08:03 AM

--prefix=/opt ? on a patch one

Z038 12-04-2012 08:23 AM

ok. I think the SlackBuild route is overkill. I am going to try going simple with something like ./configure --prefix=$HOME/test && make && make install. And I'll run it as non-root first so I can see where it tries to install stuff and hopefully not clobber something important.


All times are GMT -5. The time now is 11:48 PM.