Skip to content
Newer
Older
100644 245 lines (216 sloc) 7.53 KB
e281dcf Merged from `Makefile' and `Makefile.2nd'.
hornik authored
1 #
3f74187 Rename RHOME to R_HOME.
hornik authored
2 # ${R_HOME}/Makefile
e281dcf Merged from `Makefile' and `Makefile.2nd'.
hornik authored
3
4 VPATH = @srcdir@
5 srcdir = @srcdir@
6 top_srcdir = @top_srcdir@
7
8 top_builddir = .
9
10 include $(top_builddir)/Makeconf
11
7333662 s/:=/=/ as the former is not portable
maechler authored
12 GIT = `if [ -d "$(top_builddir)/.git" ]; then echo "git"; fi`
df157bc Help git lovers tracking R devel; patch proposed by Felipe Balbi at k…
maechler authored
13
a2d7cb8 Remove `stamp-R' when updating.
hornik authored
14 distdir = $(PACKAGE)-$(VERSION)
51797e1 move text NEWS files to doc
ripley authored
15 INSTFILES = COPYING
3e5a783 start moving top-level docs to doc/ for easier split installations
ripley authored
16 NON_SVN_INSTFILES = SVN-REVISION
c7b5dc4 branch update - not bugfree
pd authored
17 DISTFILES = $(INSTFILES) \
08649b0 arrange to install older NEWS files
ripley authored
18 ChangeLog INSTALL README VERSION VERSION-NICK \
fc709ca separate framework-specific stuff to a separate makefile
ripley authored
19 Makeconf.in Makefile.in Makefile.fw \
76a7f91 remove 'date-stamp' from DISTFILES
maechler authored
20 config.site configure configure.ac
84a017b more tidying up
ripley authored
21 SUBDIRS = m4 tools doc etc share src tests
22 SUBDIRS_WITH_NO_BUILD = po
a2d7cb8 Remove `stamp-R' when updating.
hornik authored
23
05890ca use javareconf to configure for Java during build
ripley authored
24 all: Makefile Makeconf R docs recommended vignettes javaconf
8fe7435 make recommended packages before vignettes (as use lattice, at least …
ripley authored
25 recommended: @USE_RECOMMENDED_PACKAGES_TRUE@ stamp-recommended
1f7ea5b Rewrite.
hornik authored
26
ba6787e branch update
pd authored
27 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
3f2fe45 Rename 'configure.in' to 'configure.ac'.
hornik authored
28 @cd $(top_builddir) && $(SHELL) ./config.status $@
b2a3d9a Misc fixes and cleanups.
hornik authored
29 Makeconf: $(srcdir)/Makeconf.in $(top_builddir)/config.status
3f2fe45 Rename 'configure.in' to 'configure.ac'.
hornik authored
30 @cd $(top_builddir) && $(SHELL) ./config.status $@
b2a3d9a Misc fixes and cleanups.
hornik authored
31
3548e85 build ac{include,local} in the build tree as needed, don't ship
ripley authored
32 ACLOCAL_M4 = aclocal.m4
a23f43e tweaks for POSIX 2008 and FreeBSD stat() calls
ripley authored
33 ## NB: this is duplicated in m4/Makefile.in
06e1709 Create `aclocal.m4' from `m4/*' via `acconfig.h'.
hornik authored
34 ACINCLUDE_DEPENDENCIES = \
4d29d3d Split `acinclude.m4' into new subdir `m4'.
hornik authored
35 m4/R.m4 \
5d81ae7 support of own bigendian test (from autoconf 2.61)
ripley authored
36 m4/bigendian.m4 \
37397fc add cairo-based X11, jpeg and png devices (not yet the default
ripley authored
37 m4/cairo.m4 \
d7c77fd more cleaning up of FLIBS
ripley authored
38 m4/clibs.m4 \
faf7cb1 branch update
ripley authored
39 m4/codeset.m4 \
611ff02 make use of local copy of ax_cxx_compile_stdcxx_11
ripley authored
40 m4/cxx_11.m4 \
f5eef21 add gettext-lib.m4, as not always already installed
ripley authored
41 m4/gettext.m4 m4/gettext-lib.m4 \
a23f43e tweaks for POSIX 2008 and FreeBSD stat() calls
ripley authored
42 m4/libtool.m4 m4/ltoptions.m4 m4/ltversion.m4 m4/ltsugar.m4 m4/lt~obsolete.m4 \
48564b5 improve OpenMP support
ripley authored
43 m4/openmp.m4 \
a23f43e tweaks for POSIX 2008 and FreeBSD stat() calls
ripley authored
44 m4/stat-time.m4
530510d configure needs a dependency on VERSION.
hornik authored
45 CONFIGURE_DEPENDENCIES = $(srcdir)/VERSION
b2a3d9a Misc fixes and cleanups.
hornik authored
46 config.status: $(srcdir)/configure
e6f219c Improve automatic remaking.
hornik authored
47 @$(SHELL) ./config.status --recheck
530510d configure needs a dependency on VERSION.
hornik authored
48 $(srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(srcdir)/configure.ac $(ACLOCAL_M4) $(CONFIGURE_DEPENDENCIES)
3548e85 build ac{include,local} in the build tree as needed, don't ship
ripley authored
49 @BD=`pwd`; cd $(srcdir) && $(AUTOCONF) -B $${BD}
50 $(ACLOCAL_M4): $(srcdir)/configure.ac acinclude.m4
51 @BD=`pwd`; cd $(srcdir) && $(ACLOCAL) --output=$${BD}/$@ -I $${BD}
f8d4977 lost dependencies
ripley authored
52 acinclude.m4: $(srcdir)/configure.ac $(ACINCLUDE_DEPENDENCIES)
3548e85 build ac{include,local} in the build tree as needed, don't ship
ripley authored
53 @(cd $(srcdir) && cat $(ACINCLUDE_DEPENDENCIES)) > $@
e281dcf Merged from `Makefile' and `Makefile.2nd'.
hornik authored
54
e1acdaf Start support for libtool and R shared library.
hornik authored
55 LIBTOOL_DEPS = @LIBTOOL_DEPS@
56 libtool: $(LIBTOOL_DEPS)
57 $(SHELL) ./config.status --recheck
58
0f0950c move some files from SVN sources to `make dist'.
ripley authored
59 R: Makefile svnonly
a437d9e Improve testing whether srcdir equals builddir.
hornik authored
60 @if test "$(BUILDDIR_IS_SRCDIR)" = no ; then \
6f16fac branch update
pd authored
61 for f in $(INSTFILES); do \
62 $(INSTALL_DATA) $(srcdir)/$${f} $(top_builddir); \
63 done; \
64 fi
89cc593 Make targets for build and (un)install more recursive.
hornik authored
65 @for d in $(SUBDIRS); do \
aa7eb80 branch update
pd authored
66 (cd $${d} && $(MAKE) R) || exit 1; \
0aaec01 Add demos in install and clean.
hornik authored
67 done
8cbcb25 Remove 'autom4te.cache' in 'make maintainer-clean'.
hornik authored
68 @test -f src/library/stamp-docs || \
86e6463 more use of $(ECHO)
ripley authored
69 $(ECHO) "you should 'make docs' now ..."
e281dcf Merged from `Makefile' and `Makefile.2nd'.
hornik authored
70
1c06edb branch update
ripley authored
71 docs: R FORCE
640f330 Build HTML versions of texinfo manuals.
hornik authored
72 -@(cd doc && $(MAKE) $@)
73 -@(cd src/library && $(MAKE) $@)
1f7ea5b Rewrite.
hornik authored
74 FORCE:
e281dcf Merged from `Makefile' and `Makefile.2nd'.
hornik authored
75
49dde09 updated mechanism re. recommended packages
pd authored
76 stamp-recommended: R docs
368bb7f Improve target 'stamp-recommended'.
hornik authored
77 @(cd src/library/Recommended && $(MAKE))
3ca2d9e Further changes related to recommended packages.
hornik authored
78
6767c89 Unix fix for installing vignettes when building from a tarball
ripley authored
79 ## One of the grid vignettes requires lattice
8fe7435 make recommended packages before vignettes (as use lattice, at least …
ripley authored
80 vignettes: stamp-recommended
1478e36 Don't catch build vignette failures.
hornik authored
81 @(cd src/library && $(MAKE) $@)
8fe7435 make recommended packages before vignettes (as use lattice, at least …
ripley authored
82
04b9e16 tweaks
ripley authored
83 ## This needs packages built, hence 'R' dependence on 'javaconf'
c916969 stop continual re-build
ripley authored
84 ## javareconf gets remade often.
85 stamp-java : etc/javaconf $(srcdir)/src/scripts/javareconf.in
04ac159 Allow disabling Java configuration.
hornik authored
86 @WANT_JAVA_TRUE@ @$(ECHO) "configuring Java ..."
87 @WANT_JAVA_TRUE@ @-bin/R CMD javareconf
05890ca use javareconf to configure for Java during build
ripley authored
88 @touch stamp-java
89
04b9e16 tweaks
ripley authored
90 javaconf: R
91 @$(MAKE) stamp-java
05890ca use javareconf to configure for Java during build
ripley authored
92
93
eeb8523 make install-strip
ripley authored
94 install install-strip: installdirs svnonly
89cc593 Make targets for build and (un)install more recursive.
hornik authored
95 @for d in $(SUBDIRS); do \
aa7eb80 branch update
pd authored
96 (cd $${d} && $(MAKE) $@) || exit 1; \
a16651d New targets Makefile and uninstall.
hornik authored
97 done
fd3265c Fix installation bug.
hornik authored
98 @for f in $(INSTFILES); do \
78bf050 add DESTDIR support
ripley authored
99 $(INSTALL_DATA) $(srcdir)/$${f} "$(DESTDIR)$(rhome)"; \
fd3265c Fix installation bug.
hornik authored
100 done
51797e1 move text NEWS files to doc
ripley authored
101 @for f in $(NON_SVN_INSTFILES); do \
78bf050 add DESTDIR support
ripley authored
102 $(INSTALL_DATA) $${f} "$(DESTDIR)$(rhome)"; \
0f0950c move some files from SVN sources to `make dist'.
ripley authored
103 done
fc709ca separate framework-specific stuff to a separate makefile
ripley authored
104 @WANT_R_FRAMEWORK_TRUE@ $(MAKE) -f $(srcdir)/Makefile.fw top_srcdir=$(top_srcdir) $@
c614025 new fixes for the R framework installation: patches to the SHLIB scri…
iacus authored
105
0f0950c move some files from SVN sources to `make dist'.
ripley authored
106 svnonly:
147bf7a repair last attempt at a fix
ripley authored
107 @if test ! -f "$(srcdir)/doc/FAQ" || test -f non-tarball ; then \
4d49f36 simplify make distclean
ripley authored
108 (cd doc/manual && $(MAKE) front-matter html-non-svn) ; \
0f0950c move some files from SVN sources to `make dist'.
ripley authored
109 touch non-tarball ; \
df157bc Help git lovers tracking R devel; patch proposed by Felipe Balbi at k…
maechler authored
110 (cd $(srcdir); LC_ALL=C TZ=GMT $(GIT) svn info || $(ECHO) "Revision: -99") 2> /dev/null \
beaf15d try harder to get svn info
ripley authored
111 | sed -n -e '/^Revision/p' -e '/^Last Changed Date/'p \
7b29647 updates for SVN 1.4.0
ripley authored
112 | cut -d' ' -f1,2,3,4 > SVN-REVISION-tmp ; \
4f13e53 trap HK Leung misuse
ripley authored
113 if test "`cat SVN-REVISION-tmp`" = "Revision: -99"; then \
114 $(ECHO) "ERROR: not an svn checkout"; \
115 exit 1; \
116 fi; \
d2f1b3f make non-executable scripts intended to be used via $(SHELL)
ripley authored
117 $(SHELL) $(top_srcdir)/tools/move-if-change SVN-REVISION-tmp SVN-REVISION ; \
beaf15d try harder to get svn info
ripley authored
118 rm -f SVN-REVISION-tmp ; \
0f0950c move some files from SVN sources to `make dist'.
ripley authored
119 else \
120 if test "$(BUILDDIR_IS_SRCDIR)" = no ; then \
121 for f in $(NON_SVN_INSTFILES); do \
5e24ffc update DISTFILES, tweak install from make dist tarball
ripley authored
122 $(INSTALL_DATA) $(srcdir)/$${f} $(top_builddir); \
0f0950c move some files from SVN sources to `make dist'.
ripley authored
123 done \
124 fi \
125 fi
c614025 new fixes for the R framework installation: patches to the SHLIB scri…
iacus authored
126
6322482 Use R_DYLIB_EXT instead of DYLIB_EXT for the R dylibs so that these
hornik authored
127 @WANT_R_STATIC_FALSE@libR_la = libR$(R_DYLIB_EXT)
2db35f5 more support of make install-libR
ripley authored
128 @WANT_R_STATIC_TRUE@libR_la = libR.a
d8c4034 add target to install libR.so
ripley authored
129 install-libR:
2db35f5 more support of make install-libR
ripley authored
130 @if test -f lib$(R_ARCH)/$(libR_la); then $(MAKE) install-libR-exists; fi
d8c4034 add target to install libR.so
ripley authored
131 install-libR-exists:
78bf050 add DESTDIR support
ripley authored
132 @$(MKINSTALLDIRS) "$(DESTDIR)${libdir}"
2db35f5 more support of make install-libR
ripley authored
133 @$(INSTALL_DATA) -m755 lib$(R_ARCH)/$(libR_la) "$(DESTDIR)${libdir}"
df157bc Help git lovers tracking R devel; patch proposed by Felipe Balbi at k…
maechler authored
134 uninstall-libR:
2db35f5 more support of make install-libR
ripley authored
135 @rm -f "$(DESTDIR)${libdir}/$(libR_la)"
d8c4034 add target to install libR.so
ripley authored
136
afe5b25 Improve installdirs target.
hornik authored
137 installdirs:
78bf050 add DESTDIR support
ripley authored
138 @$(MKINSTALLDIRS) "$(DESTDIR)$(rhome)"
e281dcf Merged from `Makefile' and `Makefile.2nd'.
hornik authored
139 uninstall:
89cc593 Make targets for build and (un)install more recursive.
hornik authored
140 @(for d in $(SUBDIRS); do rsd="$${d} $${rsd}"; done; \
141 for d in $${rsd}; do (cd $${d} && $(MAKE) $@); done)
51797e1 move text NEWS files to doc
ripley authored
142 @for f in $(INSTFILES) $(NON_SVN_INSTFILES); do \
78bf050 add DESTDIR support
ripley authored
143 rm -f "$(DESTDIR)$(rhome)/$${f}"; \
a16651d New targets Makefile and uninstall.
hornik authored
144 done
78bf050 add DESTDIR support
ripley authored
145 @rm -rf "$(DESTDIR)$(Rexecbindir)" "$(DESTDIR)$(rhome)/lib"
146 @rmdir "$(DESTDIR)$(rhome)" 2>/dev/null \
86e6463 more use of $(ECHO)
ripley authored
147 || $(ECHO) " dir $(DESTDIR)$(rhome) not removed"
6322482 Use R_DYLIB_EXT instead of DYLIB_EXT for the R dylibs so that these
hornik authored
148 @rm -f "$(DESTDIR)${libdir}/libR$(R_DYLIB_EXT)"
1dbd666 added install-aqua target to the install procedure
iacus authored
149
1f7ea5b Rewrite.
hornik authored
150 mostlyclean: clean
e281dcf Merged from `Makefile' and `Makefile.2nd'.
hornik authored
151 clean:
4b393dc Reverse order of SUBDIRS for clean/disclean.
hornik authored
152 @(for d in $(SUBDIRS); do rsd="$${d} $${rsd}"; done; \
153 for d in $${rsd}; do (cd $${d} && $(MAKE) $@); done)
a437d9e Improve testing whether srcdir equals builddir.
hornik authored
154 @if test "$(BUILDDIR_IS_SRCDIR)" = no ; then \
120ce4a sort out some make distclean/make uninstall issues
ripley authored
155 rm -f $(INSTFILES); \
6f16fac branch update
pd authored
156 fi
1f7ea5b Rewrite.
hornik authored
157 distclean: clean
4b393dc Reverse order of SUBDIRS for clean/disclean.
hornik authored
158 @(for d in $(SUBDIRS); do rsd="$${d} $${rsd}"; done; \
159 for d in $${rsd}; do (cd $${d} && $(MAKE) $@); done)
02384a6 migrate compiled translations to a separate package
ripley authored
160 @rm -f po/Makefile
7a48a55 distclean should remove the lib directory
ripley authored
161 -@rm -rf bin include lib library modules gnome
0f0950c move some files from SVN sources to `make dist'.
ripley authored
162 @if test -f non-tarball ; then \
51797e1 move text NEWS files to doc
ripley authored
163 rm -f $(NON_SVN_INSTFILES) non-tarball doc/FAQ doc/RESOURCES doc/html/resources.html doc/html/NEWS.html; \
4d49f36 simplify make distclean
ripley authored
164 fi
165 @if test "$(BUILDDIR_IS_SRCDIR)" = no ; then \
166 rm -f $(NON_SVN_INSTFILES); \
65b8dd2 improve cleaning
ripley authored
167 rm -rf $(SUBDIRS) $(SUBDIRS_WITH_NO_BUILD); \
0f0950c move some files from SVN sources to `make dist'.
ripley authored
168 fi
811bf59 better cleanup
ripley authored
169 -@rm -rf libconftest.dSYM
f7688be Misc Makefile cleanups: FIXME, NOTE, quoting, and so on.
hornik authored
170 -@rm -f Makeconf Makefile Makefile.bak Makefrag.* \
05890ca use javareconf to configure for Java during build
ripley authored
171 config.cache config.log config.status libtool stamp-java \
0f0950c move some files from SVN sources to `make dist'.
ripley authored
172 $(ACLOCAL_M4) acinclude.m4 $(distdir).tar.gz
1f7ea5b Rewrite.
hornik authored
173 maintainer-clean: distclean
86e6463 more use of $(ECHO)
ripley authored
174 @$(ECHO) "This command is intended for maintainers to use; it"
175 @$(ECHO) "deletes files that may need special rules to rebuild"
f7688be Misc Makefile cleanups: FIXME, NOTE, quoting, and so on.
hornik authored
176 @(for d in $(SUBDIRS); do rsd="$${d} $${rsd}"; done; \
177 for d in $${rsd}; do (cd $${d} && $(MAKE) $@); done)
8cbcb25 Remove 'autom4te.cache' in 'make maintainer-clean'.
hornik authored
178 -@(cd $(srcdir) && rm -rf autom4te.cache)
e281dcf Merged from `Makefile' and `Makefile.2nd'.
hornik authored
179
a2d7cb8 Remove `stamp-R' when updating.
hornik authored
180 dist: dist-unix
181 dist-unix: distdir
182 -chmod -R a+r $(distdir)
96d3913 prevent wrong permissions from make dist
pd authored
183 -chmod -R go-w $(distdir)
25a5dc6 name dist tarball more sensibly
ripley authored
184 distname=`$(srcdir)/tools/GETDISTNAME`; \
86e6463 more use of $(ECHO)
ripley authored
185 dirname=`$(ECHO) $${distname} | sed -e s/_.*//`; \
bfe6497 some systems think 'mv a a' is an error
ripley authored
186 if test $(distdir) != $${dirname} ; then \
187 mv $(distdir) $${dirname}; \
188 fi ; \
5f19299 improve names of dist tarballs
ripley authored
189 GZIP=$(GZIP) $(TAR) czf $${distname}.tar.gz $${dirname}; \
190 rm -rf $${dirname}
a2d7cb8 Remove `stamp-R' when updating.
hornik authored
191 dist-win:
f7fda40 always have SVN-REVISION file
ripley authored
192 distdir: $(DISTFILES) vignettes
a2d7cb8 Remove `stamp-R' when updating.
hornik authored
193 @rm -rf $(distdir)
194 @mkdir $(distdir)
195 @-chmod 755 $(distdir)
196 @for f in $(DISTFILES); do \
197 test -f $(distdir)/$${f} \
d061198 Replace leading spaces by tabs.
hornik authored
198 || ln $(srcdir)/$${f} $(distdir)/$${f} 2>/dev/null \
a2d7cb8 Remove `stamp-R' when updating.
hornik authored
199 || cp -p $(srcdir)/$${f} $(distdir)/$${f}; \
200 done
7bd5de5 add NEWS[.pdf] back to tarball
ripley authored
201 @for f in $(NON_SVN_INSTFILES) ; do \
0f0950c move some files from SVN sources to `make dist'.
ripley authored
202 cp -p $${f} $(distdir)/$${f}; \
203 done
a2d7cb8 Remove `stamp-R' when updating.
hornik authored
204 @for d in $(SUBDIRS); do \
205 test -d $(distdir)/$${d} \
206 || mkdir $(distdir)/$${d} \
207 || exit 1; \
208 chmod 755 $(distdir)/$${d}; \
209 (cd $${d} && $(MAKE) distdir) \
210 || exit 1; \
d061198 Replace leading spaces by tabs.
hornik authored
211 done
189bc25 Use Make variable 'SUBDIRS_WITH_NO_BUILD' to indicate subdirs where u…
hornik authored
212 @for d in $(SUBDIRS_WITH_NO_BUILD); do \
b9368b1 Teach make dist to exclude .svn subdirs.
hornik authored
213 ((cd $(srcdir); $(TAR) -c -f - $(DISTDIR_TAR_EXCLUDE) $${d}) \
189bc25 Use Make variable 'SUBDIRS_WITH_NO_BUILD' to indicate subdirs where u…
hornik authored
214 | (cd $(distdir); $(TAR) -x -f -)) \
a2d7cb8 Remove `stamp-R' when updating.
hornik authored
215 || exit 1; \
216 done
bf14343 start adding package parallel
ripley authored
217 @for d in grid parallel utils; do \
218 mkdir -p $(distdir)/src/library/$${d}/inst/doc; \
219 cp library/$${d}/doc/*.pdf $(distdir)/src/library/$${d}/inst/doc; \
220 done
0f0950c move some files from SVN sources to `make dist'.
ripley authored
221 @(cd $(distdir); tools/link-recommended)
e281dcf Merged from `Makefile' and `Makefile.2nd'.
hornik authored
222
5b301ef start removing support for DVI manuals (but Rd2dvi is still supported
ripley authored
223 info pdf:
a16651d New targets Makefile and uninstall.
hornik authored
224 -@(cd doc && $(MAKE) $@)
5b301ef start removing support for DVI manuals (but Rd2dvi is still supported
ripley authored
225 install-info install-pdf:
10da9f2 branch update
pd authored
226 -@(cd doc/manual && $(MAKE) $@)
5b301ef start removing support for DVI manuals (but Rd2dvi is still supported
ripley authored
227 uninstall-info uninstall-pdf:
10da9f2 branch update
pd authored
228 -@(cd doc/manual && $(MAKE) $@)
e281dcf Merged from `Makefile' and `Makefile.2nd'.
hornik authored
229
0b31d29 add isstall-tests
ripley authored
230 install-tests:
231 -@(cd tests && $(MAKE) $@)
232 -@(cd src/library && $(MAKE) $@)
233
234 uninstall-tests:
235 -@(cd src/library && $(MAKE) $@)
236 -@(cd tests && $(MAKE) $@)
237
b70611a 'make check-recommended' was documented, so restore it
ripley authored
238 check check-devel check-all check-recommended:
ba6787e branch update
pd authored
239 @(cd tests && $(MAKE) $@)
bbbd710 Improve/simplify targets for checking.
hornik authored
240
17300d7 Makefile support for bundling recommended packages
pd authored
241 reset-recommended:
93d29fc make fullcheck
pd authored
242 @(cd src/library/Recommended && $(MAKE) clean)
60ee3fa changes needed for the new RAqua and Rframework
iacus authored
243
660b7fd modified Rframework target
iacus authored
244 TAGS:
Something went wrong with that request. Please try again.