google-deepmind / lab

A customisable 3D platform for agent-based AI research
Other
7.11k stars 1.37k forks source link

No such file:dmlab.lds Error! #106

Closed cumttang closed 6 years ago

cumttang commented 6 years ago

When I run the installation of deepmind lab on Ubuntu16.04, all dependencies have been installed, but there still some errors:

ERROR: /home/tommy/IMPALA/lab/BUILD:895:1: Linking of rule '//:libdmlab_headless_hw.so' failed (Exit 1) gcc: error: :dmlab.lds: No such file or directory Target //python/pip_package:build_pip_package failed to build Use --verbose_failures to see the command lines of failed build steps. INFO: Elapsed time: 125.820s, Critical Path: 72.23s INFO: 835 processes: 835 linux-sandbox. FAILED: Build did NOT complete successfully

How to fix it, please?

tkoeppe commented 6 years ago

Can you provide the Bazel invocation that caused this error?

cumttang commented 6 years ago

$ cd lab --Build the Python interface to DeepMind Lab lab$ bazel build -c opt //:deepmind_lab.so

When I ran the last bold line, finally, the error took place:(

rnunziata commented 6 years ago

I have same issue with Dockerfile from scalable_agent project

ERROR: /lab/BUILD:895:1: Linking of rule '//:libdmlab_headless_hw.so' failed (Exit 1)
gcc: error: :dmlab.lds: No such file or directory
Target //python/pip_package:build_pip_package failed to build
Use --verbose_failures to see the command lines of failed build steps.
INFO: Elapsed time: 78.655s, Critical Path: 34.17s
INFO: 835 processes: 835 processwrapper-sandbox.
FAILED: Build did NOT complete successfully
FAILED: Build did NOT complete successfully
The command '/bin/sh -c NP_INC="$(python -c 'import numpy as np; print(np.get_include())[5:]')" &&     git clone https://github.com/deepmind/lab.git &&     cd lab &&     sed -i 's@hdrs = glob(\[@hdrs = glob(["'"$NP_INC"'/\*\*/*.h", @g' python.BUILD &&     sed -i 's@includes = \[@includes = ["'"$NP_INC"'", @g' python.BUILD &&     bazel build -c opt python/pip_package:build_pip_package &&     pip install wheel &&     ./bazel-bin/python/pip_package/build_pip_package /tmp/dmlab_pkg &&     pip install /tmp/dmlab_pkg/DeepMind_Lab-1.0-py2-none-any.whl --force-reinstall' returned a non-zero code: 1
bboyseiok commented 6 years ago

I solved the issue while working with gh://deepmind/scalable_agent project. It's because of bazel 0.17.1 that was released 5 days ago. (2018-09-14)

The problem is that the following dockerfile code line,

RUN echo "deb [arch=amd64] http://storage.googleapis.com/bazel-apt stable jdk1.8"

gets the latest stable version which is bazel 0.17.1.

for the deepmind/scalable_agent issue #16 I changed the line

RUN echo "deb [arch=amd64] http://storage.googleapis.com/bazel-apt stable jdk1.8" | \
    tee /etc/apt/sources.list.d/bazel.list && \
    curl https://bazel.build/bazel-release.pub.gpg | \
    apt-key add - && \
    apt-get update && apt-get install -y bazel

to

RUN export BAZEL_VERSION=0.16.1 && \
    wget https://github.com/bazelbuild/bazel/releases/download/$BAZEL_VERSION/bazel-$BAZEL_VERSION-installer-linux-x86_64.sh && \
    sed -i 's@sudo@, @g' bazel-$BAZEL_VERSION-installer-linux-x86_64.sh && \
    chmod +x bazel-$BAZEL_VERSION-installer-linux-x86_64.sh &&\
    ./bazel-$BAZEL_VERSION-installer-linux-x86_64.sh --user

ENV PATH="/root/bin:${PATH}"

And It should build without errors. (as of 2018-09-18)

You can use the Dockerfile here

cumttang commented 6 years ago

Unlucky, https://github.com/bazelbuild/bazel/releases/download/$BAZEL_VERSION/bazel-$BAZEL_VERSION-installer-linux-x86_64.sh is not available now:(

bboyseiok commented 6 years ago

It's meant to be used inside dockerfile (that's why export BAZEL_VERSION=0.16.1 exists.)

Try with this then :) https://github.com/bazelbuild/bazel/releases/download/0.16.1/bazel-0.16.1-installer-linux-x86_64.sh

tkoeppe commented 6 years ago

Thanks a lot for reporting this! There has been a change in Bazel semantics. It was actually fixed internally a while ago, but I missed that and forgot to release that change. Fixed in 8ca0776954d7a3ba57ae1c494cebb12807fde423.