Makefile 892 Bytes
#
# Makefile for patches20I ultra
#

include $(ROOT)/usr/include/make/PRdefs

OLD_DOCS =	Changefiles.jp \
		README.jp

OLD_SGIDOCS =   ${OLD_DOCS:.jp=.sgi}

OLD_PCDOCS =	${OLD_DOCS:.jp=.pc}

LDIRT = $(OLD_SGIDOCS) $(OLD_PCDOCS)

default:

include $(COMMONRULES)

install:        default $(OLD_SGIDOCS)
		for i in $(OLD_SGIDOCS:.sgi=); \
		do \
			$(INSTALL) -m 444 -F /usr/src/PR/doc/relnotes_old/patches20J/ultra \
			-src $$i.sgi $$i.jp ;\
		done

$(OLD_SGIDOCS):
		for i in $(OLD_DOCS:.jp=); \
		do \
			perl -ne 'if(/^#if(def.+PC|ndef.+SGI)/){$$a=1}elsif(/^#if(ndef.+PC|def.+SGI)/||/^#endif/){$$a=0}elsif(/^#else/){$$a^=1}elsif($$a==0){print}' $$i.jp > $$i.sgi; \
		done

pcdocs:
		for i in $(OLD_DOCS:.jp=); \
		do \
			perl -ne 'if(/^#if(def.+SGI|ndef.+PC)/){$$a=1}elsif(/^#if(ndef.+SGI|def.+PC)/||/^#endif/){$$a=0}elsif(/^#else/){$$a^=1}elsif($$a==0){print}' $$i.jp > $$i.pc; \
		done