Skip to content

Commit

Permalink
drop C++11 as a system requirement
Browse files Browse the repository at this point in the history
  • Loading branch information
rnuske committed Jun 13, 2024
1 parent 3dd03aa commit cc76a0f
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 24 deletions.
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: apcf
Title: Adapted Pair Correlation Function
Version: 0.3.0
Version: 0.3.0.900
Authors@R:
person(given="Robert", family="Nuske", role=c("aut", "cre"),
email="[email protected]",
Expand All @@ -20,7 +20,7 @@ Depends: R (>= 3.3.0)
Imports: Rcpp (>= 0.12), wk (>= 0.6.0)
Suggests: knitr, rmarkdown
LinkingTo: Rcpp
SystemRequirements: C++11, GEOS (>= 3.4.0)
SystemRequirements: GEOS (>= 3.4.0)
VignetteBuilder: knitr
LazyData: true
Roxygen: list(markdown=TRUE)
Expand Down
3 changes: 3 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# apcf 0.3.1
* dropped C++11 as a system requirement

# apcf 0.3.0
* switched to R's random number generator in C++ code
* fixed CRANs M1mac vsnprintf() warning
Expand Down
12 changes: 2 additions & 10 deletions configure
Original file line number Diff line number Diff line change
Expand Up @@ -2005,25 +2005,17 @@ RVER_MINOR=`echo ${RVER} | cut -f2 -d"."`
RVER_PATCH=`echo ${RVER} | cut -f3 -d"."`
if test $RVER_MAJOR = "development"; then
CXX11=`"${RBIN}" CMD config CXX11`
CXX11STD=`"${RBIN}" CMD config CXX11STD`
CXX=`"${RBIN}" CMD config CXX`
else
if test $RVER_MAJOR -lt 3 -o $RVER_MAJOR -eq 3 -a $RVER_MINOR -lt 3; then
as_fn_error $? "apcf is not compatible with R versions before 3.3.0" "$LINENO" 5
else
if test $RVER_MAJOR -eq 3 -a $RVER_MINOR -eq 3; then
CXX11=`"${RBIN}" CMD config CXX1X`
CXX11STD=`"${RBIN}" CMD config CXX1XSTD`
else
CXX11=`"${RBIN}" CMD config CXX11`
CXX11STD=`"${RBIN}" CMD config CXX11STD`
fi
CXX=`"${RBIN}" CMD config CXX`
fi
fi
# pick all flags for testing from R
: ${CC=`"${RBIN}" CMD config CC`}
: ${CXX=${CXX11} ${CXX11STD}}
: ${CFLAGS=`"${RBIN}" CMD config CFLAGS`}
: ${CPPFLAGS=`"${RBIN}" CMD config CPPFLAGS`}
: ${CXXFLAGS=`"${RBIN}" CMD config CXXFLAGS`}
Expand Down
12 changes: 2 additions & 10 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -24,25 +24,17 @@ RVER_MINOR=`echo ${RVER} | cut -f2 -d"."`
RVER_PATCH=`echo ${RVER} | cut -f3 -d"."`

if test [$RVER_MAJOR = "development"]; then
CXX11=`"${RBIN}" CMD config CXX11`
CXX11STD=`"${RBIN}" CMD config CXX11STD`
CXX=`"${RBIN}" CMD config CXX`
else
if test [$RVER_MAJOR -lt 3] -o [$RVER_MAJOR -eq 3 -a $RVER_MINOR -lt 3]; then
AC_MSG_ERROR([apcf is not compatible with R versions before 3.3.0])
else
if test [$RVER_MAJOR -eq 3 -a $RVER_MINOR -eq 3]; then
CXX11=`"${RBIN}" CMD config CXX1X`
CXX11STD=`"${RBIN}" CMD config CXX1XSTD`
else
CXX11=`"${RBIN}" CMD config CXX11`
CXX11STD=`"${RBIN}" CMD config CXX11STD`
fi
CXX=`"${RBIN}" CMD config CXX`
fi
fi

# pick all flags for testing from R
: ${CC=`"${RBIN}" CMD config CC`}
: ${CXX=${CXX11} ${CXX11STD}}
: ${CFLAGS=`"${RBIN}" CMD config CFLAGS`}
: ${CPPFLAGS=`"${RBIN}" CMD config CPPFLAGS`}
: ${CXXFLAGS=`"${RBIN}" CMD config CXXFLAGS`}
Expand Down
2 changes: 1 addition & 1 deletion src/Makevars.in
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
PKG_CPPFLAGS=@PKG_CPPFLAGS@
PKG_LIBS=@PKG_LIBS@
CXX_STD=CXX11
CXX_STD=CXX
2 changes: 1 addition & 1 deletion src/Makevars.win
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ PKG_LIBS = \

all: clean winlibs

CXX_STD = CXX11
CXX_STD = CXX

winlibs:
mkdir -p ../inst
Expand Down

0 comments on commit cc76a0f

Please sign in to comment.