Now properly unloading multimedia drivers when winmm unloads.
[wine] / programs / Makefile.in
1 TOPSRCDIR = @top_srcdir@
2 TOPOBJDIR = ..
3 SRCDIR    = @srcdir@
4 VPATH     = @srcdir@
5 MODULE    = none
6
7 SUBDIRS = \
8         avitools \
9         clock \
10         cmdlgtst \
11         control \
12         expand \
13         notepad \
14         osversioncheck \
15         progman \
16         regapi \
17         regedit \
18         regsvr32 \
19         regtest \
20         uninstaller \
21         view \
22         wcmd \
23         wineconsole \
24         winedbg \
25         winefile \
26         winemine \
27         winepath \
28         winetest \
29         winhelp \
30         winver
31
32 # Sub-directories to run make install into
33 INSTALLSUBDIRS = \
34         avitools \
35         clock \
36         control \
37         expand \
38         notepad \
39         progman \
40         regedit \
41         regsvr32 \
42         uninstaller \
43         wcmd \
44         wineconsole \
45         winedbg \
46         winefile \
47         winemine \
48         winepath \
49         winhelp \
50         winver
51
52 # Programs to install in bin directory
53 # We don't install everything to avoid polluting /usr/bin too much
54 INSTALLPROGS = \
55         notepad \
56         progman \
57         regedit \
58         regsvr32 \
59         uninstaller \
60         wcmd \
61         wineconsole \
62         winedbg \
63         winefile \
64         winemine \
65         winepath \
66         winhelp
67
68 # Symlinks to apps that we want to run from inside the source tree
69 SYMLINKS = \
70         wineconsole.exe \
71         winedbg.exe
72
73 @MAKE_RULES@
74
75 all: wineapploader winelauncher $(SUBDIRS) $(SYMLINKS:%=%$(DLLEXT))
76
77 wineapploader: wineapploader.in
78         sed -e 's,@bindir\@,$(bindir),g' $(SRCDIR)/wineapploader.in >$@ || $(RM) $@
79
80 winelauncher: winelauncher.in
81         sed -e 's,@bindir\@,$(bindir),g' -e 's,@libdir\@,$(libdir),g' -e 's,@dlldir\@,$(dlldir),g' $(SRCDIR)/winelauncher.in >$@ || $(RM) $@
82
83 # Rules for installation
84
85 .PHONY: install-apploader install-progs install-progs.so $(INSTALLPROGS:%=%/__installprog__)
86
87 install-apploader: wineapploader dummy
88         $(MKINSTALLDIRS) $(bindir)
89         $(INSTALL_SCRIPT) wineapploader $(bindir)/wineapploader
90
91 $(INSTALLPROGS:%=%/__installprog__): install-apploader
92         $(RM) $(bindir)/`dirname $@` && $(LN) $(bindir)/wineapploader $(bindir)/`dirname $@`
93
94 install-progs.so: $(INSTALLPROGS:%=%/__installprog__)
95         $(RM) $(bindir)/wineapploader
96
97 install-progs: # nothing to do here
98
99 install:: winelauncher install-progs$(DLLEXT)
100         $(MKINSTALLDIRS) $(bindir)
101         $(INSTALL_SCRIPT) winelauncher $(bindir)/winelauncher
102
103 uninstall::
104         $(RM) $(bindir)/wineapploader $(bindir)/winelauncher $(INSTALLPROGS:%=$(bindir)/%)
105         -rmdir $(dlldir)
106
107 clean::
108         $(RM) wineapploader winelauncher $(SYMLINKS)
109
110 # Rules for testing
111
112 checklink:: $(SUBDIRS:%=%/__checklink__)
113
114 check test:: $(SUBDIRS:%=%/__test__)
115
116 # Rules for symlinks
117
118 wineconsole.exe$(DLLEXT): wineconsole/wineconsole.exe$(DLLEXT)
119         $(RM) $@ && $(LN_S) wineconsole/wineconsole.exe$(DLLEXT) $@
120
121 winedbg.exe$(DLLEXT): winedbg/winedbg.exe$(DLLEXT)
122         $(RM) $@ && $(LN_S) winedbg/winedbg.exe$(DLLEXT) $@
123
124 wineconsole/wineconsole.exe$(DLLEXT): wineconsole
125 winedbg/winedbg.exe$(DLLEXT): winedbg
126
127 ### Dependencies: