TOPSRCDIR = @top_srcdir@
TOPOBJDIR = ..
SRCDIR    = @srcdir@
VPATH	  = @srcdir@
MODULE	  = none

IDL_H_SRCS = \
	activscp.idl \
	amstream.idl \
	amvideo.idl \
	austream.idl \
	comcat.idl \
	control.idl \
	ddstream.idl \
	dispex.idl \
	docobj.idl \
	downloadmgr.idl \
	exdisp.idl \
	hlink.idl \
	htiframe.idl \
	iads.idl \
	indexsrv.idl \
	mediaobj.idl \
	mimeinfo.idl \
	mlang.idl \
	mmstream.idl \
	mshtmhst.idl \
	mshtml.idl \
	msxml.idl \
	msxml2.idl \
	oaidl.idl \
	objidl.idl \
	objsafe.idl \
	ocidl.idl \
	ocmm.idl \
	oledb.idl \
	oleidl.idl \
	optary.idl \
	propidl.idl \
	pstore.idl \
	richole.idl \
	sensevts.idl \
	servprov.idl \
	shldisp.idl \
	shobjidl.idl \
	shtypes.idl \
	strmif.idl \
	tom.idl \
	unknwn.idl \
	urlhist.idl \
	urlmon.idl \
	wine/itss.idl \
	wtypes.idl \
	xmldom.idl \
	xmldso.idl

IDL_TLB_SRCS = \
	stdole2.idl

