Compile my own kernel?

Hi!
I wan't to edit and compile my own kernel, so I got even more structure on my machine - and I hope to get a little more performance.
How do I edit and Compile a custom kernel?
[EDIT] And maybe how I make all my own-compiled programs to be compiled to a Pentium4 processor As i could when I was a Gentoo user

Kris;
There is a wiki for custom kernel generation.
Basically, you can use ABS to obtain the basic kernel  and its accompanying patches and config file.  ABS is  Arch Build System which somewhat automates the making of packages, including custom kernels.
Just run abs in CL and find the download in /var/abs/kernels.
The kernel you desire to customize is found therein.
You customize it by modifying the kernelconfig and setup PKGBUILD file.
Run "makepkg" on the PKGBUILD and then run pacman -A (name of custom kernel.pkg.tar.gz).  If using lilo run/sbin/lilo before reboot.
The steps are outlined in the wikis.
Best of luck!!!

Similar Messages

  • A little question about compiling my own kernel

    Hii, How can I know please, wich moudle is loaded in my current kernel and being used?
    for example, if I have now the RAID xxxx , and I don't use it, so when compiling my own Kernel, I don't need it.
    How can I know wich ones arn't needed?

    Ok Lsmod I know, is there any thing else?

  • Rolling my own kernel off a fresh install

    Hey folks!
    I just recently acquired an Acer Aspire One. In a vain effort to get the wireless working off of a fresh install I thought that I might compile my own kernel version 2.6.27 (and I hoped that the ath5k driver would automagically work). Sadly I ran into some issues, and owing to my ignorance of Linux kernel compiling magic I have posted here to the Newbie forum:
    So I get to the point where I need to install the kernel (after compiling from source), but I lack the program mkinitrd. I did some research and apparently we use mkinitramfs, which the fresh install also doesn't come with.
    My questions are thus:
    1) Is it possible to make an initrd on a computer which the initrd is NOT intended for?
    2) Why is it that a fresh install doesn't come with the stuff required to recompile a kernel, I would think that might be important?
    I am thankful for any help!

    Hey awesome, this looks good.
    If a package is included in the "Core" repository, does that mean it comes rolled up with the Arch install?
    EDIT:
    I see now that this is the case. From the Official Arch Linux Install Guide:
    The core iso (~300MB) is a live environment which contains a snapshot of the entire /core repository. Packages are divided into 4 categories: BASE, SUPPORT, DEVEL and LIB. RAID/LVM are fully supported; all necessary packages are included within /core. Installing from a medium created with this image results in a completely functional GNU/Linux system, without any frills, expecting to be used from the command line; the Linux kernel, GNU toolchain and a few extra modules and libraries. This image is ideally suited for those who have a rather slow or nonexistent internet connection on the candidate machine, making an FTP install unfeasible. The name of the iso will be "archlinux-i686-2008.xx-x.core.iso", according to your architecture
    Last edited by amackera (2008-11-04 01:15:00)

  • Installing own kernel...

    I have no problem git cloning my kernel of choice and configuring. My question is when compiling a new video drivers or any other package that might be dependent on Linux sources. I usually use the /usr/src directory. I am having trouble with the PKGBUILD on kernel26zen-git. It fails at installing after compile.
    Is there a global symlink ?Like there is in Gentoo? Where, I can custom build my kernels, and not have to worry about when I install new Nvidia drivers from there website. I am just greatly disappointed in these custom PKGBUILDS, and I don't need a initrd package. Are there any special parameters I need to be aware of... such as any global symlinks?
    Am I going to have problems install drivers from Nvidia's site if I decide not use the kernel26 packages, or any other package that compiles against the kernel sources..?
    Here's the error I get from the PKGBUILD
    ==> ERROR: Failed... Your source tree might be broken. Run 'make mrproper' in src/kernel26zen to clean it up
    ==> ERROR: Build Failed.
    Aborting...
    Error: Makepkg was unable to build kernel26zen package
    Last edited by StanIsTheMan (2009-09-26 20:36:48)

    B wrote:
    The PKGBUILD seems to be pointing to his own kernel chanco, shouldn't be a problem.
    @ OP: did you try the suggestion the error is giving you? I.e. a
    make mproper
    in the source tree?
    I was going to ... but I decided on a static kernel. And since I used to write ebuilds for my own packages, I decided to take up the task of writing my own PKGBUILD /w a static kernel, using the zen-sources git tree.
    BTW, am I going to be running into any problems in the future when running updates through pacman /w the way my kernel is setup? That's ,my main concern, since I am using a static kernel.  Though I do use my own video drivers from the Nvidia site, so I am not worried about video drivers.
    I guess I became accustomed with gentoo, that so much of the transition has been different.  Though I like Arch and its ABS, and AUR, plus there are lot of packages available.
    Last edited by StanIsTheMan (2009-09-27 23:03:52)

  • Making own kernel patches?

    Dear archers,
    I had to change a file (saa7134-card.c) in kernel source to make my Avermedia TV Tuner work. But i must try to change some code in the file several time. It's not a problem if i'm compiling the kernel by traditional way, but if i follow the arch way, it's so time consumed because i had to extract the original kernel source and then edit saa7134-card.c file again. Then, some questions pop-up in my mind...
    1. How do i edit a file in kernel source tarball and put it again in the tarball?
    2. How do i make my own kernel patch?
    3. Do pacman always extract the sources tarball and overwrite files in $startdir/src when i do makepkg? is it possible to skip that step in makepkg process?

    Your best bet would just be make a diff file and add that to your PKGBUILD. Just make the changes and save it under a different file name. Use diff to create the file and then use patch to apply it in your PKGBUILD. Here's how I do it
    patch --ignore-whitespace <$startdir/right-click.diff $startdir/src/$pkgname-$pkgver/src/adesklets.c

  • Problems with own kernel and nvidia

    Hi.
    I've got a little problem with nvidia driver. I removed stock kernel and compiled my own. Then I installed nvidia drivers (from nvidia.com) and everythings gone fine. But after reboot Xserver doesn't seem to start. The only way to run X is to reinstall nvidia drivers (after every reboot)... anyone knows any solution for that?

    Log:
    (**) NVIDIA(0): Depth 24, (--) framebuffer bpp 32
    (==) NVIDIA(0): RGB weight 888
    (==) NVIDIA(0): Default visual is TrueColor
    (==) NVIDIA(0): Using gamma correction (1.0, 1.0, 1.0)
    (**) NVIDIA(0): Option "NoLogo" "on"
    (**) NVIDIA(0): Option "TripleBuffer" "on"
    (**) NVIDIA(0): Option "AddARGBGLXVisuals"
    (**) NVIDIA(0): Enabling RENDER acceleration
    (II) NVIDIA(0): Support for GLX with the Damage and Composite X extensions is
    (II) NVIDIA(0): enabled.
    (EE) NVIDIA(0): Failed to initialize the NVIDIA kernel module! Please ensure
    (EE) NVIDIA(0): that there is a supported NVIDIA GPU in this system, and
    (EE) NVIDIA(0): that the NVIDIA device files have been created properly.
    (EE) NVIDIA(0): Please consult the NVIDIA README for details.
    (EE) NVIDIA(0): *** Aborting ***
    (II) UnloadModule: "nvidia"
    (II) UnloadModule: "wfb"
    (II) UnloadModule: "fb"
    (EE) Screen(s) found, but none have a usable configuration.
    Fatal server error:
    no screens found

  • Strange error compiling a custom kernel...

    Here is the error i get when compiling a custom kernel (i tried both 2.6.22 from core and 2.6.23 from testing):
    init/built-in.o: In function 'start_kernel':
    (.init.text.0x836): undefined reference to 'early_populated_rootfs'
    make: *** [.tmp_vmlinuz1] Error 1
    i have no idea of what it the problem, the config file it's the same i've used for all my 2.6.22 kernels, any idea?
    Thank you.

    This kind of error is when you forget to add a source file to gcc comand line during compilation. I think that problem might be in one of broken Makefiles in kernel tree. Maybe some patch messed with them. Try to download fresh kernel sources.

  • Compiling Sata into Kernel [SOLVED]

    First time compiling a custom kernel. I've gone through the config process about 10 times now but never took the plunge. I did notice, however, that using gconfig I can't get SATA_AHCI to become a 'checkmark' which, I have taken to understand, means it'll be built into the kernel. Do I have to edit the config using vi or is there something I'm not getting/understanding?
    Thanks.
    Last edited by virati (2009-07-22 22:16:42)

    virati wrote:hmm. In looking into that I just realized that gconf is not saving/loading my config when I tell it to. It's flat out ignoring all the changes that I make. This is frustrating... Any idea what's going on?
    I once had this problem of the kernel not building with the configurations that I would choose in the "make menuconfig", and it would always use the /proc/config.gz of the default .config (so it would build as Generic x86_64 instead of AMD64 and all of my other changes that I would do)
    I found that this setting in the General Setup section would allow my new settings from "make menuconfig" to be used:
    CONFIG_IKCONFIG=y
    # CONFIG_IKCONFIG_PROC is not set
    I just set the CONFIG_IKCONFIG_PROC to not be used. (it used to be =y)
    This way the new kernel26NEW package was built with my new settings and not the old config from /proc. All of the new changes that I made in "make menuconfig" were shown in the /usr/src/linux-2.6.30-ARCHNEW/.config file of the new package after it was built. (before I did this it had all of the old generic settings in that same file after selecting AMD64 and other changes)

  • How would I go about compiling my own multilib GCC?

    Hello, as the topic says, how would I compile my own multilib GCC? I realize there is one on the AUR, but it is version 4.4.0, which has issues with compiling FFMpeg and MPlayer(both of which I compile daily), and the fact that the pkgbuild has to be manually updated in a few areas to work in the first place. I'm thinking about updating the PKGBUILD myself, actually(well creating a parallel build in any case, because the author hasn't actually orphaned it, but he seems to have disappeared).
    I've found a few documents on the subject but they are distro specific, or use scripts. I don't want to be a script kiddie, I want to know what the "base" configure parameters are for setting one up. I can figure out the rest.
    Slackware scripts link here.
    -What ./configure parameters create a multi-lib system? What specifies the multilib compile to be 32-bit and 64-bit?(I read that sometimes people use multi-lib for other features so I want to make sure it's 32-bit and 64-bit, not something else)
    -How would I make this build compatible with the /opt/lib32 system that Arch users like to use?
    -Do I only need to compile binutils, glibc, and gcc? And lastly, does this replace the "regular" gcc on the system?(aka if I created a PKGBUILD for this, would gcc still be named gcc or would it be renamed gcc-multilib and have it's own directories for libs)
    Last edited by MP2E (2009-10-01 01:03:40)

    I'd start by going here:
    http://aur.archlinux.org/packages.php?ID=28545

  • Problems bringing up my ADSL connection with mu own kernel

    Hey guys,
    I got some problems.
    I'm running arch linux (v0.6) 4th day already and I think this distro is awesome. Now about my problem.
    When I've installed arch linux i've installed a IDE kernel from CD. it's v2.4.21. Like always, everything runs well except my sound card. I can use the internet with it, but I need sound (DOH! . So I decided to compile my custom kernel (v2.4.25). In menuconfig I select everythink that my computer needs (Realtek card drivers, sound drivers (my soundcard is SBAWE 32) and other things.) When I boot new kernel I can't bring up my ADSL connection. I use a PPPoE mode ([computer] ->- [eth0] ->- [adsl splitter] ->- [adsl modem] ->- [telephone line]). When I compile kernel I compile in (not as a module) ppp and pppoe support. I use rp-pppoe software to connect to the internet. It just can't bring my adsl connection up Maybe I forgot something to compile in my kernel? I've compared the new kernel's /proc/pci with the old /proc/pci... all information is the same.
    Can you suggest me something?
    p.s. my adsl modem is Ericcson HM210dp

    ah nevermind, problem solved. I recompiled kernel 1hr ago, and compiled in support for "async" and "sync" ports (or smth like that). now everything is OK. :twisted:

  • How to compile my own applications

    Hello,
    I have been working through a book on J2ee, and getting on very well, apart from the fact that I cant create my own applications because I dont know how to compile them!!!
    Im used to just typing javac classsname.java, and it all gets done - I've tried this on my J2ee source files and I keep getting errors becasue the J2EE library classes I reference cant be found.
    I have been doing the exercises and examples that came with the book with no trouble, using asant to compile and build programs. I can use asant in this way with no problems, but that is becaause of a ready-cooked build.xml file and the works.
    Is asant the only way to compile J2EE apps, and if it is how do I go about using it for my own applications? Does it mean building my own build.xml file for each application I writeand then using asant as in the case of the examples?
    can javac not be used on its own to compile the application?
    Thanks for the feedback.

    Im used to just typing javac classsname.java, and it
    all gets done - I've tried this on my J2ee source
    files and I keep getting errors becasue the J2EE
    library classes I reference cant be found.J2EE library classes are in $J2EE_HOME/lib/j2ee.jar
    I have been doing the exercises and examples that came
    with the book with no trouble, using asant to compile
    and build programs. I can use asant in this way with
    no problems, but that is becaause of a ready-cooked
    build.xml file and the works.
    Is asant the only way to compile J2EE apps, and if it
    is how do I go about using it for my own applications?
    Does it mean building my own build.xml file for each
    application I writeand then using asant as in the case
    of the examples?
    can javac not be used on its own to compile the
    application?asant comes with predefined ant targets which has been found very useful. Check out the J2EE tutorial (http://java.sun.com/j2ee/1.4/docs/tutorial/doc/index.html) and the J2EE-SDK samples bundle. You can also use ant and write your own targets. Check out J2EE BLuePrints applications (java.sun.com/blueprints) or the BLuePrints solutions catalog (https://bpcatalog.dev.java.net/). Hope this helps

  • [Solved] Compiling a new kernel with ABS

    I've made it through the whole process outlined in the wiki, up to installing with pacman.  Pacman is telling me that the stock arch kernel is a conflicting package and wants to remove it.  I want to hang on to it in case I've messed something up.  What am I doing wrong?  I know you can have two kernels installed.  Using the traditional way I can get this, but I'd rather keep to doing things The Arch Way.
    Last edited by Morrvick (2011-11-17 00:40:30)

    I double checked what I was doing, and I have done that.  Here is my modified PKGBUILD:
    # $Id: PKGBUILD 130991 2011-07-09 12:23:51Z thomas $
    # Maintainer: Tobias Powalowski <[email protected]>
    # Maintainer: Thomas Baechler <[email protected]>
    pkgbase=linux
    #pkgname=('linux' 'linux-headers' 'linux-docs') # Build stock -ARCH kernel
    pkgname=('linux-morrvick' 'linux-headers-morrvick') # Build kernel with a different name
    _kernelname=${pkgname#linux}
    _basekernel=3.1
    pkgver=${_basekernel}.1
    pkgrel=1
    arch=('i686' 'x86_64')
    url="http://www.kernel.org/"
    license=('GPL2')
    makedepends=('xmlto' 'docbook-xsl')
    options=('!strip')
    source=("http://www.kernel.org/pub/linux/kernel/v3.x/linux-3.1.tar.xz"
    "http://www.kernel.org/pub/linux/kernel/v3.x/patch-${pkgver}.xz"
    # the main kernel config files
    'config' 'config.x86_64'
    # standard config files for mkinitcpio ramdisk
    "${pkgname}.preset"
    'change-default-console-loglevel.patch'
    'i915-fix-ghost-tv-output.patch'
    'i915-fix-incorrect-error-message.patch'
    'usb-add-reset-resume-quirk-for-several-webcams.patch')
    md5sums=('edbdc798f23ae0f8045c82f6fa22c536'
    '2bf7eb28a58238e1a062fa7393bf7824'
    'cbaaa923f00c1935055273ccc1630144'
    '93687a4b7e1e6bcd4e7417d6e5079bc4'
    'eb14dcfd80c00852ef81ded6e826826a'
    '9d3c56a4b999c8bfbd4018089a62f662'
    '263725f20c0b9eb9c353040792d644e5'
    'a50c9076012cb2dda49952dc6ec3e9c1'
    '52d41fa61e80277ace2b994412a0c856')
    build() {
    cd "${srcdir}/linux-${_basekernel}"
    # add upstream patch
    patch -p1 -i "${srcdir}/patch-${pkgver}"
    # add latest fixes from stable queue, if needed
    # http://git.kernel.org/?p=linux/kernel/git/stable/stable-queue.git
    # Some chips detect a ghost TV output
    # mailing list discussion: http://lists.freedesktop.org/archives/intel-gfx/2011-April/010371.html
    # Arch Linux bug report: FS#19234
    # It is unclear why this patch wasn't merged upstream, it was accepted,
    # then dropped because the reasoning was unclear. However, it is clearly
    # needed.
    patch -Np1 -i "${srcdir}/i915-fix-ghost-tv-output.patch"
    # In 3.1.1, a DRM_DEBUG message is falsely declared as DRM_ERROR. This
    # worries users, as this message is displayed even at loglevel 4. Fix
    # this.
    patch -Np1 -i "${srcdir}/i915-fix-incorrect-error-message.patch"
    # Add the USB_QUIRK_RESET_RESUME for several webcams
    # FS#26528
    patch -Np1 -i "${srcdir}/usb-add-reset-resume-quirk-for-several-webcams.patch"
    # set DEFAULT_CONSOLE_LOGLEVEL to 4 (same value as the 'quiet' kernel param)
    # remove this when a Kconfig knob is made available by upstream
    # (relevant patch sent upstream: https://lkml.org/lkml/2011/7/26/227)
    patch -Np1 -i "${srcdir}/change-default-console-loglevel.patch"
    if [ "${CARCH}" = "x86_64" ]; then
    cat "${srcdir}/config.x86_64" > ./.config
    else
    cat "${srcdir}/config" > ./.config
    fi
    if [ "${_kernelname}" != "" ]; then
    sed -i "s|CONFIG_LOCALVERSION=.*|CONFIG_LOCALVERSION=\"${_kernelname}\"|g" ./.config
    fi
    # set extraversion to pkgrel
    sed -ri "s|^(EXTRAVERSION =).*|\1 -${pkgrel}|" Makefile
    # get kernel version
    make prepare
    # load configuration
    # Configure the kernel. Replace the line below with one of your choice.
    #make menuconfig # CLI menu for configuration
    #make nconfig # new CLI menu for configuration
    make xconfig # X-based configuration
    #make oldconfig # using old config from previous kernel version
    # ... or manually edit .config
    # stop here
    # this is useful to configure the kernel
    #msg "Stopping build"
    #return 1
    yes "" | make config
    # build!
    make ${MAKEFLAGS} bzImage modules
    package_linux-morrvick() {
    pkgdesc="The Linux Kernel and modules"
    groups=('base')
    depends=('coreutils' 'linux-firmware' 'module-init-tools>=3.16' 'mkinitcpio>=0.7')
    optdepends=('crda: to set the correct wireless channels of your country')
    provides=('kernel26')
    conflicts=('kernel26')
    replaces=('kernel26')
    backup=("etc/mkinitcpio.d/${pkgname}.preset")
    install=${pkgname}.install
    cd "${srcdir}/linux-${_basekernel}"
    KARCH=x86
    # get kernel version
    _kernver="$(make kernelrelease)"
    mkdir -p "${pkgdir}"/{lib/modules,lib/firmware,boot}
    make INSTALL_MOD_PATH="${pkgdir}" modules_install
    cp arch/$KARCH/boot/bzImage "${pkgdir}/boot/vmlinuz-${pkgname}"
    # add vmlinux
    install -D -m644 vmlinux "${pkgdir}/usr/src/linux-${_kernver}/vmlinux"
    # install fallback mkinitcpio.conf file and preset file for kernel
    install -D -m644 "${srcdir}/${pkgname}.preset" "${pkgdir}/etc/mkinitcpio.d/${pkgname}.preset"
    # set correct depmod command for install
    sed \
    -e "s/KERNEL_NAME=.*/KERNEL_NAME=${_kernelname}/g" \
    -e "s/KERNEL_VERSION=.*/KERNEL_VERSION=${_kernver}/g" \
    -i "${startdir}/${pkgname}.install"
    sed \
    -e "s|ALL_kver=.*|ALL_kver=\"/boot/vmlinuz-${pkgname}\"|g" \
    -e "s|default_image=.*|default_image=\"/boot/initramfs-${pkgname}.img\"|g" \
    -e "s|fallback_image=.*|fallback_image=\"/boot/initramfs-${pkgname}-fallback.img\"|g" \
    -i "${pkgdir}/etc/mkinitcpio.d/${pkgname}.preset"
    # remove build and source links
    rm -f "${pkgdir}"/lib/modules/${_kernver}/{source,build}
    # remove the firmware
    rm -rf "${pkgdir}/lib/firmware"
    # gzip -9 all modules to save 100MB of space
    find "${pkgdir}" -name '*.ko' -exec gzip -9 {} \;
    # make room for external modules
    ln -s "../extramodules-${_basekernel}${_kernelname:--ARCH}" "${pkgdir}/lib/modules/${_kernver}/extramodules"
    # add real version for building modules and running depmod from post_install/upgrade
    mkdir -p "${pkgdir}/lib/modules/extramodules-${_basekernel}${_kernelname:--ARCH}"
    echo "${_kernver}" > "${pkgdir}/lib/modules/extramodules-${_basekernel}${_kernelname:--ARCH}/version"
    package_linux-headers-morrvick() {
    pkgdesc="Header files and scripts for building modules for linux kernel"
    provides=('kernel26-headers')
    conflicts=('kernel26-headers')
    replaces=('kernel26-headers')
    mkdir -p "${pkgdir}/lib/modules/${_kernver}"
    cd "${pkgdir}/lib/modules/${_kernver}"
    ln -sf ../../../usr/src/linux-${_kernver} build
    cd "${srcdir}/linux-${_basekernel}"
    install -D -m644 Makefile \
    "${pkgdir}/usr/src/linux-${_kernver}/Makefile"
    install -D -m644 kernel/Makefile \
    "${pkgdir}/usr/src/linux-${_kernver}/kernel/Makefile"
    install -D -m644 .config \
    "${pkgdir}/usr/src/linux-${_kernver}/.config"
    mkdir -p "${pkgdir}/usr/src/linux-${_kernver}/include"
    for i in acpi asm-generic config crypto drm generated linux math-emu \
    media net pcmcia scsi sound trace video xen; do
    cp -a include/${i} "${pkgdir}/usr/src/linux-${_kernver}/include/"
    done
    # copy arch includes for external modules
    mkdir -p "${pkgdir}/usr/src/linux-${_kernver}/arch/x86"
    cp -a arch/x86/include "${pkgdir}/usr/src/linux-${_kernver}/arch/x86/"
    # copy files necessary for later builds, like nvidia and vmware
    cp Module.symvers "${pkgdir}/usr/src/linux-${_kernver}"
    cp -a scripts "${pkgdir}/usr/src/linux-${_kernver}"
    # fix permissions on scripts dir
    chmod og-w -R "${pkgdir}/usr/src/linux-${_kernver}/scripts"
    mkdir -p "${pkgdir}/usr/src/linux-${_kernver}/.tmp_versions"
    mkdir -p "${pkgdir}/usr/src/linux-${_kernver}/arch/${KARCH}/kernel"
    cp arch/${KARCH}/Makefile "${pkgdir}/usr/src/linux-${_kernver}/arch/${KARCH}/"
    if [ "${CARCH}" = "i686" ]; then
    cp arch/${KARCH}/Makefile_32.cpu "${pkgdir}/usr/src/linux-${_kernver}/arch/${KARCH}/"
    fi
    cp arch/${KARCH}/kernel/asm-offsets.s "${pkgdir}/usr/src/linux-${_kernver}/arch/${KARCH}/kernel/"
    # add headers for lirc package
    mkdir -p "${pkgdir}/usr/src/linux-${_kernver}/drivers/media/video"
    cp drivers/media/video/*.h "${pkgdir}/usr/src/linux-${_kernver}/drivers/media/video/"
    for i in bt8xx cpia2 cx25840 cx88 em28xx et61x251 pwc saa7134 sn9c102; do
    mkdir -p "${pkgdir}/usr/src/linux-${_kernver}/drivers/media/video/${i}"
    cp -a drivers/media/video/${i}/*.h "${pkgdir}/usr/src/linux-${_kernver}/drivers/media/video/${i}"
    done
    # add docbook makefile
    install -D -m644 Documentation/DocBook/Makefile \
    "${pkgdir}/usr/src/linux-${_kernver}/Documentation/DocBook/Makefile"
    # add dm headers
    mkdir -p "${pkgdir}/usr/src/linux-${_kernver}/drivers/md"
    cp drivers/md/*.h "${pkgdir}/usr/src/linux-${_kernver}/drivers/md"
    # add inotify.h
    mkdir -p "${pkgdir}/usr/src/linux-${_kernver}/include/linux"
    cp include/linux/inotify.h "${pkgdir}/usr/src/linux-${_kernver}/include/linux/"
    # add wireless headers
    mkdir -p "${pkgdir}/usr/src/linux-${_kernver}/net/mac80211/"
    cp net/mac80211/*.h "${pkgdir}/usr/src/linux-${_kernver}/net/mac80211/"
    # add dvb headers for external modules
    # in reference to:
    # http://bugs.archlinux.org/task/9912
    mkdir -p "${pkgdir}/usr/src/linux-${_kernver}/drivers/media/dvb/dvb-core"
    cp drivers/media/dvb/dvb-core/*.h "${pkgdir}/usr/src/linux-${_kernver}/drivers/media/dvb/dvb-core/"
    # and...
    # http://bugs.archlinux.org/task/11194
    mkdir -p "${pkgdir}/usr/src/linux-${_kernver}/include/config/dvb/"
    cp include/config/dvb/*.h "${pkgdir}/usr/src/linux-${_kernver}/include/config/dvb/"
    # add dvb headers for http://mcentral.de/hg/~mrec/em28xx-new
    # in reference to:
    # http://bugs.archlinux.org/task/13146
    mkdir -p "${pkgdir}/usr/src/linux-${_kernver}/drivers/media/dvb/frontends/"
    cp drivers/media/dvb/frontends/lgdt330x.h "${pkgdir}/usr/src/linux-${_kernver}/drivers/media/dvb/frontends/"
    cp drivers/media/video/msp3400-driver.h "${pkgdir}/usr/src/linux-${_kernver}/drivers/media/dvb/frontends/"
    # add dvb headers
    # in reference to:
    # http://bugs.archlinux.org/task/20402
    mkdir -p "${pkgdir}/usr/src/linux-${_kernver}/drivers/media/dvb/dvb-usb"
    cp drivers/media/dvb/dvb-usb/*.h "${pkgdir}/usr/src/linux-${_kernver}/drivers/media/dvb/dvb-usb/"
    mkdir -p "${pkgdir}/usr/src/linux-${_kernver}/drivers/media/dvb/frontends"
    cp drivers/media/dvb/frontends/*.h "${pkgdir}/usr/src/linux-${_kernver}/drivers/media/dvb/frontends/"
    mkdir -p "${pkgdir}/usr/src/linux-${_kernver}/drivers/media/common/tuners"
    cp drivers/media/common/tuners/*.h "${pkgdir}/usr/src/linux-${_kernver}/drivers/media/common/tuners/"
    # add xfs and shmem for aufs building
    mkdir -p "${pkgdir}/usr/src/linux-${_kernver}/fs/xfs"
    mkdir -p "${pkgdir}/usr/src/linux-${_kernver}/mm"
    cp fs/xfs/xfs_sb.h "${pkgdir}/usr/src/linux-${_kernver}/fs/xfs/xfs_sb.h"
    # copy in Kconfig files
    for i in `find . -name "Kconfig*"`; do
    mkdir -p "${pkgdir}"/usr/src/linux-${_kernver}/`echo ${i} | sed 's|/Kconfig.*||'`
    cp ${i} "${pkgdir}/usr/src/linux-${_kernver}/${i}"
    done
    chown -R root.root "${pkgdir}/usr/src/linux-${_kernver}"
    find "${pkgdir}/usr/src/linux-${_kernver}" -type d -exec chmod 755 {} \;
    # strip scripts directory
    find "${pkgdir}/usr/src/linux-${_kernver}/scripts" -type f -perm -u+w 2>/dev/null | while read binary ; do
    case "$(file -bi "${binary}")" in
    *application/x-sharedlib*) # Libraries (.so)
    /usr/bin/strip ${STRIP_SHARED} "${binary}";;
    *application/x-archive*) # Libraries (.a)
    /usr/bin/strip ${STRIP_STATIC} "${binary}";;
    *application/x-executable*) # Binaries
    /usr/bin/strip ${STRIP_BINARIES} "${binary}";;
    esac
    done
    # remove unneeded architectures
    rm -rf "${pkgdir}"/usr/src/linux-${_kernver}/arch/{alpha,arm,arm26,avr32,blackfin,cris,frv,h8300,ia64,m32r,m68k,m68knommu,mips,microblaze,mn10300,parisc,powerpc,ppc,s390,sh,sh64,sparc,sparc64,um,v850,xtensa}
    package_linux-docs() {
    pkgdesc="Kernel hackers manual - HTML documentation that comes with the Linux kernel."
    provides=('kernel26-docs')
    conflicts=('kernel26-docs')
    replaces=('kernel26-docs')
    cd "${srcdir}/linux-${_basekernel}"
    mkdir -p "${pkgdir}/usr/src/linux-${_kernver}"
    cp -al Documentation "${pkgdir}/usr/src/linux-${_kernver}"
    find "${pkgdir}" -type f -exec chmod 444 {} \;
    find "${pkgdir}" -type d -exec chmod 755 {} \;
    # remove a file already in linux package
    rm -f "${pkgdir}/usr/src/linux-${_kernver}/Documentation/DocBook/Makefile"
    After the compiling is finished:
    sudo pacman -U linux-morrvick-3.1.1-1-x86_64.pkg.tar.xz
    Password:
    resolving dependencies...
    looking for inter-conflicts...
    :: linux-morrvick and linux are in conflict (kernel26). Remove linux? [y/N] n
    error: unresolvable package conflicts detected
    error: failed to prepare transaction (conflicting dependencies)
    :: linux-morrvick and linux are in conflict (kernel26)
    Any thoughts?

  • Fglrx compilation fix for kernel 3.14

    Not sure if this is the proper place to put this, but it seemed reasonable enough.
    After upgrading to kernel 3.14 and trying to reinstall my proprietary graphics drivers, I encountered an error similar to the one mentioned in this post: http://forums.opensuse.org/showthread.p … d-with-ATI
    Digging around the kernel code a little bit, I came up with a temporary solution to get it working. Thought I'd post it in case it helps someone else running Arch on a machine with an ATI card.
    Step 1: change to the source directory
    cd /lib/modules/fglrx/build_mod
    Step 2: edit the trouble line in firegl_public.c
    Change line 1764 from
    return current_euid();
    to read
    return (KCL_TYPE_Uid)(current_euid().val);
    Step 3: compile the module
    sudo ./make.sh
    Step 4: install the module
    sudo cp 2.6.x/fglrx.ko /lib/modules/<your kernel version here>/kernel/drivers/video/
    sudo depmod -a
    Replacing <your kernel version here> with your current kernel version, which you can find using
    uname -a
    Reboot or load the module manually and your should be good to go.

    @electrojustin: The catalyst-test package works with kernel 3.14 all ready. I know because I use it.
    In addition, catalyst was all ready patched to work with kernel 3.14.
    EDIT: I've just had a look at the patch for the catalyst package, and it does what you suggested in the case that the user is using kernel 3.14. I think this can be marked solved all ready, because of Cold's patch.
    Last edited by clfarron4 (2014-04-12 09:14:23)

  • [SOLVED] Uvesafb compiled into the kernel.

    I'm having some trouble getting uvesafb to work...
    As far as I know, compiling it into the kernel is possible, but when I do I can't get it to work the following appears at boot time:
    uvesafb: failed to execute /sbin/v86d
    uvesafb: make sure that the v86d helper is installed and executable
    uvesafb: Getting VBE info block failed (eax=0x4f00, err=-2)
    uvesafb: vbe_init() failed with -22
    uvesafb: probe of uvesafb.0 failed with error -22
    v86d is correctly installed and in place so I don't know why it's finding it. As I have /boot in a separate partition I tried even copying the executable to /, /boot and /boot/grub and changing where to find it in the kernel command line, none of it worked.
    I was able to get it to work compiling it as a module and specifying it in the MODULES array in the kernel (I'm not using initramfs so I can't specify it in the mods array in mkinitcpio.conf), but it started way to late.
    Any suggestion?
    Thank you very much.
    Last edited by MickST (2010-06-03 20:19:34)

    I'm thinking it can not find v86d that early in the boot process, for the simple reason that your root filesystem is not mounted yet.
    Perhaps a way to solve that would be to include the neccessary files to run v86d in the initramfs, but you are not using initramfs. And I do not know of another easy way to include the files that quick in the boot process.
    But I am curious about something, why does uvesafb start "way too late" for you? You want to be able to read your kernel messages roll by in the full resolution of your screen? Want to get a fancy bootscreen using a splash of some sort? Another reason?
    Last edited by Ultraman (2010-06-03 16:25:16)

  • [solved] Compiling A Custom Kernel W/ Same Config

    I apologize in advance if this is repetitive but i am just a little confused with a few questions.
    What i want to do is be able to pretty much just have the ability to add a module or compile somthing on top of the default linux
    kernel. I guess the only way to do that is to recompile a linux kernel with this guide:
    https://wiki.archlinux.org/index.php/Ke … ild_System
    My questions:
    In the guide it says to change PKGBUILD and change:
    # pkgname=linux-custom       # Build kernel with a different name
    to
    pkgname=linux-test
    I understand that. it also says to disable conflicts if you want two kernels.
    is that just comenting "provides" , "conflicts" and "replaces"
    like:
    #next lines give you problems with nvidia drivers which depend on kernel
    #provides=('kernel26')
    #conflicts=('kernel26')
    #replaces=('kernel26'
    Also when i select or uncomment menuconfig and lets say not change anything at all is that going to be the same configuration as it would be if i were to install the kernel with pacman. It should be the same thing i have right now? right?
    So i can say add framebuffer support or something like that and compile and install and have the exact same kernel now plus FB support.
    Thanks,
    Paul
    Last edited by paulb787 (2012-06-22 05:50:35)

    1.
    What i want to do is be able to pretty much just have the ability to add a module or compile somthing on top of the default linux kernel.
    You would need linux-headers to do that like this (more or less):
    cd your-src/kernel
    make SYSSRC=/lib/modules/${current-kernel-version}/build module
    If you want to customize your kernel further, change its config options, modify default features, etc., then you need to recompile it entirely as described in the Wiki.
    2.
    is that just comenting "provides" , "conflicts" and "replaces"
    Yes. You also need to create a custom linux-${your-custom-kernel-name}.preset in order to generate initramfs. Of course, you can as well use the default name and change the settings in the config file (via menuconfig, nconfig or whatever tool you choose the achieve this). Then nothing has to be changed as all the add-ons will follow the naming convention reserved for the default kernel.
    3.
    Also when i select or uncomment menuconfig and lets say not change anything at all is that going to be the same configuration as it would be if i were to install the kernel with pacman?
    Yes.
    4.
    So i can say add framebuffer support or something like that and compile and install and have the exact same kernel now plus FB support.
    Basically yes, though I'm wondering for which video board you need extra FB support...
    Last edited by bohoomil (2012-06-20 00:41:15)

Maybe you are looking for

  • [SOLVED]pacman fails to install mtpaint

    [me@mypc ~]$ sudo pacman -S mtpaint resolving dependencies... looking for inter-conflicts... Targets (3): giflib-4.1.6-4 openjpeg-1.3-3 mtpaint-3.31-4 Total Download Size: 0.86 MB Total Installed Size: 2.61 MB Proceed with installation? [Y/n] y :: Re

  • Import package question

    I am currently trying to import com.sun.tools.jconsole.JConsolePlugin so that I can create a plugin for the JConsole. My problem is that I don't have com.sun.tools package and I'm not seeing some obvious place where I can get it. Can someone point me

  • Cannot drop object?

    I am simply following the CBT nuggets fundamentals course and did the following: create sequence seq_int_by1 INCREMENT BY 1 START WITH 1 MINVALUE 1; create sequence SEQ_testsequence increment by 100 start with 1000 maxvalue 100000 minvalue 1000 cache

  • Applying Fusion middleware patches in 12.2

    Hai all, Am using the note Oracle E-Business Suite Release 12.2: Consolidated List of Patches and Technology Bug Fixes (Doc ID 1594274.1) Now all the patches are being applied in fs1 , do I have to apply simultaneously  (manually in fs2 also ? Thanks

  • High Level Complaints contact number?

    Hi  I've got an issue that is turning into Groundhog Day which is covered in a different thread (service getting provisioned and that BT cancelling the order shortly afterwards, this is happened three times in two months now).  I'm not getting any re