GithubHelp home page GithubHelp logo

Comments (8)

yyoncho avatar yyoncho commented on September 19, 2024 1

I think that you need linux-headers-4.15.0-20 for that(and I think that there were 2-3 more packages).

from elisp-tree-sitter.

ubolonton avatar ubolonton commented on September 19, 2024 1

On a related note, once #2 is done, there will be pre-built binaries, so people don't have to deal with this kind of headache.

from elisp-tree-sitter.

shackra avatar shackra commented on September 19, 2024

I already have that package installed, so, maybe the solution are those three mysterious packages

and, naturally, thank you for the reply, @yyoncho

from elisp-tree-sitter.

yyoncho avatar yyoncho commented on September 19, 2024

Might be of help:

➜  ~ dpkg -S stddef.h                                                    
linux-headers-4.15.0-20: /usr/src/linux-headers-4.15.0-20/include/uapi/linux/stddef.h
libclang-common-6.0-dev: /usr/lib/llvm-6.0/lib/clang/6.0.0/include/stddef.h
linux-libc-dev:amd64: /usr/include/linux/stddef.h
libclang-common-8-dev: /usr/lib/llvm-8/lib/clang/8.0.1/include/stddef.h
libgcc-7-dev:amd64: /usr/lib/gcc/x86_64-linux-gnu/7/include/stddef.h
libgcc-8-dev:amd64: /usr/lib/gcc/x86_64-linux-gnu/8/include/stddef.h
linux-headers-4.15.0-20: /usr/src/linux-headers-4.15.0-20/include/linux/stddef.h

from elisp-tree-sitter.

shackra avatar shackra commented on September 19, 2024

it is weird because I also installed libgcc-8-dev but the rust toolchain is unable to reach this file

from elisp-tree-sitter.

shackra avatar shackra commented on September 19, 2024

The following is the list of packages installed on my system's work laptop:
packages-installed.txt

and, as shown below I have most of the packages pointed out by @yyoncho installed:

cat /tmp/packages-installed.txt | grep "linux-headers-4.15.0-20\|libclang-common-6.0-dev\|linux-libc-dev\|libclang-common-8-dev\|libgcc-7-dev\|libgcc-8-dev\|linux-headers-4.15.0-20"
libclang-common-8-dev  1:8-3~ubuntu18.04.1     Clang library - Common development package
libgcc-7-dev    7.4.0-1ubuntu1~18.04.1  GCC support library (development files)
libgcc-8-dev    8.3.0-6ubuntu1~18.04.1  GCC support library (development files)
linux-headers-4.15.0-20 4.15.0-20.21    Header files related to Linux kernel version 4.15.0
linux-headers-4.15.0-20-generic 4.15.0-20.21    Linux kernel headers for version 4.15.0 on 64 bit x86 SMP
linux-libc-dev  4.15.0-64.73    Linux Kernel Headers for development

from elisp-tree-sitter.

ubolonton avatar ubolonton commented on September 19, 2024

I only tested this on Ubuntu. It may be the case that the Ubuntu installations I use (CI and my own server) already have the necessary packages, with correct configuration.

emacs-module-rs uses bindgen to generate the raw bindings. bindgen uses clang to search for system header files, not gcc. You have libclang-common-8-dev installed, so it may be an issue with include path configuration, not missing packages.

Can you check what these commands print?

sudo find / -name stddef.h

echo $CPATH

echo $C_INCLUDE_PATH

clang -E -x c - -v < /dev/null

from elisp-tree-sitter.

shackra avatar shackra commented on September 19, 2024

@ubolonton it turns out I did not had clang installed to begin with. I installed it and was able to build

from elisp-tree-sitter.

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.