GithubHelp home page GithubHelp logo

Fail in make project about libxkbcommon HOT 10 CLOSED

xkbcommon avatar xkbcommon commented on July 17, 2024
Fail in make project

from libxkbcommon.

Comments (10)

bluetech avatar bluetech commented on July 17, 2024

Are you building from git? If not, which version?
Can you attach the file 'config.log' from the build root?

Thanks.

from libxkbcommon.

bluetech avatar bluetech commented on July 17, 2024

So I can only assume you're using some yacc which is not bison. I just made some commits which adds support for recent byacc as well. I'm not aware of any other widely used yacc's.

Anything more than that is unlikely - either bison or byacc should be sufficient. Feel free to reopen if this is not the case.

from libxkbcommon.

ballifatih avatar ballifatih commented on July 17, 2024

Hi,

When trying to build library, I am getting similar error. I am using OS X Yosemite, and trying to port this library to MacPorts, as it is required as dependency. I attached the config.log file.

YACC     src/xkbcomp/parser.c
/Users/blue/Downloads/libxkbcommon-0.5.0/src/xkbcomp/parser.y:220.5-9: syntax error, unexpected type, expecting string or identifier
make: *** [src/xkbcomp/parser.c] Error 1

As for yacc, checking the version returns:

bison (GNU Bison) 2.3
Written by Robert Corbett and Richard Stallman.

I am using the version 5.0 from http://lists.freedesktop.org/archives/wayland-devel/2014-October/017836.html

from libxkbcommon.

nuko8 avatar nuko8 commented on July 17, 2024

As @bluetech pointed out in Issue #23, Bison 2.3 is too old to compile parser.y.

I've successfully built libxkbcommon with Bison 3.0.4 on both Mavericks and El Capitan. I installed that Bison via MacPorts :-)

from libxkbcommon.

ballifatih avatar ballifatih commented on July 17, 2024

Yeah, after getting updated version of Bison, finally it passed the yacc parsing problem. (It took some time to realize almost every tool coming default with OS X is older versions). But now I am getting complaints that

CCLD     libxkbcommon.la
ld: unknown option: --version-script=./xkbcommon.map
clang: error: linker command failed with exit code 1 (use -v to see invocation)

This also is a similar problem. So should I move completely away from OS X gcc compiler to GNU compiler. Or more generally, do I have to move completely to the core tools with MacPorts.

from libxkbcommon.

nuko8 avatar nuko8 commented on July 17, 2024

That's the issue #24 and has already been fixed with the github version.

So should I move completely away from OS X gcc compiler to GNU compiler. Or more generally, do I have to move completely to the core tools with MacPorts.

I think you don't need to do that. The problem is simply caused by passing the wrong flag --version-script, which is unknown to clang's linker. Only dropping the flag should be fine.

from libxkbcommon.

nuko8 avatar nuko8 commented on July 17, 2024

Only dropping the flag should be fine.

@bluetech committed 257e38c to fix the issue.

from libxkbcommon.

ballifatih avatar ballifatih commented on July 17, 2024

Indeed, dropping the flag --version-script makes compiling OK. So, it is working with Bison 3.0.4; and dropping the flag from Makefile successfully compiles( I am still 5.0 version from the stable releases).

However, when using the most recent version with cloning, I am not able to auto configure the library.

$ autoconf
configure.ac:45: error: must install xorg-macros 1.16 or later before running autoconf/autogen
configure.ac:45: the top level
autom4te: /usr/bin/m4 failed with exit status: 1

However, when I check from MacPorts, it claims that I already have the most recent version. (xorg-util-macro: 1.19). So I am guessing, the name differences between ports and libraries makes some problem, when Makefile's checking lib versions. Anyways, still 5.0 version works with dropped flag. I am planning to write a Portfile for the library, so I am still trying to get the most convenient way.

Thanks for the help :)

from libxkbcommon.

nuko8 avatar nuko8 commented on July 17, 2024

$ autoconf

Instead of invoking autoconf directly, I guess you'll get a better result with

$ ./autogen.sh

at the top directory of the source tree.

from libxkbcommon.

ballifatih avatar ballifatih commented on July 17, 2024

Oh, it works like a charm when I use ./autogen.sh script. Then everything is fine. Thanks again :)

from libxkbcommon.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.