ropensci / geojsonio

Convert many data formats to & from GeoJSON & TopoJSON
https://docs.ropensci.org/geojsonio
Other
151 stars 59 forks source link

Cannot install in Manjaro #143

Closed jethroppaPH closed 3 years ago

jethroppaPH commented 5 years ago

I am trying to install the package in Manjaro XFCE x86_64. I always received the following error:

...
** testing if installed package can be loaded
sh: line 1: 14143 Trace/breakpoint trap   (core dumped) '/usr/lib64/R/bin/R' --no-save --slave 2>&1 < '/tmp/RtmpOFVQUU/file373c6d4c704d'

#
# Fatal error in ../src/platform-linux.cc, line 776
# CHECK_EQ(0, result) failed
#   Expected: 0
#   Found: 22
#

ERROR: loading failed
...

I already have the Arch packages gdal, geos, and proj, as well as udunits.

Session Info ```r R version 3.5.2 (2018-12-20) Platform: x86_64-pc-linux-gnu (64-bit) Running under: Manjaro Linux Matrix products: default BLAS: /usr/lib/libopenblasp-r0.3.4.so LAPACK: /usr/lib/liblapack.so.3.8.0 locale: [1] LC_CTYPE=en_PH.UTF-8 LC_NUMERIC=C LC_TIME=en_PH.UTF-8 [4] LC_COLLATE=en_PH.UTF-8 LC_MONETARY=en_PH.UTF-8 LC_MESSAGES=en_PH.UTF-8 [7] LC_PAPER=en_PH.UTF-8 LC_NAME=C LC_ADDRESS=C [10] LC_TELEPHONE=C LC_MEASUREMENT=en_PH.UTF-8 LC_IDENTIFICATION=C attached base packages: [1] stats graphics grDevices utils datasets methods base loaded via a namespace (and not attached): [1] compiler_3.5.2 tools_3.5.2 yaml_2.2.0 ```
ateucher commented 5 years ago

Hi @jethroppaPH. This looks an error installing one of the dependencies, as geojsonio doesn’t contain any C or C++ that needs compiling. It’s possible you are missing system libraries for one of these dependencies. Can you paste a more complete error message?

jethroppaPH commented 5 years ago

@ateucher

I tried again today, this is the error:

> install.packages("geojsonio")
Installing package into ‘/home/jethroemmanuel/R/x86_64-pc-linux-gnu-library/3.5’
(as ‘lib’ is unspecified)
trying URL 'https://cran.rstudio.com/src/contrib/geojsonio_0.6.0.tar.gz'
Content type 'application/x-gzip' length 2913377 bytes (2.8 MB)
==================================================
downloaded 2.8 MB

* installing *source* package ‘geojsonio’ ...
** package ‘geojsonio’ successfully unpacked and MD5 sums checked
** R
** data
*** moving datasets to lazyload DB
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded
sh: line 1:  2834 Trace/breakpoint trap   (core dumped) '/usr/lib64/R/bin/R' --no-save --slave 2>&1 < '/tmp/RtmpTb8VHP/fileb0f6a5c9019'

#
# Fatal error in ../src/platform-linux.cc, line 776
# CHECK_EQ(0, result) failed
#   Expected: 0
#   Found: 22
#

ERROR: loading failed
* removing ‘/home/jethroemmanuel/R/x86_64-pc-linux-gnu-library/3.5/geojsonio’
Warning in install.packages :
  installation of package ‘geojsonio’ had non-zero exit status

The downloaded source packages are in
    ‘/tmp/RtmpNdb4JZ/downloaded_packages’

This is the versions of the system packages:

geos 3.7.1-1
gdal 2.3.2-6
proj 5.2.0-1
udunits 2.2.26-1

What other system packages do I need to install?

ateucher commented 5 years ago

Hmmm I’m not sure. It does look it’s happening when installing geojsonio. @sckott any ideas?

sckott commented 5 years ago

not sure. spun up an archlinux instance on ec2 and have been fiddling, but not familiar enough with the os to make much progress.

So you get no other errors about any system libraries not being available or not installed?

jethroppaPH commented 5 years ago

