Subject: misc/3111: build relies on executable shell scripts in tree
To: None <gnats-bugs@gnats.netbsd.org>
From: Klaus Klein <kleink@layla.inka.de>
List: netbsd-bugs
Date: 01/15/1997 13:41:40
>Number:         3111
>Category:       misc
>Synopsis:       build relies on executable shell scripts in tree
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    misc-bug-people (Misc Bug People)
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Wed Jan 15 04:50:00 1997
>Last-Modified:
>Originator:     Klaus Klein
>Organization:
private site
>Release:        970114
>Environment:
(mi)

>Description:
The system build process relies on three shell scripts inside the source
tree having execute permissions, which is not necessary. I can also think
of two drawbacks:
	- stylistic matters: after all, it's a _source_ tree
	- an FTP server offering the tree might not preserve file
	  permissions, e.g. due to a "0644 policy"

>How-To-Repeat:

>Fix:
(After patching, the scripts' execute permissions should be revoked.)

Index: Makefile
===================================================================
RCS file: /cvsroot/netbsd/src/bin/ksh/Makefile,v
retrieving revision 1.1.1.1
diff -b -c -r1.1.1.1 Makefile
*** Makefile	1996/12/20 13:14:18	1.1.1.1
--- Makefile	1997/01/15 12:16:38
***************
*** 11,22 ****
  
  # two steps to prevent the creation of a bogus siglist.out
  siglist.out: config.h sh.h siglist.in siglist.sh
! 	$(.CURDIR)/siglist.sh "$(CPP) $(CPPFLAGS) $(DEFS) -I. -I$(.CURDIR)" < $(.CURDIR)/siglist.in > tmpsiglist.out
  	mv tmpsiglist.out siglist.out
  
  # two steps to prevent the creation of a bogus emacs.out
  emacs.out: emacs.c
! 	$(.CURDIR)/emacs-gen.sh $(.CURDIR)/emacs.c > tmpemacs.out
  	mv tmpemacs.out emacs.out
  
  emacs.o: emacs.out
--- 11,22 ----
  
  # two steps to prevent the creation of a bogus siglist.out
  siglist.out: config.h sh.h siglist.in siglist.sh
! 	sh $(.CURDIR)/siglist.sh "$(CPP) $(CPPFLAGS) $(DEFS) -I. -I$(.CURDIR)" < $(.CURDIR)/siglist.in > tmpsiglist.out
  	mv tmpsiglist.out siglist.out
  
  # two steps to prevent the creation of a bogus emacs.out
  emacs.out: emacs.c
! 	sh $(.CURDIR)/emacs-gen.sh $(.CURDIR)/emacs.c > tmpemacs.out
  	mv tmpemacs.out emacs.out
  
  emacs.o: emacs.out
Index: Makefile
===================================================================
RCS file: /cvsroot/netbsd/src/share/zoneinfo/Makefile,v
retrieving revision 1.1.1.1
diff -b -c -r1.1.1.1 Makefile
*** Makefile	1996/12/20 13:23:49	1.1.1.1
--- Makefile	1997/01/15 12:16:48
***************
*** 38,44 ****
  REDO=		posix_only
  
  # Since "." may not be in PATH...
! YEARISTYPE=	${.CURDIR}/datfiles/yearistype.sh
  
  YDATA=		africa antarctica asia australasia \
  		europe northamerica southamerica pacificnew etcetera factory \
--- 38,44 ----
  REDO=		posix_only
  
  # Since "." may not be in PATH...
! YEARISTYPE=	"sh ${.CURDIR}/datfiles/yearistype.sh"
  
  YDATA=		africa antarctica asia australasia \
  		europe northamerica southamerica pacificnew etcetera factory \
>Audit-Trail:
>Unformatted: