# Copyright (C) 1996 by Andrey A. Chernov, Moscow, Russia.
#
# This software may be used, modified, copied, distributed, and sold,
# in both source and binary form provided that the above copyright
# and these terms are retained. Under no circumstances is the author
# responsible for the proper functioning of this software, nor does
# the author assume any responsibility for damages incurred with its use.

DESTDIR = /usr/X11R6/lib/X11/fonts/cyrillic/misc

.SUFFIXES: .bdf .pcf.Z

.bdf.pcf.Z:
	bdftopcf -t $< | compress -b12 > $@

FIXED   = koi6x10.pcf.Z koi6x13.pcf.Z koi8x13.pcf.Z koi9x15.pcf.Z koinil2.pcf.Z\
	  koi10x16b.pcf.Z koi10x20.pcf.Z koi12x24.pcf.Z

SRCFIX  = koi6x10.bdf koi6x13.bdf koi8x13.bdf koi9x15.bdf koinil2.bdf\
	  koi10x16b.bdf koi10x20.bdf koi12x24.bdf

all: fonts.dir

fixed: $(SRCFIX) $(FIXED)

fonts.dir: $(SRCFIX) $(FIXED)
	mkfontdir .

install:
	-mkdir -p $(DESTDIR)
	for i in $(FIXED) fonts.alias; \
	do \
	cp $$i $(DESTDIR)/$$i; \
	chmod 644 $(DESTDIR)/$$i; \
	done
	cd $(DESTDIR); mkfontdir .

clean:
	rm -f *.ff *.fb *.b *.pcf *.pcf.Z *.pcf.gz Families.list fonts.dir

cleanall: clean
