Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
emerge failed because I don't have /usr/src/linux?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
fpemud
Apprentice
Apprentice


Joined: 15 Feb 2012
Posts: 264

PostPosted: Tue Apr 05, 2016 12:44 pm    Post subject: emerge failed because I don't have /usr/src/linux? Reply with quote

fpemud-workstation codes # USE=minimal emerge -1 mono
Calculating dependencies... done!

>>> Verifying ebuild manifests
>>> Running pre-merge checks for dev-lang/mono-4.2.3.4
* Determining the location of the kernel source code
* Unable to find kernel sources at /usr/src/linux
* Please make sure that /usr/src/linux points at your running kernel,
* (or the kernel you wish to build against).
* Alternatively, set the KERNEL_DIR environment variable to the kernel sources location
* Unable to calculate Linux Kernel version for build, attempting to use running version
* Could not find a usable .config in the kernel source directory.
* Please ensure that /usr/src/linux points to a configured set of Linux sources.
* If you are using KBUILD_OUTPUT, please set the environment var so that
* it points to the necessary object directory so that it might find .config.
* ERROR: dev-lang/mono-4.2.3.4::gentoo failed (pretend phase):
* Kernel not configured; no .config found in
*
* Call stack:
* ebuild.sh, line 133: Called pkg_pretend
* mono-4.2.3.4.ebuild, line 44: Called check_extra_config
* linux-info.eclass, line 734: Called require_configured_kernel
* linux-info.eclass, line 297: Called die
* The specific snippet of code:
* die "Kernel not configured; no .config found in ${KV_OUT_DIR}"
*
* If you need support, post the output of `emerge --info '=dev-lang/mono-4.2.3.4::gentoo'`,
* the complete build log and the output of `emerge -pqv '=dev-lang/mono-4.2.3.4::gentoo'`.
* The complete build log is located at '/var/tmp/portage/dev-lang/mono-4.2.3.4/temp/build.log'.
* The ebuild environment file is located at '/var/tmp/portage/dev-lang/mono-4.2.3.4/temp/die.env'.
* Working directory: '/usr/lib64/python3.3/site-packages'
* S: '/var/tmp/portage/dev-lang/mono-4.2.3.4/work/mono-4.2.3'


In my opinion, /proc/config.gz should be the fall back for /usr/src/linux/.config, shouldn't it?
Or is it a sin that I don't keep /usr/src/linux?
Back to top
View user's profile Send private message
Roman_Gruber
Advocate
Advocate


Joined: 03 Oct 2006
Posts: 3806
Location: Austro Bavaria

PostPosted: Tue Apr 05, 2016 1:48 pm    Post subject: Reply with quote

no

gentoo needs (official way)

e.g. gentoo sources installed and pointing to that installed gentoo source + valid kernel config there

thats it.

you can have /usr/src/linux point to any valid kernel sources.

---

many ebuilds depends on
Quote:
Or is it a sin that I don't keep /usr/src/linux?


i know its nuts to waste 1gb for a kernel souce but tahts it (binary blobs in it are the cause)
Back to top
View user's profile Send private message
khayyam
Watchman
Watchman


Joined: 07 Jun 2012
Posts: 6228
Location: Room 101

PostPosted: Tue Apr 05, 2016 1:57 pm    Post subject: Reply with quote

fpemud ...

you can probably work around it like so:

Code:
# mkdir -p /tmp/$(uname -r)
# zcat /proc/config.gz > /tmp/$(uname -r)/.config
# KERNEL_DIR=/tmp/$(uname -r) emerge -1 mono

... or you might set up a more permanent solution via a script in /etc/local.d/ and so have /tmp/$(uname -r)/.config, and the KERNEL_DIR parameter, setup automatically.

best ... khay
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum