octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: trouble compiling


From: Jordi Gutiérrez Hermoso
Subject: Re: trouble compiling
Date: Fri, 18 May 2012 15:01:13 -0400

On 18 May 2012 14:53, Daniel J Sebald <address@hidden> wrote:
> One thing I don't like about the default build that has object code
> mixed in with source code is that "hg status" gives a big list of
> files when it is only a few I'm interested in.  Maybe as I use hg
> more I'll figure out nice ways of leaving out object files.

There is .hgignore, but I deliberately kept it small last time I
touched itbecause all those object files you're seeing should be in
the *build* directory, not in the source directory.

Basically, you should build like this (and maybe this belongs in the
HACKING file):

    address@hidden:~/octave$ ./autogen && cd ..
    address@hidden:~$ mkdir oct-build && cd oct-build
    address@hidden:~/oct-build$ ../octave/configure && make

i.e. sit in a build directory, but call the configure script from the
source directory. The only things in the .hgignore file are those that
autogen produces, and all of your object files will be out of your
source directory. You can also wipe your build by wiping your build
directory, and if you had some modifications or extra files in your
source directory, you don't need to be purging it.

This is useful in another way: parallel builds. You can have two
builds, one with -O2 optimisations and one without for debugging
purposes. Or one with 64-bit-indexing and one without fltk support.
You can update your source tree and independently later go into each
build tree and type "make" to refresh that build.

If you want to be building more than one branch, it's useful to have
two hg clones each checked out to a different branch, since updating
the same clone to different branches will touch all files and make
make(1) think that you need to rebuild more than you need to.

HTH,
- Jordi G. H.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]