artoolkitx / jsartoolkit5

Javascript ARToolKit v5.x

Home Page:https://artoolkitx.github.io/jsartoolkit5/examples/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Docker build failing

Adolar13 opened this issue · comments

Hey,
currently the docker build fails as it can't get libjpeg from https://dl.bintray.com/homebrew/mirror/jpeg-9c.tar.gz

[...]
system_libs:INFO: retrieving port: zlib from https://github.com/emscripten-ports/zlib/archive/version_1.zip
system_libs:INFO: unpacking port: zlib
cache:INFO: generating port: libz.a... (this will be cached in "/emsdk_portable/.data/cache/asmjs/libz.a" for subsequent builds)
cache:INFO:  - ok
system_libs:INFO: retrieving port: libjpeg from https://dl.bintray.com/homebrew/mirror/jpeg-9c.tar.gz
Traceback (most recent call last):
  File "/emsdk_portable/emscripten/tag-1.39.4/emcc.py", line 3704, in <module>
    sys.exit(run(sys.argv))
  File "/emsdk_portable/emscripten/tag-1.39.4/emcc.py", line 1960, in run
    compile_source_file(i, input_file)
  File "/emsdk_portable/emscripten/tag-1.39.4/emcc.py", line 1942, in compile_source_file
    cmd = get_clang_command([input_file]) + ['-c', '-o', output_file]
  File "/emsdk_portable/emscripten/tag-1.39.4/emcc.py", line 1913, in get_clang_command
    args = system_libs.process_args(args, shared.Settings)
  File "/emsdk_portable/emscripten/tag-1.39.4/tools/system_libs.py", line 1762, in process_args
    args = port.process_args(Ports, args, settings, shared)
  File "/emsdk_portable/emscripten/tag-1.39.4/tools/ports/libjpeg.py", line 53, in process_args
    get(ports, settings, shared)
  File "/emsdk_portable/emscripten/tag-1.39.4/tools/ports/libjpeg.py", line 18, in get
    ports.fetch_project('libjpeg', 'https://dl.bintray.com/homebrew/mirror/jpeg-9c.tar.gz', 'jpeg-9c', sha512hash=HASH)
  File "/emsdk_portable/emscripten/tag-1.39.4/tools/system_libs.py", line 1681, in fetch_project
    retrieve()
  File "/emsdk_portable/emscripten/tag-1.39.4/tools/system_libs.py", line 1629, in retrieve
    f = urlopen(url)
  File "/usr/lib/python2.7/urllib2.py", line 154, in urlopen
    return opener.open(url, data, timeout)
  File "/usr/lib/python2.7/urllib2.py", line 429, in open
    response = self._open(req, data)
  File "/usr/lib/python2.7/urllib2.py", line 447, in _open
    '_open', req)
  File "/usr/lib/python2.7/urllib2.py", line 407, in _call_chain
    result = func(*args)
  File "/usr/lib/python2.7/urllib2.py", line 1241, in https_open
    context=self._context)
  File "/usr/lib/python2.7/urllib2.py", line 1198, in do_open
    raise URLError(err)
urllib2.URLError: <urlopen error [Errno 0] Error>

exec error: 1
Built at Wed Apr 6 18:04:21 UTC 2022

It depends which docker image are you using but i think emscripten/trzeci is outdated because use fastcomp. You can use for sure a newer version of emsdk, version 2.0.20 will work you can read about this in this isssue webarkit#14 and PR webarkit#15 If you want to try, you need to modify the tools/makem.js script as in that PR. In regards of the Docker image: emscripten/trzeci is deprecated and you should use emscripten/emsdk instead:

//try with emsdk 2.0.20 first
docker run -dit --name emscripten -v $(pwd):/src emscripten/emsdk:2.0.20 bash
docker exec emscripten npm run build 

You can follow this guide https://github.com/webarkit/jsartoolkitNFT/wiki#recommended-build-using-docker not for jsartoolkit5 but almost the same.