1 # This Makefile understands the following targets:
3 # all (default): build wine
4 # clean: remove all intermediate files
5 # distclean: also remove all files created by configure
7 # testclean: clean test results to force running all tests again
8 # install-lib: install libraries needed to run applications
9 # install-dev: install development environment
10 # install: install everything
11 # uninstall: uninstall everything
12 # depend: create the dependencies
13 # etags: create a TAGS file for Emacs.
14 # manpages: compile manpages for Wine API
19 TOPSRCDIR
= @top_srcdir@
28 # Sub-directories to run make depend/clean into
41 # Sub-directories to install for install-lib
50 # Sub-directories to install for install-dev
56 # Sub-directories to install for both install-lib and install-dev
57 INSTALLBOTHSUBDIRS
= dlls
59 INSTALLSUBDIRS
= $(INSTALLDEVSUBDIRS
) $(INSTALLLIBSUBDIRS
)
61 # Sub-directories to run make test into
67 @echo
"Wine build complete."
69 WINAPI_CHECK_EXTRA_FLAGS
= --global
73 Make.rules
: Make.rules.in configure
74 @echo
$? is newer than
'Make.rules', please rerun .
/configure
!
78 $(RM
) $@
&& $(LN_S
) $(WINEWRAPPER
) $@
82 install-aclocal
: dummy
83 $(MKINSTALLDIRS
) $(datadir)/aclocal
84 $(INSTALL_DATA
) $(SRCDIR
)/aclocal.m4
$(datadir)/aclocal
/wine.m4
86 install-lib
:: $(INSTALLLIBSUBDIRS
:%=%/__install__
) $(INSTALLBOTHSUBDIRS
:%=%/__install-lib__
)
88 install-dev
:: $(INSTALLDEVSUBDIRS
:%=%/__install__
) $(INSTALLBOTHSUBDIRS
:%=%/__install-dev__
) install-aclocal
90 install:: install-lib install-dev install-aclocal
92 @if
test -n
"`LANG=C $(LDD) $(bindir)/wine|grep not.found`"; \
94 echo
"*************************************************" ; \
95 echo
"*************************************************" ; \
96 echo
"The installed Wine libraries will not be found!" ; \
97 echo
"You can either:" ; \
98 echo
" Add the line '$(libdir)' to /etc/ld.so.conf" ; \
99 echo
' export LD_LIBRARY_PATH=$$LD_LIBRARY_PATH:$(libdir)' ; \
100 echo
"*************************************************" ; \
101 echo
"*************************************************" ; \
104 uninstall:: $(INSTALLBOTHSUBDIRS
:%=%/__uninstall__
)
105 $(RM
) $(datadir)/aclocal
/wine.m4
106 -rmdir
$(datadir)/aclocal
108 $(INSTALLBOTHSUBDIRS
:%=%/__install-lib__
): dummy
109 cd
`dirname $@` && $(MAKE
) install-lib
111 $(INSTALLBOTHSUBDIRS
:%=%/__install-dev__
): dummy
112 cd
`dirname $@` && $(MAKE
) install-dev
114 $(INSTALLBOTHSUBDIRS
:%=%/__uninstall__
): dummy
115 cd
`dirname $@` && $(MAKE
) uninstall
117 .PHONY
: install-aclocal
$(INSTALLBOTHSUBDIRS
:%=%/__install-lib__
) $(INSTALLBOTHSUBDIRS
:%=%/__install-dev__
) $(INSTALLBOTHSUBDIRS
:%=%/__uninstall__
)
119 # Dependencies between directories
122 dlls
: library ole tools unicode
123 server
: library tools unicode
124 miscemu programs
: dlls library ole tools unicode
125 tools
: library unicode
127 dlls
/__install-lib__ dlls
/__install-dev__
: library ole tools unicode
128 server
/__install__
: library tools unicode
129 miscemu
/__install__ programs
/__install__
: library ole tools unicode dlls
/__install-lib__
130 library
/__install__
: library
132 tools
/__install__
: tools
133 unicode
/__install__
: unicode
137 checklink
:: $(TESTSUBDIRS
:%=%/__checklink__
)
138 $(CC
) -o checklink
$(TOPSRCDIR
)/library
/checklink.c
&& $(RM
) checklink
140 check test:: wine
$(TESTSUBDIRS
:%=%/__test__
)
142 crosstest
:: $(TESTSUBDIRS
:%=%/__crosstest__
)
147 etags
`find $(TOPSRCDIR) -name '*.[ch]' -a -not -name '*.spec.c' -a -not -name '*.glue.c' -a -not -name '*.dbg.c' -print`
150 $(MKINSTALLDIRS
) $(TOPOBJDIR
)/documentation
/man3w
151 for i in
$(SUBDIRS
); do
(cd
$$i && $(MAKE
) man
); done
154 $(MKINSTALLDIRS
) $(TOPOBJDIR
)/documentation
/html
155 for i in
$(SUBDIRS
); do
(cd
$$i && $(MAKE
) html
); done
161 $(RM
) config.
* configure.lineno TAGS Make.rules dlls
/Makedll.rules dlls
/Maketest.rules programs
/Makeprog.rules
include/config.h
162 $(RM
) -r autom4te.cache
163 $(RM
) `find . \( -name Makefile -o -size 0 \) -print`
165 .PHONY
: manpages htmlpages
distclean