SRCDIR_INCLUDES = \
	$(IDL_TLB_SRCS) \
	$(IDL_H_SRCS) \
	accctrl.h \
	aclapi.h \
	adshlp.h \
	advpub.h \
	appmgmt.h \
	audevcod.h \
	aviriff.h \
	axcore.idl \
	axextend.idl \
	basetsd.h \
	basetyps.h \
	cderr.h \
	cfgmgr32.h \
	cguid.h \
	cierror.h \
	clusapi.h \
	commctrl.h \
	commdlg.h \
	compobj.h \
	cpl.h \
	custcntl.h \
	cvconst.h \
	d3d.h \
	d3d8.h \
	d3d8caps.h \
	d3d8types.h \
	d3d9.h \
	d3d9caps.h \
	d3d9types.h \
	d3dcaps.h \
	d3dhal.h \
	d3drm.h \
	d3drmdef.h \
	d3dtypes.h \
	d3dvec.inl \
	d3dx8core.h \
	dbghelp.h \
	dbinit.idl \
	dbprop.idl \
	dbs.idl \
	dbt.h \
	dciddi.h \
	dciman.h \
	dde.h \
	ddeml.h \
	ddk/compstui.h \
	ddk/hidsdi.h \
	ddk/ntddcdvd.h \
	ddk/ntddser.h \
	ddk/ntddtape.h \
	ddk/wdm.h \
	ddk/winsplp.h \
	ddraw.h \
	ddrawi.h \
	devenum.idl \
	devguid.h \
	digitalv.h \
	dinput.h \
	dispdib.h \
	dlgs.h \
	dls1.h \
	dls2.h \
	dmdls.h \
	dmerror.h \
	dmo.h \
	dmoreg.h \
	dmort.h \
	dmplugin.h \
	dmusbuff.h \
	dmusicc.h \
	dmusicf.h \
	dmusici.h \
	dmusics.h \
	dpaddr.h \
	dplay.h \
	dplay8.h \
	dplobby.h \
	dplobby8.h \
	dpnathlp.h \
	dsconf.h \
	dsdriver.h \
	dsgetdc.h \
	dshow.h \
	dsound.h \
	dsrole.h \
	dxdiag.h \
	dxerr8.h \
	dxerr9.h \
	dxfile.h \
	dyngraph.idl \
	errors.h \
	evcode.h \
	evntrace.h \
	excpt.h \
	exdispid.h \
	fci.h \
	fdi.h \
	guiddef.h \
	hlguids.h \
	htmlhelp.h \
	icm.h \
	icmpapi.h \
	idispids.h \
	imagehlp.h \
	imm.h \
	initguid.h \
	ipexport.h \
	iphlpapi.h \
	ipifcons.h \
	iprtrmib.h \
	iptypes.h \
	ks.h \
	ksguid.h \
	ksmedia.h \
	lm.h \
	lmaccess.h \
	lmapibuf.h \
	lmbrowsr.h \
	lmcons.h \
	lmerr.h \
	lmjoin.h \
	lmmsg.h \
	lmserver.h \
	lmshare.h \
	lmstats.h \
	lmwksta.h \
	lzexpand.h \
	mapi.h \
	mapicode.h \
	mapidefs.h \
	mapiguid.h \
	mapitags.h \
	mapiutil.h \
	mapival.h \
	mapix.h \
	mciavi.h \
	mcx.h \
	mediaerr.h \
	minmax.h \
	mmddk.h \
	mmreg.h \
	mmsystem.h \
	mprapi.h \
	msacm.h \
	msacmdlg.h \
	msacmdrv.h \
	mscat.h \
	mshtmcid.h \
	mshtmdid.h \
	msi.h \
	msidefs.h \
	msiquery.h \
	mssip.h \
	msvcrt/conio.h \
	msvcrt/crtdbg.h \
	msvcrt/ctype.h \
	msvcrt/direct.h \
	msvcrt/dirent.h \
	msvcrt/dos.h \
	msvcrt/eh.h \
	msvcrt/errno.h \
	msvcrt/fcntl.h \
	msvcrt/float.h \
	msvcrt/io.h \
	msvcrt/limits.h \
	msvcrt/locale.h \
	msvcrt/malloc.h \
	msvcrt/math.h \
	msvcrt/mbctype.h \
	msvcrt/mbstring.h \
	msvcrt/process.h \
	msvcrt/search.h \
	msvcrt/setjmp.h \
	msvcrt/share.h \
	msvcrt/signal.h \
	msvcrt/stddef.h \
	msvcrt/stdio.h \
	msvcrt/stdlib.h \
	msvcrt/string.h \
	msvcrt/sys/locking.h \
	msvcrt/sys/stat.h \
	msvcrt/sys/timeb.h \
	msvcrt/sys/types.h \
	msvcrt/sys/unistd.h \
	msvcrt/sys/utime.h \
	msvcrt/time.h \
	msvcrt/unistd.h \
	msvcrt/wchar.h \
	msvcrt/wctype.h \
	mswsock.h \
	msxml2did.h \
	msxmldid.h \
	nb30.h \
	ndrtypes.h \
	npapi.h \
	nspapi.h \
	ntddcdrm.h \
	ntddscsi.h \
	ntddstor.h \
	ntdsapi.h \
	ntquery.h \
	ntsecapi.h \
	ntsecpkg.h \
	ntstatus.h \
	objbase.h \
	objsel.h \
	odbcinst.h \
	ole2.h \
	ole2ver.h \
	oleauto.h \
	olectl.h \
	oledlg.h \
	pktdef.h \
	poppack.h \
	powrprof.h \
	profinfo.h \
	prsht.h \
	psapi.h \
	pshpack1.h \
	pshpack2.h \
	pshpack4.h \
	pshpack8.h \
	ras.h \
	reason.h \
	regstr.h \
	richedit.h \
	rmxfguid.h \
	rpc.h \
	rpcdce.h \
	rpcdcep.h \
	rpcndr.h \
	rpcnterr.h \
	rpcproxy.h \
	schannel.h \
	schemadef.h \
	schnlsp.h \
	sddl.h \
	secext.h \
	security.h \
	sensapi.h \
	setupapi.h \
	sfc.h \
	shellapi.h \
	shlguid.h \
	shlobj.h \
	shlwapi.h \
	sipbase.h \
	snmp.h \
	softpub.h \
	sql.h \
	sqlext.h \
	sqltypes.h \
	sspi.h \
	storage.h \
	svrapi.h \
	tapi.h \
	tchar.h \
	textserv.h \
	tlhelp32.h \
	tmschema.h \
	twain.h \
	usp10.h \
	uuids.h \
	uxtheme.h \
	ver.h \
	vfw.h \
	vfwmsgs.h \
	winbase.h \
	wincon.h \
	wincred.h \
	wincrypt.h \
	windef.h \
	windns.h \
	windows.h \
	windowsx.h \
	wine/debug.h \
	wine/exception.h \
	wine/library.h \
	wine/unicode.h \
	winerror.h \
	wingdi.h \
	wininet.h \
	winioctl.h \
	winldap.h \
	winnetwk.h \
	winnls.h \
	winnls32.h \
	winnt.h \
	winreg.h \
	winres.h \
	winresrc.h \
	winsock.h \
	winsock2.h \
	winspool.h \
	winsvc.h \
	wintab.h \
	wintabx.h \
	winternl.h \
	wintrust.h \
	winuser.h \
	winver.h \
	wmistr.h \
	wnaspi32.h \
	wownt32.h \
	ws2spi.h \
	ws2tcpip.h \
	wshisotp.h \
	wsipx.h \
	wsnwlink.h \
	wtsapi32.h \
	xcmc.h \
	xmldomdid.h \
	xmldsodid.h \
	zmouse.h

