Subject: building the security set with "make release"
To: None <tech-install@netbsd.org>
From: Frederick Bruckman <fb@enteract.com>
List: tech-install
Date: 12/15/1999 05:22:38
As it stands now, "make release" without EXPORTABLE_SYSTEM=1 is not
useful, as the resulting base set is polluted with crypto binaries
such as "ftp" and "ed".. Worse, it deletes the existing ${RELEASEDIR}.
I propose to change the behavior of "make release" when
EXPORTABLE_SYSTEM is not set and ..domestic exists, to _only_ build
the security set. Then you could build a release like so

  cd usr/src && \
  EXPORTABLE_SYSTEM=1 make build && EXPORTABLE_SYSTEM=1 DESTDIR=... \
    RELEASEDIR=... UPDATE=1 BUILD=1 make release && \
  make build && DESTDIR=... RELEASEDIR=... UPDATE=1 BUILD=1 make release


Index: Makefile
===================================================================
RCS file: /cvsroot/basesrc/etc/Makefile,v
retrieving revision 1.129
diff -c -r1.129 Makefile
*** Makefile	1999/12/13 10:19:32	1.129
--- Makefile	1999/12/15 11:20:02
***************
*** 241,262 ****
  release snapshot snap_pre snap_md_pre snap_md_post:
  	@echo setenv RELEASEDIR before doing that!
  	@false
  .else
  release snapshot: distribution snap_pre snap_md_pre snap_kern snap_md_post
  	sh ../distrib/sets/maketars -s ../distrib/sets \
  		-d ${DESTDIR} -t ${RELEASEDIR}/binary/sets
- .if exists(../domestic) && !defined(EXPORTABLE_SYSTEM)
- 	sh ../distrib/sets/maketars -s ../distrib/sets \
- 		-d ${DESTDIR} -t ${RELEASEDIR}/binary/security secr
- 	sh ../distrib/sets/makesums -t ${RELEASEDIR}/binary/security
- .endif
  	sh ../distrib/sets/makesums -t ${RELEASEDIR}/binary/sets
  .ifdef EXTRA_KERNELS
  	sh ../distrib/sets/makesums -t ${RELEASEDIR}/binary/kernel '*.gz'
  .endif
  
  snap_pre:
  	/bin/rm -rf ${RELEASEDIR}
  	${INSTALL} ${INSTPRIV} -d -o root -g wheel -m 755 ${RELEASEDIR}
  .for dir in ${INSTALLATION_DIRS}
  	${INSTALL} ${INSTPRIV} -d -o root -g wheel -m 755 ${RELEASEDIR}/${dir}
--- 241,264 ----
  release snapshot snap_pre snap_md_pre snap_md_post:
  	@echo setenv RELEASEDIR before doing that!
  	@false
+ .elif exists(../domestic) && !defined(EXPORTABLE_SYSTEM)
+ release snapshot: distribution snap_pre
+ 	sh ../distrib/sets/maketars -s ../distrib/sets \
+ 		-d ${DESTDIR} -t ${RELEASEDIR}/binary/security secr
+ 	sh ../distrib/sets/makesums -t ${RELEASEDIR}/binary/security
  .else
  release snapshot: distribution snap_pre snap_md_pre snap_kern snap_md_post
  	sh ../distrib/sets/maketars -s ../distrib/sets \
  		-d ${DESTDIR} -t ${RELEASEDIR}/binary/sets
  	sh ../distrib/sets/makesums -t ${RELEASEDIR}/binary/sets
  .ifdef EXTRA_KERNELS
  	sh ../distrib/sets/makesums -t ${RELEASEDIR}/binary/kernel '*.gz'
  .endif
  
  snap_pre:
+ .if !(exists(../domestic) && !defined(EXPORTABLE_SYSTEM))
  	/bin/rm -rf ${RELEASEDIR}
+ .endif
  	${INSTALL} ${INSTPRIV} -d -o root -g wheel -m 755 ${RELEASEDIR}
  .for dir in ${INSTALLATION_DIRS}
  	${INSTALL} ${INSTPRIV} -d -o root -g wheel -m 755 ${RELEASEDIR}/${dir}