Date: Fri, 15 May 1998 11:14:14 +0300 From: Ruslan Ermilov <ru@ucb.crimea.ua> To: hackers@FreeBSD.ORG Subject: Problems installing things using /usr/share/mk/* Message-ID: <19980515111414.A12691@ucb.crimea.ua>
next in thread | raw e-mail | index | archive | help
Hi!
While recently ``making the world my own'' I noticed the strange thing.
One day (see below) I ran ``make buildworld''.
Next morning I've ran ``make installworld''.
Then, after succussful upgrade, I tried:
# cd /usr/src/bin/cat && make -n all
cc -O -static -o cat cat.o
Why the make wants to build the ``cat'' again, I thought?
Here's what were digged:
1. The ${PROG} target depends on ${DESTDIR}/usr/lib/libc.a
(line 64 of /usr/share/mk/bsd.prog.mk, RELENG_2_2)
In this particular case, the ``cat'' binary depends on /usr/lib/libc.a.
2. /usr/lib/libc.a is older than the /usr/obj/usr/src/bin/cat/cat.
-r--r--r-- 1 bin bin 539170 May 12 11:33 /usr/lib/libc.a
-rw-r--r-- 1 root bin 539170 May 10 19:52 /usr/obj/usr/src/lib/libc/libc.a
-rwxr-xr-x 1 root bin 63788 May 10 20:31 /usr/obj/usr/src/bin/cat/cat
Note, that original libc.a in /usr/obj was built earlier that the ``cat''.
That's why the make wants to build the ``cat'' binary again.
The reason why /usr/lib/libc.a gets older than the libc.a in /usr/obj
is in the way the libs are installed.
They are installed with ``install -c'' command.
How about to install binaries using ``install -p'' instead of
``install -c''. This will preserve the original modification times
of the files being installed and will no confuse the make.
There are many ways to implement this.
The one I thought of was to define and use something like ``PRESERVE=-p''
in bsd.*.mk. I tried it (modifying /usr/share/mk/*) and was success.
Anyone wants to comment?
Regards,
--
Ruslan Ermilov System Administrator
ru@ucb.crimea.ua United Commercial Bank
+380-652-247647 Simferopol, Crimea
2426679 ICQ Network, UIN
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19980515111414.A12691>
