Add mkinstalldirs
[mono.git] / Makefile.am
1 AUTOMAKE_OPTIONS = foreign
2 ACLOCAL_AMFLAGS = -I .
3
4 SUBDIRS = po/mcs $(libgc_dir) $(eglib_dir) mono $(ikvm_native_dir) support docs data runtime scripts man samples web msvc
5
6 # Keep in sync with SUBDIRS
7 ## 'tools' is not normally built
8 DIST_SUBDIRS = po/mcs libgc $(eglib_dir) mono ikvm-native support docs data runtime scripts man samples web tools msvc
9
10 EXTRA_DIST= po.m4 mono-uninstalled.pc.in dtrace-prelink.sh build-mingw32.sh LICENSE mkinstalldirs
11
12 DISTCHECK_CONFIGURE_FLAGS = EXTERNAL_MCS=false EXTERNAL_RUNTIME=false
13
14 # Distribute the 'mcs' tree too
15 dist-hook:
16         test -d $(distdir)/mcs || mkdir $(distdir)/mcs
17         d=`cd $(distdir)/mcs && pwd`; cd $(mcs_topdir) && $(MAKE) PROFILE=default distdir=$$d dist-recursive
18         d=`cd $(distdir)/mcs && pwd`; cd $(mcs_topdir) && $(MAKE) PROFILE=net_2_0 distdir=$$d dist-recursive
19
20 pkgconfigdir = $(libdir)/pkgconfig
21 noinst_DATA = mono-uninstalled.pc
22 DISTCLEANFILES= mono-uninstalled.pc
23
24 .PHONY: get-monolite-latest mcs-do-compiler-tests compiler-tests bootstrap-world
25
26 # building with monolite
27 mcslib = $(mcs_topdir)/class/lib
28 monolite = $(mcslib)/monolite
29 monolite_url = http://mono.ximian.com/daily/monolite-latest.tar.gz
30 get-monolite-latest:
31         -rm -fr $(mcslib)/monolite-*
32         -mkdir -p $(mcslib)
33         test ! -d $(monolite) || test ! -d $(monolite).old || rm -fr $(monolite).old
34         test ! -d $(monolite) || mv -f $(monolite) $(monolite).old
35         cd $(mcslib) && { (wget -O- $(monolite_url) || curl $(monolite_url)) | gzip -d | tar xf - ; }
36         cd $(mcslib) && mv -f monolite-* monolite
37
38 compiler-tests: mcs-do-clean
39         $(MAKE) all
40         $(MAKE) mcs-do-compiler-tests
41
42 compiler-tests-net_2_0:
43         -rm -f $(mcs_topdir)/build/common/Consts.cs.save
44         -mv -f $(mcs_topdir)/build/common/Consts.cs $(mcs_topdir)/build/common/Consts.cs.save
45         cd $(mcs_topdir) && $(MAKE) PROFILE=net_2_0_bootstrap clean
46         cd $(mcs_topdir) && $(MAKE) PROFILE=net_2_0 clean
47         -mv -f $(mcs_topdir)/build/common/Consts.cs.save $(mcs_topdir)/build/common/Consts.cs
48         $(MAKE) all
49         $(MAKE) build_profiles=net_2_0 mcs-do-compiler-tests
50
51 bootstrap-world: compiler-tests
52         $(MAKE) install
53
54 bootstrap-world-net_2_0: compiler-tests-net_2_0
55         $(MAKE) install
56
57 # internal targets
58 mcs-do-clean:
59         cd runtime && $(MAKE) clean-local
60         cd mono/tests && $(MAKE) clean
61 mcs-do-compiler-tests:
62         cd runtime && $(MAKE) test_select='TEST_SUBDIRS="tests errors"' check-local
63         cd mono/tests && $(MAKE) check
64
65 win32getdeps:
66         wget http://www.go-mono.com/archive/pkgconfig-0.11-20020310.zip
67         wget http://www.go-mono.com/archive/glib-2.0.4-20020703.zip 
68         wget http://www.go-mono.com/archive/glib-dev-2.0.4-20020703.zip 
69         wget http://www.go-mono.com/archive/libiconv-1.7.zip 
70         wget http://www.go-mono.com/archive/libiconv-dev-1.7.zip 
71         wget http://www.go-mono.com/archive/libintl-0.10.40-20020101.zip
72         unzip -n -d / pkgconfig-0.11-20020310.zip
73         unzip -n -d / glib-2.0.4-20020703.zip
74         unzip -n -d / glib-dev-2.0.4-20020703.zip
75         unzip -n -d / libiconv-1.7.zip
76         unzip -n -d / libiconv-dev-1.7.zip
77         unzip -n -d / libintl-0.10.40-20020101.zip
78
79 win32setup:
80         makensis /DMILESTONE=$(VERSION) /DSOURCE_INSTALL_DIR=$(SOURCE_INSTALL_DIR) /DBUILDNUM=$(BUILDNUM) monowiz.win32.nsi
81
82 bootstrap: all
83         @echo "*** 'make bootstrap' is obsolete.  Just run 'make' to perform a combined mono+mcs build"
84         exit 1
85
86 patch-quiet:
87         find mono -name Makefile -exec scripts/patch-quiet.sh {} \;
88         find libgc -name Makefile -exec scripts/patch-quiet.sh {} \;