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@
49 graphics
/enhmetafiledrv \
50 graphics
/metafiledrv \
83 PROGSUBDIRS
= libtest programs
85 DOCSUBDIRS
= documentation
89 # Sub-directories to run make into
97 # Sub-directories to run make depend into
98 DEPENDSUBDIRS
= $(LIBSUBDIRS
) $(X11SUBDIRS
) $(EMUSUBDIRS
) $(DOCSUBDIRS
)
100 # Sub-directories to run make install into
101 INSTALLSUBDIRS
= $(DOCSUBDIRS
) $(INCSUBDIRS
)
104 controls
/controls.o \
106 dlls
/advapi32
/advapi32.o \
107 dlls
/avifil32
/avifil32.o \
108 dlls
/comctl32
/comctl32.o \
109 dlls
/commdlg
/commdlg.o \
110 dlls
/imagehlp
/imagehlp.o \
112 dlls
/msacm32
/msacm32.o \
115 dlls
/rasapi32
/rasapi32.o \
116 dlls
/shell32
/shell32.o \
117 dlls
/tapi32
/tapi32.o \
119 dlls
/version
/version.o \
120 dlls
/winaspi
/winaspi.o \
121 dlls
/wnaspi32
/wnaspi32.o \
123 graphics
/graphics.o \
124 graphics
/enhmetafiledrv
/enhmetafiledrv.o \
125 graphics
/metafiledrv
/metafiledrv.o \
126 graphics
/psdrv
/psdrv.o \
127 graphics
/ttydrv
/ttydrv.o \
135 multimedia
/multimedia.o \
139 resources
/resources.o \
140 scheduler
/scheduler.o \
144 windows
/ttydrv
/ttydrv.o
147 graphics
/x11drv
/x11drv.o \
149 windows
/x11drv
/x11drv.o
152 debugger
/debugger.o \
153 graphics
/win16drv
/win16drv.o \
157 LIB_TARGET
= @LIB_TARGET@
159 ALT_LINK
= @ALT_LINK@
161 all: Makefile Make.rules
$(MAIN_TARGET
)
165 Make.rules
: Make.rules.in configure
166 @echo
$? is newer than
'Make.rules', please rerun .
/configure
!
169 install:: install_
$(MAIN_TARGET
)
171 uninstall:: uninstall_
$(MAIN_TARGET
)
175 lib
: $(LIBSUBDIRS
) $(X11SUBDIRS
) $(LIB_TARGET
)
177 wine wine.sym
: $(LIBSUBDIRS
) $(X11SUBDIRS
) $(LIB_TARGET
) $(EMUSUBDIRS
) dummy
178 $(CC
) -o wine
$(EMUOBJS
) $(ALT_LINK
) $(LDOPTIONS
) $(X_LIBS
) $(XLIB
) $(LIBS
)
179 nm
-n wine | grep
-v _compiled
>wine.sym
180 @echo
"Wine build complete."
182 libwine.a
: $(LIBOBJS
) $(X11OBJS
)
184 $(AR
) $@
$(LIBOBJS
) $(X11OBJS
)
187 libwine.so
.1.0: $(LIBOBJS
) $(X11OBJS
)
188 $(LDSHARED
) -o
$@
$(LIBOBJS
) $(X11OBJS
) $(LDOPTIONS
)
191 install_emu
: install_lib
192 [ -d
$(bindir) ] ||
$(MKDIR
) $(bindir)
193 $(INSTALL_PROGRAM
) wine
$(bindir)/wine
194 $(INSTALL_PROGRAM
) loader
/dos
/dosmod
$(bindir)/dosmod
196 uninstall_emu
: uninstall_lib
197 $(RM
) $(bindir)/wine
$(bindir)/dosmod
200 [ -d
$(libdir) ] ||
$(MKDIR
) $(libdir)
201 if
[ $(LIB_TARGET
) ]; then
$(INSTALL_DATA
) $(LIB_TARGET
) $(libdir); fi
202 if
[ -f wine.sym
]; then
$(INSTALL_DATA
) wine.sym
$(libdir)/wine.sym
; fi
205 cd
$(libdir); $(RM
) $(LIB_TARGET
)
206 if
[ -f
$(libdir)/wine.sym
]; then
$(RM
) $(libdir)/wine.sym
; fi
208 $(BUILDSUBDIRS
): dummy
211 install_programs
: dummy
212 @cd programs
; $(SUBMAKE
) install
214 uninstall_programs
: dummy
215 @cd programs
; $(SUBMAKE
) uninstall
218 for i in
$(INSTALLSUBDIRS
); do
(cd
$$i && $(MAKE
) install) || exit
1; done
221 for i in
$(INSTALLSUBDIRS
); do
(cd
$$i && $(MAKE
) uninstall) || exit
1; done
224 for i in
$(DEPENDSUBDIRS
); do
(cd
$$i && $(MAKE
) depend
) || exit
1; done
227 etags
`find $(TOPSRCDIR) -name '*.[chS]' -print | grep -v dbgmain`
230 -$(MKDIR
) $(TOPOBJDIR
)/documentation
/man3w
231 for i in
$(LIBSUBDIRS
); do
(cd
$$i && $(MAKE
) man
); done
234 -$(MKDIR
) $(TOPOBJDIR
)/documentation
/html
235 for i in
$(LIBSUBDIRS
); do
(cd
$$i && $(MAKE
) html
); done
238 for i in
$(BUILDSUBDIRS
); do
(cd
$$i; $(MAKE
) clean) || exit
1; done
239 for i in
include include/bitmaps
include/server
include/wine
; do
(cd
$$i; $(RM
) *.o \
#*\# .#* *~ *% *.bak *.orig *.rej *.flc); done
240 $(RM
) wine wine.sym libwine.a libwine.so
.1.0 libwine.so TAGS .
#*
243 $(RM
) config.
* Make.rules
include/config.h
244 $(RM
) `find . \( -name Makefile -o -size 0 \) -print`
246 # We depend on configure above for checks, so we better don't use this rule.
247 #configure: configure.in
250 include/config.h.in
: configure.in
include/acconfig.h
251 autoheader
-l
include