Skip to content

Travis CI currently fails #3

@thomasjfox

Description

@thomasjfox

Testing with Travis CI currently fails.
tl;dr: It picks up the wrong libmagic.so:
file: compiled magic version [532] does not match with shared library magic version [514]

.travis.yml basically does a "make" and "make install".
After that it calls "file --version" and from the log you can see it's the current file version.
It does not set any LD_LIBRARY_PATH. What happens now is that it will pick up the "libmagic.so" from Travis CI's system instead of the just built one.

We could either tweak around the LD_LIBRARY_PATH or set -rpath during compile time.
Something like "LDFLAGS=-Wl,-rpath $BUILD_DIR". That's how I do it for my local file-tests invocation.

Example log output showing the problem:
https://travis-ci.org/file/file-tests/jobs/272927961

$ file --version
file-5.32
magic file from /etc/magic:/usr/share/misc/magic

The command "file --version" exited with 0.

python update-db.py -m file/magic/Magdir
using file from /usr/bin/file
version is file-5.32
magic file from /etc/magic:/usr/share/misc/magic
[ ################################################ ] 100% Splitting patterns
file: compiled magic version [532] does not match with shared library magic version [514]
file: Unknown !: entry `!:ext cwk'
.. [CRASH] ..

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions