How do i tell when my text file is busy?
M. G. Hand
marcus at pyuxt.UUCP
Thu May 17 00:20:35 AEST 1984
>> The method i have used (successfully) in the past tackles the problem in
>> another way. ... Then, when it comes to installing the program you use a
>> make line which effectively does this series of operations:
>> rm -f $(INSD)/n$(PRODUCT)
>> cp $(PRODUCT) $(INSD)/n$(PRODUCT)
>> cd $(INSD); mv $(PRODUCT) o$(PRODUCT); mv n$(PRODUCT) $(PRODUCT); \
>> rm -f o$(PRODUCT)
>The standard USG UNIX "install" command (in "/etc/install") has a "-o"
>option which does exactly this. The "install" command copies something
>to an install directory; if the "-o" option is specified, the current
>copy is renamed OLDwhatever and the new one moved there.
Thats all very well if you want to install stuff which either:
a) already exists (/etc/install will retain ownerships with -f)
b) you don't mind ending up with the executable being owned
by bin (user and group) and in 755 mode
Either way is OK, but you may have to go through some skullduggery to get
the ownership and permissions set up. What is REALLY required is other
options to /etc/install... one day, when i have time...
By the way, doesn't a command that allows *anybody* to install programs
with bin ownership strike you as a teansy bit insecure?
Marcus Hand (pyuxt!marcus)
More information about the Comp.unix.wizards
mailing list