* PKGBUILD variables in arch
@ Christopher Moore
` Kyle
0 siblings, 1 reply; 4+ messages in thread
From: Christopher Moore @ UTC (permalink / raw)
To: speakup
Hello,
I'm trying to apply a patch to an arch package. Where does makepkg
extract downloaded files?
What are the values in $startdir and $Srcdir variables?
My PKGBUILD is in my home directory and I run makepkg from there.
cd $srcdir points to ~/src which is not where the files have been extracted.
TIA
Chris
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: PKGBUILD variables in arch
PKGBUILD variables in arch Christopher Moore
@ ` Kyle
` Steve Holmes
0 siblings, 1 reply; 4+ messages in thread
From: Kyle @ UTC (permalink / raw)
To: Speakup is a screen review system for Linux.
Your source and built binary package will be put into subdirectories
under the directory where your PKGBUILD file is. The sources are put
into ./src and the binary package is in ./pkg. It looks like these
settings can be overridden in /etc/makepkg.conf. You probably should use
a directory to store your PKGBUILD files other than your home directory.
Most of the time, you will want a package build directory, and each
PKGBUILD file should be in a subdirectory under the one you selected for
all your package builds. Example: I have my package builds in ~/build.
Under that is a subdirectory for each PKGBUILD I want to build, e.g.
~/build/svox-pico-git/, where I have my PKGBUILD file for that package,
which I hope to build as soon as I figure out why I get very strange
errors only when I use makepkg to build it. :) Using this clean
directory structure for each package makes it much easier to find the
sources for each package and to apply your patches. I've never tried
just putting PKGBUILD in my home directory and building it there to see
what would happen, but it can't be easy to sort out if something goes
wrong. Hope this helps a litttle, as I'm lacking in experience myself.
~Kyle
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: PKGBUILD variables in arch
` Kyle
@ ` Steve Holmes
` Christopher Moore
0 siblings, 1 reply; 4+ messages in thread
From: Steve Holmes @ UTC (permalink / raw)
To: speakup
Yes, never use your top level home directory to build these packages.
You will lose stuff in a hury; orI should say, you will lose your
place before you know it and not be able to find the files that the
build process created. I do like Cal suggested. I have a directory
called ~/abs and under that I have one called aur for packages I have
brought down from AUR and I haven't modified - just built to use or
possibly packages I'm maintaining for the AUR. I also have another
one for testing such as when I apply patches to a git orca tree or
if/when I might make my own changes to a program. So then under each
of these directories, I have the directory for each package. Within
the package directory, I 'cd into this directory and then do the
'makepkg' to build the package.
Now to answer your questions, the variables $STARTDIR points to the
top level directory of your package and is really not being used much
anymore. Instead, we usually will use symbols like $SRCDIR and
$PKGDIR; these symbols are pretty much self describing. $SRCDIR will
go into a directory called src right under the directory containing
your PKGBUILD file. the $PKGDIR will be called pkg and also lives in
the same directory as your PKGBUILD. in the pkg directory, is where
the installation environment for your package will go when it builds.
This is very revealing and can help you verify that your build script
is properly configuring things and placing objects in the right
folders. I find it fun to verify. The 'makepkg' step should download
the source tarball to the main package directory but untar the thing
into the src folder underneith.
What I have done on some occasions, is to temperarily insert an 'exit'
statement in the PKGBUILD right after the download or even after the
compile process so I can look around to be sure things aren't going
too far south. This is especially the case if I am build a brand new
PKGBUILD for something.
Hope this all helps.
On Tue, Mar 01, 2011 at 10:55:40PM -0500, Kyle wrote:
> Your source and built binary package will be put into subdirectories
> under the directory where your PKGBUILD file is. The sources are put
> into ./src and the binary package is in ./pkg. It looks like these
> settings can be overridden in /etc/makepkg.conf. You probably should
> use a directory to store your PKGBUILD files other than your home
> directory. Most of the time, you will want a package build
> directory, and each PKGBUILD file should be in a subdirectory under
> the one you selected for all your package builds. Example: I have my
> package builds in ~/build. Under that is a subdirectory for each
> PKGBUILD I want to build, e.g. ~/build/svox-pico-git/, where I have
> my PKGBUILD file for that package, which I hope to build as soon as
> I figure out why I get very strange errors only when I use makepkg
> to build it. :) Using this clean directory structure for each
> package makes it much easier to find the sources for each package
> and to apply your patches. I've never tried just putting PKGBUILD in
> my home directory and building it there to see what would happen,
> but it can't be easy to sort out if something goes wrong. Hope this
> helps a litttle, as I'm lacking in experience myself.
> ~Kyle
> _______________________________________________
> Speakup mailing list
> Speakup@braille.uwo.ca
> http://speech.braille.uwo.ca/mailman/listinfo/speakup
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: PKGBUILD variables in arch
` Steve Holmes
@ ` Christopher Moore
0 siblings, 0 replies; 4+ messages in thread
From: Christopher Moore @ UTC (permalink / raw)
To: Speakup is a screen review system for Linux.
Kyle and Steve,
Thanks for your helpful comments.
Chris
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~ UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
PKGBUILD variables in arch Christopher Moore
` Kyle
` Steve Holmes
` Christopher Moore
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).