unofficial mirror of help-guix@gnu.org 
 help / color / mirror / Atom feed
From: Mark H Weaver <mhw@netris.org>
To: Christopher Lemmer Webber <cwebber@dustycloud.org>
Cc: help-guix <help-guix@gnu.org>
Subject: Re: Compiling a linux kernel from git
Date: Sat, 06 Jul 2019 18:21:50 -0400	[thread overview]
Message-ID: <87pnmm9535.fsf@netris.org> (raw)
In-Reply-To: <877e8v5ezu.fsf@dustycloud.org> (Christopher Lemmer Webber's message of "Sat, 06 Jul 2019 12:01:53 -0400")

Hi Chris,

Christopher Lemmer Webber <cwebber@dustycloud.org> writes:

> Unfortunately my laptop was failing and I needed to pick up a new one
> asap before a conference I leave for tomorrow morning, so I bought one
> off the shelf from a retail store.  Also unfortunately, while the
> hardware is supported in upstream linux, it isn't in any of the released
> tarballs yet.  I thought I'd try to make a package derivative:
>
> (define linux-next
>   (package
>    (inherit linux-libre)
>    (name "linux-next")
>    (version "22c45ec32b4a9fa8c48ef4f5bf9b189b307aae12")
>    (source
>     (origin
>      (method git-fetch)
>      (uri (git-reference
>            (url (string-append "https://git.kernel.org/pub/scm/linux/"
>                                "kernel/git/next/linux-next.git"))
>            (commit version)))
>      (file-name (string-append "linux-next-" version "-checkout"))
>      (sha256
>       (base32
>        "1f3fn2mcfa213vb0d40386533dy4nll9v9d2jc6bi7gd38z2rc18"))))))
>
> Unfortunately an extra step seems to be necessary, or something.  It's
> failing at the "make oldconfig" stage:
>
>
> patch-shebang: ./tools/usb/usbip/autogen.sh: changing `/bin/sh' to `/gnu/store/q19l04vd2za80mk1845pz7r8cz29qk43-bash-minimal-4.4.23/bin/sh'
> patch-shebang: ./tools/usb/usbip/cleanup.sh: changing `/bin/sh' to `/gnu/store/q19l04vd2za80mk1845pz7r8cz29qk43-bash-minimal-4.4.23/bin/sh'
> patch-shebang: ./tools/usb/usbip/vudc/vudc_server_example.sh: changing `/bin/bash' to `/gnu/store/q19l04vd2za80mk1845pz7r8cz29qk43-bash-minimal-4.4.23/bin/bash'
> patch-shebang: ./tools/virtio/ringtest/run-on-all.sh: changing `/bin/sh' to `/gnu/store/q19l04vd2za80mk1845pz7r8cz29qk43-bash-minimal-4.4.23/bin/sh'
> patch-shebang: ./tools/vm/slabinfo-gnuplot.sh: changing `/bin/bash' to `/gnu/store/q19l04vd2za80mk1845pz7r8cz29qk43-bash-minimal-4.4.23/bin/bash'
> patch-shebang: ./usr/gen_initramfs_list.sh: changing `/bin/sh' to `/gnu/store/q19l04vd2za80mk1845pz7r8cz29qk43-bash-minimal-4.4.23/bin/sh'
> phase `patch-source-shebangs' succeeded after 4.8 seconds
> starting phase `work-around-gcc-7-include-path-issue'
> phase `work-around-gcc-7-include-path-issue' succeeded after 0.0 seconds
> starting phase `configure'
> `ARCH' set to `x86_64'
>   HOSTCC  scripts/basic/fixdep
>   HOSTCC  scripts/kconfig/conf.o
> In file included from /gnu/store/h90vnqw0nwd0hhm1l5dgxsdrigddfmq4-glibc-2.28/include/stdlib.h:394:0,
>                  from scripts/kconfig/conf.c:9:
> /gnu/store/h90vnqw0nwd0hhm1l5dgxsdrigddfmq4-glibc-2.28/include/sys/types.h:42:18: error: conflicting types for 'loff_t'
>  typedef __loff_t loff_t;
>                   ^~~~~~
> In file included from /gnu/store/3qbgfljvmyi12df4yiwjnlg7mwkc4z1y-linux-next-22c45ec32b4a9fa8c48ef4f5bf9b189b307aae12-checkout/include/linux/limits.h:6:0,
>                  from /gnu/store/h90vnqw0nwd0hhm1l5dgxsdrigddfmq4-glibc-2.28/include/bits/local_lim.h:38,
>                  from /gnu/store/h90vnqw0nwd0hhm1l5dgxsdrigddfmq4-glibc-2.28/include/bits/posix1_lim.h:161,
>                  from /gnu/store/h90vnqw0nwd0hhm1l5dgxsdrigddfmq4-glibc-2.28/include/limits.h:183,
>                  from /gnu/store/rvv5rw5gcrpmbgnvhb60f7czk0m0h2qp-gcc-7.4.0-lib/lib/gcc/x86_64-unknown-linux-gnu/7.4.0/include-fixed/limits.h:194,
>                  from /gnu/store/rvv5rw5gcrpmbgnvhb60f7czk0m0h2qp-gcc-7.4.0-lib/lib/gcc/x86_64-unknown-linux-gnu/7.4.0/include-fixed/syslimits.h:7,
>                  from /gnu/store/rvv5rw5gcrpmbgnvhb60f7czk0m0h2qp-gcc-7.4.0-lib/lib/gcc/x86_64-unknown-linux-gnu/7.4.0/include-fixed/limits.h:34,
>                  from scripts/kconfig/conf.c:7:
> /gnu/store/3qbgfljvmyi12df4yiwjnlg7mwkc4z1y-linux-next-22c45ec32b4a9fa8c48ef4f5bf9b189b307aae12-checkout/include/linux/types.h:46:26: note: previous declaration of 'loff_t' was here
>  typedef __kernel_loff_t  loff_t;
>                           ^~~~~~

My first guess is that '/gnu/store/…-linux-next-…-checkout/include'
should not be in the C include path while compiling that file, but that
it's getting added.  The difference might be due to the fact that the
'source' in this case is a directory instead of a tarball.  For now, I
would try packing the git checkout as a tarball, and then using that
tarball as your 'source'.

       Mark

  reply	other threads:[~2019-07-06 22:22 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-06 16:01 Compiling a linux kernel from git Christopher Lemmer Webber
2019-07-06 22:21 ` Mark H Weaver [this message]
2019-07-07  3:57   ` Mark H Weaver
2019-07-07  7:00     ` Christopher Lemmer Webber
2019-07-07 23:30       ` Mark H Weaver
2019-07-06 23:41 ` Tobias Geerinckx-Rice
2019-07-06 23:49   ` Tobias Geerinckx-Rice

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87pnmm9535.fsf@netris.org \
    --to=mhw@netris.org \
    --cc=cwebber@dustycloud.org \
    --cc=help-guix@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).