1 # This Makefile understands the following targets:
3 # all (default): build wine
5 # clean: remove all intermediate files
6 # distclean: also remove all files created by configure
7 # install: install everything
8 # uninstall: uninstall everything
9 # depend: create the dependencies
10 # etags: create a TAGS file for Emacs.
11 # manpages: compile manpages for Wine API
14 # Main target to build
16 MAIN_TARGET
= @MAIN_TARGET@
20 TOPSRCDIR
= @top_srcdir@
50 graphics
/enhmetafiledrv \
51 graphics
/metafiledrv \
84 PROGSUBDIRS
= libtest programs
86 DOCSUBDIRS
= documentation
90 # Sub-directories to run make into
98 # Sub-directories to run make depend into
99 DEPENDSUBDIRS
= $(LIBSUBDIRS
) $(X11SUBDIRS
) $(EMUSUBDIRS
) $(DOCSUBDIRS
)
101 # Sub-directories to run make install into
102 INSTALLSUBDIRS
= $(DOCSUBDIRS
) $(INCSUBDIRS
)
105 controls
/controls.o \
107 dlls
/advapi32
/advapi32.o \
108 dlls
/avifil32
/avifil32.o \
109 dlls
/comctl32
/comctl32.o \
110 dlls
/commdlg
/commdlg.o \
111 dlls
/imagehlp
/imagehlp.o \
113 dlls
/msacm32
/msacm32.o \
116 dlls
/rasapi32
/rasapi32.o \
117 dlls
/shell32
/shell32.o \
118 dlls
/tapi32
/tapi32.o \
120 dlls
/version
/version.o \
121 dlls
/winaspi
/winaspi.o \
122 dlls
/winspool
/winspool.o \
123 dlls
/wnaspi32
/wnaspi32.o \
125 graphics
/graphics.o \
126 graphics
/enhmetafiledrv
/enhmetafiledrv.o \
127 graphics
/metafiledrv
/metafiledrv.o \
128 graphics
/psdrv
/psdrv.o \
129 graphics
/ttydrv
/ttydrv.o \
137 multimedia
/multimedia.o \
141 resources
/resources.o \
142 scheduler
/scheduler.o \
146 windows
/ttydrv
/ttydrv.o
149 graphics
/x11drv
/x11drv.o \
151 windows
/x11drv
/x11drv.o
154 debugger
/debugger.o \
155 graphics
/win16drv
/win16drv.o \
159 LIB_TARGET
= @LIB_TARGET@
161 ALT_LINK
= @ALT_LINK@
163 all: Makefile Make.rules
$(MAIN_TARGET
)
167 Make.rules
: Make.rules.in configure
168 @echo
$? is newer than
'Make.rules', please rerun .
/configure
!
171 install:: install_
$(MAIN_TARGET
)
173 uninstall:: uninstall_
$(MAIN_TARGET
)
177 lib
: $(LIBSUBDIRS
) $(X11SUBDIRS
) $(LIB_TARGET
)
179 wine wine.sym
: $(LIBSUBDIRS
) $(X11SUBDIRS
) $(LIB_TARGET
) $(EMUSUBDIRS
) dummy
180 $(CC
) -o wine
$(EMUOBJS
) $(ALT_LINK
) $(LDOPTIONS
) $(X_LIBS
) $(XLIB
) $(LIBS
)
181 nm
-n wine | grep
-v _compiled
>wine.sym
182 @echo
"Wine build complete."
184 libwine.a
: $(LIBOBJS
) $(X11OBJS
)
186 $(AR
) $@
$(LIBOBJS
) $(X11OBJS
)
189 libwine.so
.1.0: $(LIBOBJS
) $(X11OBJS
)
190 $(LDSHARED
) -o
$@
$(LIBOBJS
) $(X11OBJS
) $(LDOPTIONS
)
193 install_emu
: install_lib
194 [ -d
$(bindir) ] ||
$(MKDIR
) $(bindir)
195 $(INSTALL_PROGRAM
) wine
$(bindir)/wine
196 $(INSTALL_PROGRAM
) loader
/dos
/dosmod
$(bindir)/dosmod
198 uninstall_emu
: uninstall_lib
199 $(RM
) $(bindir)/wine
$(bindir)/dosmod
202 [ -d
$(libdir) ] ||
$(MKDIR
) $(libdir)
203 if
[ -f wine.sym
]; then
$(INSTALL_DATA
) wine.sym
$(libdir)/wine.sym
; fi
204 if
[ $(LIB_TARGET
) ]; then \
205 $(INSTALL_DATA
) $(LIB_TARGET
) $(libdir); \
206 if
[ $(LIB_TARGET
) = libwine.so
.1.0 ]; then
$(LDCONFIG
); fi \
210 cd
$(libdir); $(RM
) $(LIB_TARGET
) libwine.a libwine.so wine.sym
212 $(BUILDSUBDIRS
): dummy
215 install_programs
: dummy
216 @cd programs
; $(SUBMAKE
) install
218 uninstall_programs
: dummy
219 @cd programs
; $(SUBMAKE
) uninstall
222 for i in
$(INSTALLSUBDIRS
); do
(cd
$$i && $(MAKE
) install) || exit
1; done
225 for i in
$(INSTALLSUBDIRS
); do
(cd
$$i && $(MAKE
) uninstall) || exit
1; done
228 for i in
$(DEPENDSUBDIRS
); do
(cd
$$i && $(MAKE
) depend
) || exit
1; done
231 etags
`find $(TOPSRCDIR) -name '*.[chS]' -print | grep -v dbgmain`
234 -$(MKDIR
) $(TOPOBJDIR
)/documentation
/man3w
235 for i in
$(LIBSUBDIRS
); do
(cd
$$i && $(MAKE
) man
); done
238 -$(MKDIR
) $(TOPOBJDIR
)/documentation
/html
239 for i in
$(LIBSUBDIRS
); do
(cd
$$i && $(MAKE
) html
); done
242 for i in
$(BUILDSUBDIRS
); do
(cd
$$i; $(MAKE
) clean) || exit
1; done
243 for i in
include include/bitmaps
include/server
include/wine
; do
(cd
$$i; $(RM
) *.o \
#*\# .#* *~ *% *.bak *.orig *.rej *.flc); done
244 $(RM
) wine wine.sym libwine.a libwine.so
.1.0 libwine.so TAGS .
#*
247 $(RM
) config.
* Make.rules
include/config.h documentation
/wine.man
248 $(RM
) `find . \( -name Makefile -o -size 0 \) -print`
250 # We depend on configure above for checks, so we better don't use this rule.
251 #configure: configure.in
254 include/config.h.in
: configure.in
include/acconfig.h
255 autoheader
-l
include