Sorry for the late reply.

@sckott

I haven't had any error installing system packages. Prior to installing the said packages, I installed v8-3.14 which is needed for the R package V8; jq for the R package jqr. I also installed the system package qgis. Maybe these can help?

sckott commented 5 years ago

trying to replicate on an archlinux image:

sudo pacman -Sy r
# had to symlink libreadline, wasn't allowing R to work
sudo ln -s /usr/lib/libreadline.so.7 /usr/lib/libreadline.so.8 
pacman -S gdal proj geos # these installed fine

but udunits seems to be unavailable. how did you install it?

ateucher commented 5 years ago

I also think this looks looks a lot like this V8 issue. Can you try running:

context <- V8::v8()

and see what happens?

jethroppaPH commented 5 years ago

@sckott

I installed udunits using yay -S udunits. It is from AUR.

Should I also run that symlink?

@ateucher

When I ran that code, my R session aborted.

Maybe it is the system package v8-3.14 causing the problem?

sckott commented 5 years ago

I think just the archlinux image I was on needed it. don't know if yours would. I imagine not if you already had R working.

Maybe this comment helps? https://github.com/jeroen/V8/issues/32#issuecomment-370259886

sckott commented 5 years ago

@ateucher there is the issue of why we need V8. took a look. we are removing lint() in the next version, which uses v8, so that's promising. But there are two other fxns geo2topo() and map_leaf() that use v8. perhaps we could move V8 to Suggests and conditionally use v8, but not sure that would work since we have to create v8 context in .onLoad on package load. Of the two fxns that use v8, once could argue to factor map_leaf out to a new pkg since it's sort of tangential to the main purpose of the pkg, but geo2topo definitely fits topically in the pkg. Just saw https://github.com/pedro-vicente/lib_topojson so may be able to use that instead of v8, haven't tried yet

ateucher commented 5 years ago

I think it’s a great idea to move V8 to suggests and conditionally load it. v8 contexts are cheap to create and throw away so there’s no problem just doing it inside the function.

sckott commented 5 years ago

ah, thought we had to have those in .onLoad, just hadn't tried it any other way. good to know

sckott commented 5 years ago

meh, the lib_topojson won't work.

sckott commented 5 years ago

trying to use mapnik c++ lib https://github.com/ropensci/geojsonio/tree/mapnik which has a topojson tool. not fixed linking to it yet though ... 😢

jethroppaPH commented 5 years ago

I received a reply from pat-s in his article here, and he said that it could be related to the v8-3.14 package. He also said "In the end, the simplest solution would be if the v8 R package would not rely on the old v8-3.14 package."

sckott commented 5 years ago

thoughts @jeroen from what I remember I don't think you can control this?

kevinkvothe commented 5 years ago

I am having the exact same error on Manjaro 18 kde. I thought this https://github.com/ropensci/geojsonio/issues/112 would help, but sadly it says that v8-3.14 and v8-3.14-bin are in conflict so I haven't found a way around. Any ideas?

jeroen commented 5 years ago

You can install the latest version of the V8 package with any recent version of libv8. Does your linux distro have any other v8 versions?

kevinkvothe commented 5 years ago

Yep, 7.2.502 is available on AUR, but i thought the point was to use the 3.14 version because R needs it particularly.

jeroen commented 5 years ago

I released a new version of the R package yesterday that now works with libv8 version 6 or 7

kevinkvothe commented 5 years ago

I'm trying to install it with the 7th version of V8, but a new error came out on R: "/lib/libc++.so: file too short", i'll try to solve it and report back when possible.

dickoa commented 5 years ago

@kevinkvothe libc++ is available under /usr/lib/v8 (no need to build libc++m from AUR I think) you can add this to your LD path before compiling it. It helps a little bit but I still have this error:

** R
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded
sh: line 1:  4857 Illegal instruction     (core dumped) '/usr/lib64/R/bin/R' --no-save --slave 2>&1 < '/tmp/Rtmp9nr6xl/file127c71f70da4'

