From: Russell E. O. <rowen@u.washington.edu> - 2009-05-14 17:30:19
|
I'm trying to install Valgrid 3.4.1 on a shared disk in such a way that all of our users can use it, though we have a mix of various flavors of linux box (x86 64-bit, 32-bit and AMD64). I assume this is the relevant section of the documentation, but I cannot make heads or tails out of it: --- begin quote --- Compiling For Multiple Architectures ==================================== You can compile the package for more than one kind of computer at the same time, by placing the object files for each architecture in their own directory. To do this, you must use a version of `make' that supports the `VPATH' variable, such as GNU `make'. `cd' to the directory where you want the object files and executables to go and run the `configure' script. `configure' automatically checks for the source code in the directory that `configure' is in and in `..'. --- end quote --- I have gnu make, so that's all right. I have my source code unpacked in a dir on my local disk. Normally I'd do this in the root of the unpacked source: ./configure --prefix=desired-location-on-shared-disk but apparently that's not sufficient to get a build that supports multiple platforms. So what to do instead? The instructions say: cd' to the directory where you want the object files and executables to go and run the `configure' script... but I don't know what that means. cd to the desired destination directory? If so, why would running configure in my source tree from the desired destination directory have any effect on the target platforms that are built? Or should I cd to various target-specific directories in the source distro? That makes more sense, but I haven't been able to find any such dirs. What am I missing? An example or some hints would be most appreciated. -- Russell |
From: tom f. <tf...@al...> - 2009-05-14 18:13:59
|
"Russell E. Owen" <rowen@u.washington.edu> writes: > I'm trying to install Valgrid 3.4.1 on a shared disk in such a way that > all of our users can use it, though we have a mix of various flavors of > linux box (x86 64-bit, 32-bit and AMD64). [snip] > `cd' to the > directory where you want the object files and executables to go and run > the `configure' script. `configure' automatically checks for the > source code in the directory that `configure' is in and in `..'. > > --- end quote --- > > I have my source code unpacked in a dir on my local disk. Normally I'd > do this in the root of the unpacked source: > ./configure --prefix=desired-location-on-shared-disk > but apparently that's not sufficient to get a build that supports > multiple platforms. So what to do instead? The instructions say: The documentation is simply telling you to do an out of source build. I'm not sure if you can use the same prefix for each different architecture; I'd say try it and test. I wouldn't say it's a huge deal to have the user choose their architecture though. In general, on Linux, you can't mix multiple archs to create anything like OS X's universal binary. So the exact same executable file cannot be executable on both ppc and x86_64, for example. Anyway, the process you want is something like this: cd /to/some/valgrind/directory wget http://.../valgrind-3.4.1.tar.bz2 tar jxvf valgrind-3.4.1.tar.bz2 mkdir x86_64-build mkdir x86-build mkdir ppc-build # or whatever, continue as necessary cd x86_64-build ../valgrind-3.4.1/configure --whatever # options appropriate for x86_64 make # likely `make install' too. cd ../x86-build ../valgrind-3.4.1/configure --whatever # options appropriate for x86 make and so on and so forth, once for each arch. "--whatever" might include "--prefix=/shared/disk/valgrind" in each case; but like I mentioned initially it might need to be "--prefix=/shared/disk/valgrind/x86_64", "--prefix=/shared/disk/valgrind/x86", etc. HTH, -tom |
From: Julian S. <js...@ac...> - 2009-05-14 18:27:04
|
On Thursday 14 May 2009, Russell E. Owen wrote: > I'm trying to install Valgrid 3.4.1 on a shared disk in such a way that > all of our users can use it, though we have a mix of various flavors of > linux box (x86 64-bit, 32-bit and AMD64). > > I assume this is the relevant section of the documentation, but I cannot > make heads or tails out of it: > > --- begin quote --- > > Compiling For Multiple Architectures > ==================================== > > You can compile the package for more than one kind of computer at the > same time, by placing the object files for each architecture in their > own directory. To do this, you must use a version of `make' that > supports the `VPATH' variable, such as GNU `make'. `cd' to the > directory where you want the object files and executables to go and run > the `configure' script. `configure' automatically checks for the > source code in the directory that `configure' is in and in `..'. Urr, that's standard GNU boilerplate guff. I don't know if it applies to us or not. Anyway (unless I misunderstand something) this should work right out of the box, no monkey business, no nothing. ./configure --prefix=/place/i/want/it/installed make make install Then /place/i/want/it/installed/bin/valgrind should be able to handle both 32-bit and 64-bit executables. One thing to look out for, though, is at the end of the ./configure run: you need to see Primary build target: AMD64_LINUX Secondary build target: X86_LINUX If you don't get that, then you will indeed be out of luck (w.r.t. a dual-arch build.) J |
From: Ashley P. <as...@pi...> - 2009-05-14 18:44:05
|
On Thu, 2009-05-14 at 20:30 +0200, Julian Seward wrote: > > Compiling For Multiple Architectures > > ==================================== > > > > You can compile the package for more than one kind of computer at > the > > same time, by placing the object files for each architecture in > their > > own directory. To do this, you must use a version of `make' that > > supports the `VPATH' variable, such as GNU `make'. `cd' to the > > directory where you want the object files and executables to go and > run > > the `configure' script. `configure' automatically checks for the > > source code in the directory that `configure' is in and in `..'. > > Urr, that's standard GNU boilerplate guff. I don't know if it applies > to us or not. Unless it's been fixed in the last month the VPATH stuff is broken on the HEAD, I posted a patch to make the basic build work last month but there are remaining problems, the tests don't work for example. Ashley, |
From: Nicholas N. <n.n...@gm...> - 2009-05-14 23:31:37
|
On Fri, May 15, 2009 at 4:44 AM, Ashley Pittman <as...@pi...> wrote: > > Unless it's been fixed in the last month the VPATH stuff is broken on > the HEAD, I posted a patch to make the basic build work last month but > there are remaining problems, the tests don't work for example. Which is something of a showstopper... if the tests don't run, then the devs won't use out-of-path builds, and if the devs won't use them they'll be basically untested and thus permanently broken. Since Valgrind has very little in the way of configure-time variability (no optimised vs. debug builds, for example) out-of-path builds don't seem to provide much benefit. So AFAIK there wouldn't be much benefit to supporting it, other than some people like doing it. N |
From: Ashley P. <as...@pi...> - 2009-05-15 09:52:07
|
On Fri, 2009-05-15 at 09:31 +1000, Nicholas Nethercote wrote: > On Fri, May 15, 2009 at 4:44 AM, Ashley Pittman <as...@pi...> wrote: > > > > Unless it's been fixed in the last month the VPATH stuff is broken on > > the HEAD, I posted a patch to make the basic build work last month but > > there are remaining problems, the tests don't work for example. > > Which is something of a showstopper... if the tests don't run, then > the devs won't use out-of-path builds, and if the devs won't use them > they'll be basically untested and thus permanently broken. I'd be prepared to put the effort in to fix this if requested, the build fix wasn't participatory tidy however so it might not be desirable. > Since Valgrind has very little in the way of configure-time > variability (no optimised vs. debug builds, for example) out-of-path > builds don't seem to provide much benefit. So AFAIK there wouldn't be > much benefit to supporting it, other than some people like doing it. It would certainly appear I'm the only person to ever use this. Ashley, |
From: Russell E. O. <rowen@u.washington.edu> - 2009-05-15 18:48:21
|
In article <200...@ac...>, Julian Seward <js...@ac...> wrote: > On Thursday 14 May 2009, Russell E. Owen wrote: > > I'm trying to install Valgrid 3.4.1 on a shared disk in such a way that > > all of our users can use it, though we have a mix of various flavors of > > linux box (x86 64-bit, 32-bit and AMD64). > > > > I assume this is the relevant section of the documentation, but I cannot > > make heads or tails out of it: > > > > --- begin quote --- > > > > Compiling For Multiple Architectures > > ==================================== > > > > You can compile the package for more than one kind of computer at the > > same time, by placing the object files for each architecture in their > > own directory. To do this, you must use a version of `make' that > > supports the `VPATH' variable, such as GNU `make'. `cd' to the > > directory where you want the object files and executables to go and run > > the `configure' script. `configure' automatically checks for the > > source code in the directory that `configure' is in and in `..'. > > Urr, that's standard GNU boilerplate guff. I don't know if it applies > to us or not. Highly confusing boilerplate (though tom fogal's reply helped clarify it). Fortunately I appears that I don't need it... > Anyway (unless I misunderstand something) this should work right out > of the box, no monkey business, no nothing. > > ./configure --prefix=/place/i/want/it/installed > make > make install > > Then /place/i/want/it/installed/bin/valgrind should be able to handle > both 32-bit and 64-bit executables. One thing to look out for, though, > is at the end of the ./configure run: you need to see > > Primary build target: AMD64_LINUX > Secondary build target: X86_LINUX > > If you don't get that, then you will indeed be out of luck (w.r.t. a > dual-arch build.) I did get that (or something very similar) and it seems to have built correctly. Thank you very much! -- Russell |