[build] Add the assemblies in LIB_REFS to LIB_MCS_FLAGS automatically to reduce dupli...
[mono-project.git] / mcs / class / System.Web.Extensions / Makefile
blobe7dd5e0f017b684e0fc2384baabaa040c7d71980
1 thisdir = class/System.Web.Extensions
2 SUBDIRS = Test
3 include ../../build/rules.make
5 LIBRARY = System.Web.Extensions.dll
7 RESOURCE_FILES= \
8 ../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjax.debug.js \
9 ../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjax.js \
10 ../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxTimer.debug.js \
11 ../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxTimer.js \
12 ../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxWebForms.debug.js\
13 ../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxWebForms.js
15 RESOURCE_FILES_DIST= \
16 ../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjax.debug.js \
17 ../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjax.js \
18 ../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxTimer.debug.js \
19 ../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxTimer.js \
20 ../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxWebForms.debug.js\
21 ../MicrosoftAjaxLibrary/System.Web.Extensions/3.5.0.0/3.5.21022.8/MicrosoftAjaxWebForms.js\
22 ../MicrosoftAjaxLibrary/System.Web.Extensions/1.0.61025.0/MicrosoftAjax.debug.js \
23 ../MicrosoftAjaxLibrary/System.Web.Extensions/1.0.61025.0/MicrosoftAjax.js \
24 ../MicrosoftAjaxLibrary/System.Web.Extensions/1.0.61025.0/MicrosoftAjaxTimer.debug.js \
25 ../MicrosoftAjaxLibrary/System.Web.Extensions/1.0.61025.0/MicrosoftAjaxTimer.js \
26 ../MicrosoftAjaxLibrary/System.Web.Extensions/1.0.61025.0/MicrosoftAjaxWebForms.debug.js\
27 ../MicrosoftAjaxLibrary/System.Web.Extensions/1.0.61025.0/MicrosoftAjaxWebForms.js \
28 Resources/MicrosoftAjaxExtension.js \
29 Resources/MicrosoftAjaxWebFormsExtension.js
31 NUNIT_RESOURCE_FILES= \
32 Test/resources/Web.mono.config \
33 Test/resources/profile.config.4.5 \
34 Test/resources/profile.config.4.0 \
35 Test/resources/profile.config.2.0 \
36 $(wildcard Test/resources/*.as?x) \
37 $(wildcard ../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/*.cs) \
38 $(wildcard ../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/*.as?x) \
39 $(wildcard ../System.Web/Test/mainsoft/NunitWeb/NunitWeb/Resources/*.master)
41 CLASSLIB_DIR = $(topdir)/class/lib/$(PROFILE)
43 STANDALONE_RUNNER_SUPPORT_ASSEMBLY = $(CLASSLIB_DIR)/standalone-runner-support.dll
44 STANDALONE_TEST_MCS_FLAGS = $(LIB_MCS_FLAGS) $(PROFILE_MCS_FLAGS) -debug:full -r:$(STANDALONE_RUNNER_SUPPORT_ASSEMBLY) -r:System.Web.dll -r:System.Web.Extensions.dll -r:nunit.framework.dll
45 STANDALONE_TEST_ASSEMBLY = System.Web.Extensions_standalone_test_$(PROFILE).dll
46 STANDALONE_TEST_MAKEFRAG = $(depsdir)/$(STANDALONE_TEST_ASSEMBLY).makefrag
48 STANDALONE_TEST_RUNNER = ../System.Web/Test/tools/standalone-runner.exe
49 RUN_STANDALONE = $(TEST_RUNTIME) $(STANDALONE_TEST_RUNNER)
50 ifdef TESTNAME
51 RUN_STANDALONE += --test=$(TESTNAME)
52 endif
54 ifeq (4, $(FRAMEWORK_VERSION_MAJOR))
55 OTHER_LIB_MCS_FLAGS += -r:System.Web.ApplicationServices.dll
56 endif
58 LIB_REFS = System System.Core System.Drawing System.Data System.Data.Linq System.Xml System.Web System.Web.Services System.Configuration System.EnterpriseServices System.ServiceModel
59 LIB_MCS_FLAGS = \
60 -unsafe \
61 -define:NET_3_5 \
62 -define:SYSTEM_WEB_EXTENSIONS \
63 -r:$(corlib) \
64 $(OTHER_LIB_MCS_FLAGS) \
65 $(RESOURCE_FILES:%=/resource:%)
67 TEST_MCS_FLAGS = $(LIB_MCS_FLAGS) -doc:$(test_lib:.dll=.xml) -nowarn:219,169,1591 $(NUNIT_RESOURCE_FILES:%=/resource:%) -r:SystemWebTestShim.dll -define:SYSTEM_WEB_EXTENSIONS
69 EXTRA_DISTFILES = $(RESOURCE_FILES_DIST) $(NUNIT_RESOURCE_FILES) \
70 System.Web.Extensions_standalone_test.dll.sources \
71 Test/standalone-tests/Consts.cs.in \
72 Test/standalone-tests/DataPager_NumericPagerField_Bug615315.cs
74 build-standalone-runner-support:
75 $(MAKE) -C ../System.Web/ standalone-runner-support
76 $(MAKE) -C ../System.Web/Test/tools/ STANDALONE_SUPPORT_BUILT=1 standalone-runner.exe
78 run-standalone-test: build-standalone-runner-support $(STANDALONE_RUNNER_SUPPORT_MAKEFRAG) $(STANDALONE_TEST_MAKEFRAG) $(STANDALONE_TEST_ASSEMBLY)
79 $(RUN_STANDALONE) $(STANDALONE_TEST_ASSEMBLY)
81 $(STANDALONE_TEST_MAKEFRAG): System.Web.Extensions_standalone_test.dll.sources
82 @echo Creating $@ ...
83 @sed 's,^,$(STANDALONE_TEST_ASSEMBLY): ,' $< > $@
85 include $(STANDALONE_TEST_MAKEFRAG)
87 $(STANDALONE_TEST_ASSEMBLY): $(the_assembly) Test/standalone-tests/Consts.cs
88 $(CSCOMPILE) $(STANDALONE_TEST_MCS_FLAGS) -out:$@ -target:library @System.Web.Extensions_standalone_test.dll.sources
90 Test/standalone-tests/Consts.cs: Test/standalone-tests/Consts.cs.in
91 @sed 's,@SystemWebExtensionsClassDir@,$(shell pwd),' $< > $@
93 include ../../build/library.make