EXTRASUBDIRS = ddk msvcrt msvcrt/sys wine

INSTALLDIRS = \
	$(DESTDIR)$(includedir)/windows/ddk \
	$(DESTDIR)$(includedir)/windows \
	$(DESTDIR)$(includedir)/msvcrt/sys \
	$(DESTDIR)$(includedir)/msvcrt \
	$(DESTDIR)$(includedir)

@MAKE_RULES@

OBJDIR_INCLUDES = $(IDL_H_SRCS:.idl=.h) $(IDL_TLB_SRCS:.idl=.tlb)

all: $(OBJDIR_INCLUDES)

install:: $(OBJDIR_INCLUDES) $(INSTALLDIRS)
	for f in $(SRCDIR_INCLUDES); do case $$f in \
	  wine/*)   $(INSTALL_DATA) $(SRCDIR)/$$f $(DESTDIR)$(includedir)/`expr $$f : 'wine/\(.*\)'` ;; \
	  msvcrt/*) $(INSTALL_DATA) $(SRCDIR)/$$f $(DESTDIR)$(includedir)/$$f ;; \
	  *)        $(INSTALL_DATA) $(SRCDIR)/$$f $(DESTDIR)$(includedir)/windows/$$f ;; \
	esac; done
	for f in $(OBJDIR_INCLUDES); do case $$f in \
	  wine/*)   $(INSTALL_DATA) $$f $(DESTDIR)$(includedir)/`expr $$f : 'wine/\(.*\)'` ;; \
	  msvcrt/*) $(INSTALL_DATA) $$f $(DESTDIR)$(includedir)/$$f ;; \
	  *)        $(INSTALL_DATA) $$f $(DESTDIR)$(includedir)/windows/$$f ;; \
	esac; done

# Don't just do a rm -rf on $(includedir) -- don't want to wipe out
# anything extra the user may have put there.
uninstall::
	for f in $(SRCDIR_INCLUDES) $(OBJDIR_INCLUDES); do case $$f in \
	  wine/*)   $(RM) $(DESTDIR)$(includedir)/`expr $$f : 'wine/\(.*\)'` ;; \
	  msvcrt/*) $(RM) $(DESTDIR)$(includedir)/$$f ;; \
	  *)        $(RM) $(DESTDIR)$(includedir)/windows/$$f ;; \
	esac; done
	-rmdir $(INSTALLDIRS)

@DEPENDENCIES@  # everything below this line is overwritten by make depend
