gnustep-dev
[Top][All Lists]
Advanced

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

removing the 'make install'-->'make all' dependency


From: Nicola Pero
Subject: removing the 'make install'-->'make all' dependency
Date: Mon, 9 Dec 2002 15:01:27 +0000 (GMT)

Hi.

I'm considering removing the dependency of 'make install' from 'make all'.

Traditionally, whenever you type 'make install' inside a project built
using gnustep-make, a 'make all' is automatically performed as well.

I've recently started to challenge the assumption that this is necessarily
good :-)

The idea - I suppose - is that if you have changed your source code, but
not recompiled it, and you try to install, make will automatically find
out that you have done this little mess, and automatically compile the
changed bits before install.

But in practice, there seems to be a basic flaw in the process - which is
that you normally do 'make all' as a normal user, while you do 'make
install' as the superuser.

So, if 'make install' runs 'make all', you can end up compiling and
building as the superuser, which usually spreads confusion and problems.  
Typical problems are:

 - compiling as superuser usually creates object files which the normal
user has not enough permissions to touch.  Typically, you type 'make
install' as superuser, that compiles a .m file into an .o file and links.  
Next time you run 'make' as a normal user though, building will fail
because the normal user can't delete the .o file owned by the superuser!  
Annoying, and might be madly confusing for newbies.

 - building might require running additional/auxiliary programs (we have
examples in gnustep-make: plmerge, etc) and while the normal user
environment is usually setup to support running GNUstep programs, the
superuser environment might not be.  Then, those additional/auxiliary
programs would be run as superuser even if there is not any actual need
for doing it, and 'make install' will fail.

 - there is a huge overhead in the development process; when developing,
you usually do:

 <typing typing coding coding>
 make
 su -c 'make install'
 <checking that it works>

Now the fact that 'make install' always runs 'make all' a second time
causes the process to take up something like 50% more time; without the
dependency, a typical build/install session could be much faster.

Of course we loose the fact that if you've not compiled something, 'make
install' will detect it and complete the compilation.  But in my
experience, because 'make install' is run as root and not as the standard
user, when this 'automatical update of object files' happens is usually
more confusing/annoying than helpful ... it seems to me that the average
developer is actually paying (in terms of additional build time and
additional complications) a lot for this feature, which is very rarely
useful, and even when it is, often enough it counter-strikes when used.  
Some developers have to fight against this 'feature' of gnustep-make in
order to have their building process work properly, particularly when they
are trying to extend it to support their own specific building scripts, or
integrating their own build subsystems with gnustep-make.

So - I'd like to remove it.  Given that it's quite a hard change, I'd like
to hear comments/suggestions on this proposal.

Thanks.




reply via email to

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