#
# Fatal error in , line 0
# Failed to deserialize the V8 snapshot blob. This can mean that the snapshot blob file is corrupted or missing.
#
#
#
#FailureMessage Object: 0x7ffc8fec3990
==== C stack trace ===============================

    /usr/lib/libv8_libbase.so(v8::base::debug::StackTrace::StackTrace()+0x16) [0x7f4128184046]
    /usr/lib/libv8_libplatform.so(+0x8fab) [0x7f4128196fab]
    /usr/lib/libv8_libbase.so(V8_Fatal(char const*, int, char const*, ...)+0x170) [0x7f412817b430]
    /usr/lib/libv8.so(+0x1b4cc9) [0x7f4126f6fcc9]
    /usr/lib/libv8.so(v8::Isolate::New(v8::Isolate::CreateParams const&)+0x1d) [0x7f4126f6fced]
    /usr/lib/R/library/V8/libs/V8.so(+0x10618) [0x7f412855b618]
    /usr/lib64/R/lib/libR.so(+0x6c02b) [0x7f412fe3e02b]
    /usr/lib64/R/lib/libR.so(+0x6c320) [0x7f412fe3e320]
    /usr/lib64/R/lib/libR.so(+0x127a07) [0x7f412fef9a07]
    /usr/lib64/R/lib/libR.so(Rf_eval+0x190) [0x7f412ff09cb0]
    /usr/lib64/R/lib/libR.so(+0x139970) [0x7f412ff0b970]
    /usr/lib64/R/lib/libR.so(+0x12e792) [0x7f412ff00792]
    /usr/lib64/R/lib/libR.so(Rf_eval+0x190) [0x7f412ff09cb0]
    /usr/lib64/R/lib/libR.so(+0x139970) [0x7f412ff0b970]
    /usr/lib64/R/lib/libR.so(+0x12e792) [0x7f412ff00792]
    /usr/lib64/R/lib/libR.so(Rf_eval+0x190) [0x7f412ff09cb0]
    /usr/lib64/R/lib/libR.so(+0x139970) [0x7f412ff0b970]
    /usr/lib64/R/lib/libR.so(+0x12e792) [0x7f412ff00792]
    /usr/lib64/R/lib/libR.so(Rf_eval+0x190) [0x7f412ff09cb0]
    /usr/lib64/R/lib/libR.so(+0x13862f) [0x7f412ff0a62f]
    /usr/lib64/R/lib/libR.so(+0x138b38) [0x7f412ff0ab38]
    /usr/lib64/R/lib/libR.so(+0x12d13d) [0x7f412feff13d]
    /usr/lib64/R/lib/libR.so(Rf_eval+0x190) [0x7f412ff09cb0]
    /usr/lib64/R/lib/libR.so(+0x13862f) [0x7f412ff0a62f]
    /usr/lib64/R/lib/libR.so(+0x138b38) [0x7f412ff0ab38]
    /usr/lib64/R/lib/libR.so(+0x12d13d) [0x7f412feff13d]
    /usr/lib64/R/lib/libR.so(Rf_eval+0x190) [0x7f412ff09cb0]
    /usr/lib64/R/lib/libR.so(+0x13862f) [0x7f412ff0a62f]
    /usr/lib64/R/lib/libR.so(+0x138b38) [0x7f412ff0ab38]
    /usr/lib64/R/lib/libR.so(+0x12d13d) [0x7f412feff13d]
    /usr/lib64/R/lib/libR.so(Rf_eval+0x190) [0x7f412ff09cb0]
    /usr/lib64/R/lib/libR.so(+0x13862f) [0x7f412ff0a62f]
    /usr/lib64/R/lib/libR.so(+0x138b38) [0x7f412ff0ab38]
    /usr/lib64/R/lib/libR.so(+0x12d13d) [0x7f412feff13d]
    /usr/lib64/R/lib/libR.so(Rf_eval+0x190) [0x7f412ff09cb0]
    /usr/lib64/R/lib/libR.so(+0x139970) [0x7f412ff0b970]
    /usr/lib64/R/lib/libR.so(+0x12e792) [0x7f412ff00792]
    /usr/lib64/R/lib/libR.so(Rf_eval+0x190) [0x7f412ff09cb0]
    /usr/lib64/R/lib/libR.so(+0x139970) [0x7f412ff0b970]
    /usr/lib64/R/lib/libR.so(+0x12e792) [0x7f412ff00792]
    /usr/lib64/R/lib/libR.so(Rf_eval+0x190) [0x7f412ff09cb0]
    /usr/lib64/R/lib/libR.so(+0x139970) [0x7f412ff0b970]
    /usr/lib64/R/lib/libR.so(+0x12e792) [0x7f412ff00792]
    /usr/lib64/R/lib/libR.so(Rf_eval+0x190) [0x7f412ff09cb0]
    /usr/lib64/R/lib/libR.so(+0x139970) [0x7f412ff0b970]
    /usr/lib64/R/lib/libR.so(+0x12e792) [0x7f412ff00792]
    /usr/lib64/R/lib/libR.so(Rf_eval+0x190) [0x7f412ff09cb0]
    /usr/lib64/R/lib/libR.so(+0x139970) [0x7f412ff0b970]
    /usr/lib64/R/lib/libR.so(+0x12e792) [0x7f412ff00792]
    /usr/lib64/R/lib/libR.so(Rf_eval+0x190) [0x7f412ff09cb0]
    /usr/lib64/R/lib/libR.so(+0x13862f) [0x7f412ff0a62f]
    /usr/lib64/R/lib/libR.so(+0x138b38) [0x7f412ff0ab38]
    /usr/lib64/R/lib/libR.so(+0x12d13d) [0x7f412feff13d]
    /usr/lib64/R/lib/libR.so(Rf_eval+0x190) [0x7f412ff09cb0]
    /usr/lib64/R/lib/libR.so(+0x13862f) [0x7f412ff0a62f]
    /usr/lib64/R/lib/libR.so(+0x138b38) [0x7f412ff0ab38]
    /usr/lib64/R/lib/libR.so(+0x12d13d) [0x7f412feff13d]
    /usr/lib64/R/lib/libR.so(Rf_eval+0x190) [0x7f412ff09cb0]
    /usr/lib64/R/lib/libR.so(+0x139970) [0x7f412ff0b970]
    /usr/lib64/R/lib/libR.so(+0x12e792) [0x7f412ff00792]
    /usr/lib64/R/lib/libR.so(Rf_eval+0x190) [0x7f412ff09cb0]
    /usr/lib64/R/lib/libR.so(+0x139970) [0x7f412ff0b970]

 *** caught illegal operation ***
