screenshotbot / screenshotbot-oss

A Screenshot Testing service to tie with your existing Android, iOS and Web screenshot tests
https://screenshotbot.io
Mozilla Public License 2.0
238 stars 13 forks source link

/usr/lib/jvm/java-11-openjdk-amd64 may not exists in some Linux dist #7

Closed liweijian closed 3 years ago

liweijian commented 3 years ago

As the code from:

https://github.com/screenshotbot/screenshotbot-oss/blob/cbd34360f820e17ec7a247896273225eb4f76091/src/jvm/jvm.lisp#L40

(defun libjvm.so ()
  "/usr/lib/jvm/java-11-openjdk-amd64/lib/server/libjvm.so")

Some how I could make it works in CentOS by changing it to(Simply removed the -amd64) :

(defun libjvm.so ()
  "/usr/lib/jvm/java-11-openjdk/lib/server/libjvm.so")

I believe that should be some issue in other dists, just wondering if maybe we could put the libjvm.so location in the config file?

tdrhq commented 3 years ago

Yep, I'll make that configurable. Any reason you chose not to use docker?

tdrhq commented 3 years ago

Fixed here: https://github.com/screenshotbot/screenshotbot-oss/commit/37760cc84550f870694d2f389abb11a37a238a2a

Actually, let me also use the non -amd64 path as you suggested as a separate "guess" so you don't have to worry about the libjvm argument.

tdrhq commented 3 years ago

Automatic guessing of location: https://github.com/screenshotbot/screenshotbot-oss/commit/087df2e74a49096ce51d1bc5fc7909ed6a34cc34, so you shouldn't have to pass --libjvm at least on CentOS.

Closing this task, let me know if you still have issues!

liweijian commented 3 years ago

Cool! It works well right now. It's kind of not that easy to use docker with other system in my daily work:p