Running examples in ‘MOEADr-Ex.R’ failed
The error most likely occurred in:

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: moead
> ### Title: MOEA/D
> ### Aliases: moead
> 
> ### ** Examples
> 
> ## Prepare a test problem composed of minimization of the (shifted)
> ## sphere and Rastrigin functions
> sphere     <- function(x){sum((x + seq_along(x) * 0.1) ^ 2)}
> rastringin <- function(x){
+                 x.shift <- x - seq_along(x) * 0.1
+                 sum((x.shift) ^ 2 - 10 * cos(2 * pi * x.shift) + 10)}
> problem.sr <- function(X){
+                 t(apply(X, MARGIN = 1,
+                 FUN = function(X){c(sphere(X), rastringin(X))}))}
> 
> 
> ## Set the input parameters for the moead() routine
> ## This reproduces the Original MOEA/D of Zhang and Li (2007)
> ## (with a few changes in the computational budget, to make it run faster)
> problem   <- list(name       = "problem.sr",
+                   xmin       = rep(-1, 30),
+                   xmax       = rep(1, 30),
+                   m          = 2)
> decomp    <- list(name       = "SLD", H = 49) # <-- H = 99 in the original
> neighbors <- list(name       = "lambda",
+                   T          = 20,
+                   delta.p    = 1)
> aggfun    <- list(name       = "wt")
> variation <- list(list(name  = "sbx",
+                        etax  = 20, pc = 1),
+                   list(name  = "polymut",
+                        etam  = 20, pm = 0.1),
+                   list(name  = "truncate"))
> update    <- list(name       = "standard", UseArchive = FALSE)
> scaling   <- list(name       = "none")
> constraint<- list(name       = "none")
> stopcrit  <- list(list(name  = "maxiter",
+                     maxiter  = 50))      # <-- maxiter = 200 in the original
> showpars  <- list(show.iters = "dots",
+                   showevery  = 10)
> seed      <- 42
> 
> ## Run MOEA/D
> out1 <- moead(preset = NULL,
+               problem, decomp, aggfun, neighbors, variation, update,
+               constraint, scaling, stopcrit, showpars, seed)
Error in dyn.load(file, DLLpath = DLLpath, ...) : 
  unable to load shared object '/home/hornik/tmp/R.check/r-patched-gcc/Work/build/Packages/FNN/libs/FNN.so':
  /home/hornik/tmp/R.check/r-patched-gcc/Work/build/Packages/FNN/libs/FNN.so: failed to map segment from shared object
Calls: moead ... tryCatch -> tryCatchList -> tryCatchOne -> <Anonymous>
Execution halted