XCOMM $XFree86: xc/lib/freetype2/freetype/config/Imakefile,v 1.9 2002/06/20 08:26:18 keithp Exp $

FREETYPETOP = $(TOP)/extras/freetype2
FREETYPESRC = $(FREETYPETOP)/src
FREETYPEINC = $(FREETYPETOP)/include/freetype

HEADERS= \
        ftconfig.h \
	ftheader.h \
        ftmodule.h \
        ftoption.h \
        ftstdlib.h

BuildIncludes($(HEADERS),freetype2/freetype/config,../../..)
InstallMultipleFlags($(HEADERS),$(INCDIR)/freetype2/freetype/config,$(INSTINCFLAGS))

LinkSourceFile(ftconfig.h,$(FREETYPEINC)/config)
LinkSourceFile(ftheader.h,$(FREETYPEINC)/config)
LinkSourceFile(ftmodule.h,$(FREETYPEINC)/config)
LinkSourceFile(ftoption.h,$(FREETYPEINC)/config)
LinkSourceFile(ftstdlib.h,$(FREETYPEINC)/config)

XCOMM Build and install a configure-compatible freetype-config

LinkSourceFile(freetype-config.in,$(FREETYPETOP)/builds/unix)

FREETYPE_VERSION=Freetype2Version

freetype-config: freetype-config.in
	sed -e s%@prefix@%$(PROJECTROOT)% -e s%@exec_prefix@%$(PROJECTROOT)% \
	-e s%@libdir@%$(USRLIBDIR)% -e s%@includedir@%$(INCDIR)% 	\
	-e s%@ft_version@%$(FREETYPE_VERSION)% \
	< freetype-config.in > $@

includes:: freetype-config

InstallNamedProg(freetype-config,freetype-config,$(BINDIR))

clean::
	RemoveFile(freetype-config)