address 0x7f41281745ff, cause 'illegal operand'

Traceback:
 1: dyn.load(file, DLLpath = DLLpath, ...)
 2: library.dynam(lib, package, package.lib)
 3: loadNamespace(package, lib.loc)
 4: doTryCatch(return(expr), name, parentenv, handler)
 5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
 6: tryCatchList(expr, classes, parentenv, handlers)
 7: tryCatch({    attr(package, "LibPath") <- which.lib.loc    ns <- loadNamespace(package, lib.loc)    env <- attachNamespace(ns, pos = pos, deps)}, error = function(e) {    P <- if (!is.null(cc <- conditionCall(e)))         paste(" in", deparse(cc)[1L])    else ""    msg <- gettextf("package or namespace load failed for %s%s:\n %s",         sQuote(package), P, conditionMessage(e))    if (logical.return)         message(paste("Error:", msg), domain = NA)    else stop(msg, call. = FALSE, domain = NA)})
 8: library(pkg_name, lib.loc = lib, character.only = TRUE, logical.return = TRUE)
 9: withCallingHandlers(expr, packageStartupMessage = function(c) invokeRestart("muffleMessage"))
10: suppressPackageStartupMessages(library(pkg_name, lib.loc = lib,     character.only = TRUE, logical.return = TRUE))
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: tryCatch(expr, error = function(e) {    call <- conditionCall(e)    if (!is.null(call)) {        if (identical(call[[1L]], quote(doTryCatch)))             call <- sys.call(-4L)        dcall <- deparse(call)[1L]        prefix <- paste("Error in", dcall, ": ")        LONG <- 75L        sm <- strsplit(conditionMessage(e), "\n")[[1L]]        w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w")        if (is.na(w))             w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L],                 type = "b")        if (w > LONG)             prefix <- paste0(prefix, "\n  ")    }    else prefix <- "Error : "    msg <- paste0(prefix, conditionMessage(e), "\n")    .Internal(seterrmessage(msg[1L]))    if (!silent && isTRUE(getOption("show.error.messages"))) {        cat(msg, file = outFile)        .Internal(printDeferredWarnings())    }    invisible(structure(msg, class = "try-error", condition = e))})
15: try(suppressPackageStartupMessages(library(pkg_name, lib.loc = lib,     character.only = TRUE, logical.return = TRUE)))
16: tools:::.test_load_package("V8", "/usr/lib/R/library")
An irrecoverable exception occurred. R is aborting now ...
ERROR: loading failed
* removing ‘/usr/lib/R/library/V8’
* restoring previous ‘/usr/lib/R/library/V8’
Error in i.p(...) : 
  (converted from warning) installation of package ‘/tmp/RtmpitCzHE/file11a63f452db4/V8_2.0.9000.tar.gz’ had non-zero exit status
kevinkvothe commented 5 years ago

Right. Same thing happened to me after i added /usr/lib/v8 to my LD path.

jeroen commented 5 years ago

The better solution would be to convince the arch linux maintainer of the nodejs package to build this as a shared library so that we can link to this one.

dickoa commented 5 years ago

@jeroen I would love that too. In the meantime I found a way to have v8 7.2 (AUR package) to work with new version of the R package V8. I realized that the error I got was due to the fact that v8 need external data for blob (snapshot_blob.bin and native_blob.bin) and couldn't find them. I rebuilt V8 not to use external data. You just need to modify the option on the PKGBUILD and this

    v8_use_snapshot=false
    v8_use_external_startup_data=false

Doing this the test fail for one case, I remove check in PKGBUILD for the package to build, @kevinkvothe if you have an idea on how to avoid this error please let me know but at least we can build it and play with this new version. Thanks @jeroen for this package again.

This is the complete PKGBUILD, I modified

# Maintainer: Marco Pompili <aur (at) mg.odd.red>
# Contributor: Anatol Pomozov <anatol.pomozov@gmail.com>
# Contributor: Bartłomiej Piotrowski <nospam@bpiotrowski.pl>
# Contributor: Kaiting Chen <kaitocracy@gmail.com>
# Contributor: tocer <tocer.deng@gmail.com>
# Contributor: David Flemström <david.flemstrom@gmail.com>

pkgname=v8
pkgver=7.2.502.25
pkgrel=1
pkgdesc="Fast and modern Javascript engine used in Google Chrome."
arch=('i686' 'x86_64')
url="https://v8.dev"
license=('BSD')
depends=('readline' 'icu')
makedepends=('clang' 'clang-tools-extra' 'python2' 'python2-colorama' 'python2-pylint' 'python2-lazy-object-proxy' 'python2-singledispatch' 'python2-wrapt' 'ninja' 'git' 'wget')
conflicts=('v8-3.14' 'v8-3.15' 'v8-3.20' 'v8-static-gyp' 'v8-static-gyp-5.4')
source=("depot_tools::git+https://chromium.googlesource.com/chromium/tools/depot_tools.git"
        "v8.pc"
        "v8_libbase.pc"
        "v8_libplatform.pc"
    "d8")
sha256sums=('SKIP'
            '3616bcfb15af7cd5a39bc0f223b2a52f15883a4bc8cfcfb291837c7421363d75'
            'efb37bd706e6535abfa20c77bb16597253391619dae275627312d00ee7332fa3'
            'ae23d543f655b4d8449f98828d0aff6858a777429b9ebdd2e23541f89645d4eb'
            '6abb07ab1cf593067d19028f385bd7ee52196fc644e315c388f08294d82ceff0')

#
# Custom configuration for V8
#

# clang_base_path: Set clang path when not using the clang bundled with V8.
V8_CLANG_PATH="/usr/"

# is_clang: Set to true when compiling with the Clang compiler. Typically this
# is used to configure warnings.
V8_IS_CLANG=false

# is_component_build: Component build. Setting to true compiles targets declared
# as "components" as shared libraries loaded dynamically.
# This speeds up development time.
# When false, components will be linked statically.
V8_COMPONENT_BUILD=true

# is_debug: Enabling official builds (V8_OFFICIAL_BUILD) automatically sets is_debug to false.
V8_DEBUG=false

# is_official_build: Set to enable the official build level of optimization.
# This has nothing to do with branding, but enables an additional level of
# optimization above release (!is_debug). This might be better expressed
# as a tri-state (debug, release, official) but for historical reasons there
# are two separate flags.
V8_OFFICIAL_BUILD=false

# v8_enable_i18n_support: Enable ECMAScript Internationalization API.
# Enabling this feature will add a dependency on the ICU library.
V8_I18N_SUPPORT=true

# v8_use_external_startup_data: Use external files for startup data blobs:
# the JS builtins sources and the start snapshot.
V8_USE_EXTERNAL_STARTUP_DATA=false

# Use sysroot
V8_USE_SYSROOT=false

# treat_warnings_as_errors: Default to warnings as errors for default workflow,
# where we catch warnings with known toolchains. Allow overriding this e.g.
# for Chromium builds on Linux that could use a different version of the compiler.
# With GCC, warnings in no-Chromium code are always not treated as errors.
V8_WARNINGS_AS_ERRORS=false

case "$CARCH" in
  x86_64) V8_ARCH="x64" ;;
  i686) V8_ARCH="ia32" ;;
esac

OUTFLD=out.gn/Release

prepare() {
  # Switching to python2 system environment
  mkdir -p bin
  ln -sf /usr/bin/python2 ./bin/python
  ln -sf /usr/bin/python2-config ./bin/python-config
  msg2 "Using: `which python`"

  export PATH=${srcdir}/bin:`pwd`/depot_tools:"$PATH"
  export GYP_GENERATORS=ninja

  if [ ! -d "v8" ]; then
    msg2 "Fetching V8 code"
    yes | fetch v8
  fi

  cd v8

  msg2 "Reset repository"
  git reset --hard

  if [ -f third_party/icu/BUILD.gn.orig ]
  then
      msg2 "Restoring bundled ICU build files for syncing"
      ./build/linux/unbundle/replace_gn_files.py --undo --system-libraries icu
  fi

  msg2 "Syncing, this can take a while..."
  gclient sync --revision ${pkgver}

  msg2 "Using system libraries for ICU"
  ./build/linux/unbundle/replace_gn_files.py

  sed "s/@VERSION@/${pkgver}/g" -i "${srcdir}/v8.pc"
  sed "s/@VERSION@/${pkgver}/g" -i "${srcdir}/v8_libbase.pc"
  sed "s/@VERSION@/${pkgver}/g" -i "${srcdir}/v8_libplatform.pc"

  msg2 "Running GN..."
  ../depot_tools/gn gen $OUTFLD \
    -vv --fail-on-unused-args \
    --args="clang_base_path=\"$V8_CLANG_PATH\"
    is_clang=$V8_IS_CLANG
    is_component_build=$V8_COMPONENT_BUILD
    is_debug=$V8_DEBUG
    is_official_build=$V8_OFFICIAL_BUILD
    treat_warnings_as_errors=$V8_WARNINGS_AS_ERRORS
    v8_enable_i18n_support=$V8_I18N_SUPPORT
    v8_use_snapshot=false
    v8_use_external_startup_data=false
    use_sysroot=$V8_USE_SYSROOT"
}

build() {
  cd v8

  # Fixes bug in generate_shim_headers.py that fails to create these dirs
  msg2 "Adding icu missing folders"
  mkdir -p "$OUTFLD/gen/shim_headers/icuuc_shim/third_party/icu/source/common/unicode/"
  mkdir -p "$OUTFLD/gen/shim_headers/icui18n_shim/third_party/icu/source/i18n/unicode/"

  msg2 "Building, this will take a while..."
  ninja -C $OUTFLD
}

# check() {
#   cd v8
#   msg2 "Using `which python`"
#   msg2 "Testing, this will also take a while..."
#   tools/run-tests.py --no-presubmit \
#                      --outdir=out.gn \
#                      --buildbot \
#                      --arch=$V8_ARCH \
#                      --mode=Release
# }

package() {
  cd v8

  install -d ${pkgdir}/usr/lib/v8

  install -Dm755 $OUTFLD/cctest ${pkgdir}/usr/lib/v8/cctest
  install -Dm755 $OUTFLD/d8 ${pkgdir}/usr/lib/v8/d8

  install -Dm755 $OUTFLD/libc++.so ${pkgdir}/usr/lib/v8/libc++.so

  if [ $V8_I18N_SUPPORT == "true" ]
  then
    install -Dm755 $OUTFLD/libicui18n.so ${pkgdir}/usr/lib/v8/libicui18n.so
    install -Dm755 $OUTFLD/libicuuc.so ${pkgdir}/usr/lib/v8/libicuuc.so
  fi

  install -Dm755 $OUTFLD/libv8_for_testing.so ${pkgdir}/usr/lib/libv8_for_testing.so
  install -Dm755 $OUTFLD/libv8_libbase.so ${pkgdir}/usr/lib/libv8_libbase.so
  install -Dm755 $OUTFLD/libv8_libplatform.so ${pkgdir}/usr/lib/libv8_libplatform.so
  install -Dm755 $OUTFLD/libv8.so ${pkgdir}/usr/lib/libv8.so

  #install -Dm755 $OUTFLD/natives_blob.bin ${pkgdir}/usr/lib/v8/natives_blob.bin
  #install -Dm755 $OUTFLD/snapshot_blob.bin ${pkgdir}/usr/lib/v8/snapshot_blob.bin

  install -Dm755 ${srcdir}/d8 ${pkgdir}/usr/bin/d8

  # V8 has several header files and ideally if it had its own folder in /usr/include
  # But doing it here will break all users. Ideally if they use provided pkgconfig file.
  install -d ${pkgdir}/usr/include
  install -Dm644 include/*.h ${pkgdir}/usr/include

  install -d ${pkgdir}/usr/include/libplatform
  install -Dm644 include/libplatform/*.h ${pkgdir}/usr/include/libplatform

  install -d ${pkgdir}/usr/lib/pkgconfig
  install -m644 $srcdir/v8.pc ${pkgdir}/usr/lib/pkgconfig
  install -m644 $srcdir/v8_libbase.pc ${pkgdir}/usr/lib/pkgconfig
  install -m644 $srcdir/v8_libplatform.pc ${pkgdir}/usr/lib/pkgconfig

  install -d ${pkgdir}/usr/share/licenses/v8
  install -m644 LICENSE* ${pkgdir}/usr/share/licenses/v8
}
jeroen commented 5 years ago

@dickoa could you try to suggest this fix to the arch/manjaro v8 maintainer?

dickoa commented 5 years ago

@jeroen Definitely. I'm still trying to see understand why I still have 1 error (out of 15000) in the test. It does make PKGBUILD check fail. I will propose this new PKGBUILD as soon as I can figure out why and fix it.

sckott commented 4 years ago

@dickoa any update on this?

dickoa commented 4 years ago

Hi @sckott,

I used to maintain a local PKGBUILD but I'm now using Marvin build (https://github.com/JanMarvin/v8-R) and it works perfectly. It's not yet on AUR but you can clone it on Github and build the V8 library. Thanks

sckott commented 4 years ago

thanks @dickoa

@jethroppaPH do you think ☝️ would work for you?

dickoa commented 4 years ago

Marvin packaged his build and it's now available in AUR.

https://aur.archlinux.org/packages/v8-r/

@jethroppaPH hope it works now

sckott commented 4 years ago

thanks for that @dickoa

sckott commented 3 years ago

considering this sorted out

github-actions[bot] commented 1 year ago

This issue has been automatically locked. If you believe you have found a related problem, please file a new issue (with a reprex: https://reprex.tidyverse.org) and link to this issue.