https://github.com/cran/Rcpp
Tip revision: fb578b36cc6520a0afadd424cbc3b4cf1e9c605f authored by Unknown author on 15 October 2010, 00:00:00 UTC
version 0.8.7
version 0.8.7
Tip revision: fb578b3
Makevars
# -*- mode: Makefile; tab-width: 8 -*-
#
# Makevars for Rcpp
#
# Copyright (C) 2008 - 2009 Dirk Eddelbuettel <edd@debian.org>
# Copyright (C) 2008 Simon Urbanek <simon.urbanek@r-project.org>
# Copyright (C) 2009 - 2010 Dirk Eddelbuettel and Romain Francois
## $(SHLIB) is the usual default target that is built automatically from all source
## files in this directory. userLibrary is an additional target for the second library
## that will be installed in ../inst/lib$(R_ARCH) and which users can link against.
## uncomment this to enable c++0x features (experimental)
## CLINK_CPPFLAGS=-std=c++0x
all: $(SHLIB) userLibrary
## we place it inside the inst/ directory so that it gets installed by the package
USERDIR = ../inst/lib
USERLIB = libRcpp$(DYLIB_EXT)
USERLIBST = libRcpp.a
PKG_CPPFLAGS += -I../inst/include/
userLibrary: $(USERLIB) $(USERLIBST)
-@if test ! -e $(USERDIR)$(R_ARCH); then mkdir -p $(USERDIR)$(R_ARCH); fi
cp $(USERLIB) $(USERDIR)$(R_ARCH)
cp $(USERLIBST) $(USERDIR)$(R_ARCH)
rm $(USERLIB) $(USERLIBST)
$(USERLIB): $(OBJECTS)
$(SHLIB_CXXLD) -o $(USERLIB) $^ $(SHLIB_CXXLDFLAGS) $(ALL_LIBS)
@if test -e "/usr/bin/install_name_tool"; then /usr/bin/install_name_tool -id $(R_PACKAGE_DIR)/lib$(R_ARCH)/$(USERLIB) $(USERLIB); fi
$(USERLIBST): $(OBJECTS)
$(AR) qc $(USERLIBST) $^
@if test -n "$(RANLIB)"; then $(RANLIB) $(USERLIBST); fi
.PHONY: all clean userLibrary
clean:
rm -f $(OBJECTS) $(SHLIB) $(USERLIB) $(USERLIBST)