[Solved] Problems compiling a kernel on Archlinux

Hi all, some days ago I wanted to compile a kernel on my system, and everything was fine but I have a simple problem.
Compile the kernel in the traditional manner, but no logo create the ramdisk image.
https://wiki.archlinux.org/index.php/Ke … raditional
Example:
cp -v arch/x86/boot/bzImage /boot/vmlinuz-NewKernel
And:
mkinitcpio -k NewKernel -g /boot/initramfs-NewKernel.img
But I get this error:
Error: unable to locate module directory for NewKernel.
What am I doing wrong?
PD:Sorry for my English
Last edited by Linpandro (2012-10-03 13:50:43)

This:
mkinitcpio -k NewKernel -g /boot/initramfs-NewKernel.img
Should be this:
mkinitcpio -k 3.x.x-RCn-NewKernel -g /boot/initramfs-NewKernel.img
To clarify, the wiki tells you to run this:
# mkinitcpio -k FullKernelName -g /boot/initramfs-YourKernelName.img
If you need any modules loaded in order to mount the root filesystem, build a ramdisk (most users need this). The -k parameter accepts the kernel version and appended string you set in menuconfig and is used to locate the corresponding modules directory in '/usr/lib/modules':
If you used the sources for, say, 3.5.4, "FullKernelName" would be 3.5.4-NewKernel.
If you're not sure about what the "FullKernelName" should be, simply check which directory was created after running modules_install
ls -l /lib/modules
This should show you something like this:
[stefan@archsteef scrub]$ ls -l /lib/modules/
total 8
drwxr-xr-x 3 root root 4096 Sep 30 01:30 3.5.4-1-ARCH
drwxr-xr-x 2 root root 4096 Sep 30 01:30 extramodules-3.5-ARCH
drwxr-xr-x 2 root root 4096 Oct 1 03:25 3.5.4-NewKernel
The directory name is the full name of your kernel and can be used after the -k flag.
p.s. this is all assuming that you used make menuconfig to set the local version name to "NewKernel"
Last edited by stefanwilkens (2012-10-03 08:15:26)

Similar Messages

  • [solved]Problem compiling alsa from source

    I'm trying to install alsa-driver-1.0.18a from source because I need to compile it with snd-virtuoso.  So I run "./configure --with-cards=virtuoso --with-sequencer=yes" then when I run "make" I get this at the end of it.
    make -C /lib/modules/2.6.27-ARCH/build SUBDIRS=/usr/src/alsa/alsa-driver-1.0.18a CPP="gcc -E" CC="gcc" modules
    make[1]: Entering directory `/usr/src/linux-2.6.27-ARCH'
    CC [M] /usr/src/alsa/alsa-driver-1.0.18a/acore/memory_wrapper.o
    In file included from /usr/src/alsa/alsa-driver-1.0.18a/acore/memory_wrapper.c:25:
    /usr/src/alsa/alsa-driver-1.0.18a/include/adriver.h:282:1: warning: "GFP_DMA32" redefined
    In file included from include/linux/kmod.h:22,
    from include/linux/module.h:13,
    from /usr/src/alsa/alsa-driver-1.0.18a/include/adriver.h:57,
    from /usr/src/alsa/alsa-driver-1.0.18a/acore/memory_wrapper.c:25:
    include/linux/gfp.h:105:1: warning: this is the location of the previous definition
    In file included from /usr/src/alsa/alsa-driver-1.0.18a/acore/memory_wrapper.c:25:
    /usr/src/alsa/alsa-driver-1.0.18a/include/adriver.h:831: error: static declaration of 'jiffies_to_msecs' follows non-static declaration
    include/linux/jiffies.h:286: error: previous declaration of 'jiffies_to_msecs' was here
    /usr/src/alsa/alsa-driver-1.0.18a/include/adriver.h:850: error: static declaration of 'msecs_to_jiffies' follows non-static declaration
    include/linux/jiffies.h:288: error: previous declaration of 'msecs_to_jiffies' was here
    In file included from /usr/src/alsa/alsa-driver-1.0.18a/include/adriver.h:948,
    from /usr/src/alsa/alsa-driver-1.0.18a/acore/memory_wrapper.c:25:
    include/linux/pci.h:627: error: expected identifier or '(' before numeric constant
    In file included from include/asm/pci.h:4,
    from include/linux/pci.h:989,
    from /usr/src/alsa/alsa-driver-1.0.18a/include/adriver.h:948,
    from /usr/src/alsa/alsa-driver-1.0.18a/acore/memory_wrapper.c:25:
    include/linux/mm.h:261: error: conflicting types for 'snd_compat_vmalloc_to_page'
    /usr/src/alsa/alsa-driver-1.0.18a/include/adriver.h:752: error: previous declaration of 'snd_compat_vmalloc_to_page' was here
    In file included from /usr/src/alsa/alsa-driver-1.0.18a/acore/memory_wrapper.c:25:
    /usr/src/alsa/alsa-driver-1.0.18a/include/adriver.h: In function 'snd_pci_orig_save_state':
    /usr/src/alsa/alsa-driver-1.0.18a/include/adriver.h:1197: error: too many arguments to function 'pci_save_state'
    /usr/src/alsa/alsa-driver-1.0.18a/include/adriver.h: In function 'snd_pci_orig_restore_state':
    /usr/src/alsa/alsa-driver-1.0.18a/include/adriver.h:1201: error: too many arguments to function 'pci_restore_state'
    In file included from /usr/src/alsa/alsa-driver-1.0.18a/acore/memory_wrapper.c:25:
    /usr/src/alsa/alsa-driver-1.0.18a/include/adriver.h:1598:1: warning: "page_to_pfn" redefined
    In file included from include/asm/page.h:196,
    from include/asm/pda.h:8,
    from include/asm/current.h:19,
    from include/asm/processor.h:15,
    from include/linux/prefetch.h:14,
    from include/linux/list.h:6,
    from include/linux/module.h:9,
    from /usr/src/alsa/alsa-driver-1.0.18a/include/adriver.h:57,
    from /usr/src/alsa/alsa-driver-1.0.18a/acore/memory_wrapper.c:25:
    include/asm-generic/memory_model.h:78:1: warning: this is the location of the previous definition
    /usr/src/alsa/alsa-driver-1.0.18a/acore/memory_wrapper.c: In function 'snd_compat_vmalloc_to_page':
    /usr/src/alsa/alsa-driver-1.0.18a/acore/memory_wrapper.c:44: error: implicit declaration of function 'VMALLOC_VMADDR'
    /usr/src/alsa/alsa-driver-1.0.18a/acore/memory_wrapper.c:49: error: incompatible type for argument 1 of 'pud_val'
    /usr/src/alsa/alsa-driver-1.0.18a/acore/memory_wrapper.c:50: error: implicit declaration of function 'pte_offset'
    /usr/src/alsa/alsa-driver-1.0.18a/acore/memory_wrapper.c:50: warning: assignment makes pointer from integer without a cast
    make[3]: *** [/usr/src/alsa/alsa-driver-1.0.18a/acore/memory_wrapper.o] Error 1
    make[2]: *** [/usr/src/alsa/alsa-driver-1.0.18a/acore] Error 2
    make[1]: *** [_module_/usr/src/alsa/alsa-driver-1.0.18a] Error 2
    make[1]: Leaving directory `/usr/src/linux-2.6.27-ARCH'
    make: *** [compile] Error 2
    edit: I tried compiling it on another computer and it was able too...not sure why mine wont.  Although I do seem to remember possibly forgetting to uninstall it before making it again (after kernel upgrade)...I've tried multiple times to compile so far.  Is there someway I can get a list of things to delete to manually remove all remnants of a previous install of alsa-driver?
    Last edited by Gauvenator (2008-12-13 19:48:11)

    Ok I ended up compiling the kernel from source for something else, so I tried compiling the alsa driver from source and it worked...maybe something was leftover in the previous kernel source directory that was causing problems.

  • [SOLVED] Problem compiling kernel for an Arch install on USB pendrive

    I've installed Arch linux to a USB pendrive and I'm building a kernel for my specific hardware (Acer Aspire One) so as there is no kernel26.img file needed. 
    I've used gothicknight's custom kernel but it doesn't work for me as it doesn't recognise my USB stick (/dev/sdb).  Instead, it just recognises the SSD (/dev/sda).  I believe the standard Arch kernel uses a "hook" called "usb" in order to work from a USB stick - at least that's how I've got the current (default) Archlinux kernel working.
    I'm not that skilled at linux and am still quite new to kernel compilation (I've done it once or twice before and, yes, I've read the ArchWiki articles - both of them).  Can anyone tell me what I should do to get things working on a USB stick install?
    Kind regards
    Last edited by Shagbag (2008-09-30 20:27:49)

    Solved it.  I didn't need to recompile.  I just needed to add 'rootdelay=5' as a kernel boot parameter.

  • [SOLVED] Problem compiling Suitesparse: hidden symbol `__powidf2'

    Hi guys, hope this is the right section to post this problem. I'm trying to compile (and install) Suitesparse but everytime i obtain this strange error i have never seen before...any idea to solve it?Thanks
    cholmod_super_numeric.c:(.text+0x117d): undefined reference to `dsyrk_'
    cholmod_super_numeric.c:(.text+0x125c): undefined reference to `dgemm_'
    cholmod_super_numeric.c:(.text+0x184d): undefined reference to `dtrsm_'
    cholmod_super_numeric.c:(.text+0x2401): undefined reference to `zherk_'
    cholmod_super_numeric.c:(.text+0x24e5): undefined reference to `zgemm_'
    cholmod_super_numeric.c:(.text+0x2a08): undefined reference to `ztrsm_'
    cholmod_super_numeric.c:(.text+0x35c1): undefined reference to `zherk_'
    cholmod_super_numeric.c:(.text+0x36a5): undefined reference to `zgemm_'
    cholmod_super_numeric.c:(.text+0x3c17): undefined reference to `ztrsm_'
    ../Lib/libcholmod.a(cholmod_super_solve.o): In function `cholmod_super_ltsolve':
    cholmod_super_solve.c:(.text+0x715): undefined reference to `zgemm_'
    cholmod_super_solve.c:(.text+0x7b2): undefined reference to `ztrsm_'
    cholmod_super_solve.c:(.text+0xa37): undefined reference to `zgemv_'
    cholmod_super_solve.c:(.text+0xaa1): undefined reference to `ztrsv_'
    cholmod_super_solve.c:(.text+0xde7): undefined reference to `dgemm_'
    cholmod_super_solve.c:(.text+0xe7b): undefined reference to `dtrsm_'
    cholmod_super_solve.c:(.text+0x10c8): undefined reference to `dgemv_'
    cholmod_super_solve.c:(.text+0x112c): undefined reference to `dtrsv_'
    ../Lib/libcholmod.a(cholmod_super_solve.o): In function `cholmod_super_lsolve':
    cholmod_super_solve.c:(.text+0x182c): undefined reference to `ztrsm_'
    cholmod_super_solve.c:(.text+0x18fc): undefined reference to `zgemm_'
    cholmod_super_solve.c:(.text+0x1a46): undefined reference to `ztrsm_'
    cholmod_super_solve.c:(.text+0x1bea): undefined reference to `ztrsv_'
    cholmod_super_solve.c:(.text+0x1c94): undefined reference to `zgemv_'
    cholmod_super_solve.c:(.text+0x1fb5): undefined reference to `dtrsm_'
    cholmod_super_solve.c:(.text+0x2080): undefined reference to `dgemm_'
    cholmod_super_solve.c:(.text+0x219b): undefined reference to `dtrsm_'
    cholmod_super_solve.c:(.text+0x231f): undefined reference to `dtrsv_'
    cholmod_super_solve.c:(.text+0x23c6): undefined reference to `dgemv_'
    /usr/bin/ld: cholmod_demo: hidden symbol `__powidf2' in /usr/lib/gcc/x86_64-unknown-linux-gnu/4.3.2/libgcc.a(_powidf2.o) is referenced by DSO
    /usr/bin/ld: final link failed: Nonrepresentable section on output
    collect2: ld returned 1 exit status
    make[1]: *** [cholmod_demo] Error 1
    Last edited by Demind (2008-09-15 11:09:07)

    Garns wrote:Does your atlas package contain libblas.a or does the blas library have another name? I scanned the atlas makefile and I couldn't find a reference to libblas.a, only libf77blas.a and libcblas.a. Are the libs installed to /usr/libs/ or to some subdir? If one of this is the case you might have to edit UFconfig/UFconfig.mk accordingly.
    Sorry this problem is so frustrating that i have pasted the wrong error...actually i had a UFconfig/UFconfig.mk edited and that gave me the same problem, I don't have libblas.a on my system but the reason is that this is substitued by libatlas.a!
    I paste here the "final" result:
    make[2]: Leaving directory `/home/marco/Desktop/SuiteSparse/CCOLAMD'
    gcc -O3 -fexceptions -m64 -o cholmod_demo -I../Include -I../../UFconfig cholmod_demo.c ../Lib/libcholmod.a ../../AMD/Lib/libamd.a ../../COLAMD/Lib/libcolamd.a ../../CCOLAMD/Lib/libccolamd.a ../../CAMD/Lib/libcamd.a ../../metis-4.0/libmetis.a -llapack -lgfortran -lgfortran -lpthread -Lusr/lib -lf77blas -latlas -lm
    /usr/bin/ld: cholmod_demo: hidden symbol `__powidf2' in /usr/lib/gcc/x86_64-unknown-linux-gnu/4.3.2/libgcc.a(_powidf2.o) is referenced by DSO
    /usr/bin/ld: final link failed: Nonrepresentable section on output
    collect2: ld returned 1 exit status
    make[1]: *** [cholmod_demo] Error 1
    Obviously the "undefined reference" statements are gone but the main problem, the hidden symbol, is always there...and now i'm sure this is the error i hope to solve, the first one (and i apologize for that) was a build with wrong flag...
    And when i wrote about a possible gcc version problem was because this line says:
    /usr/bin/ld: cholmod_demo: hidden symbol `__powidf2' in /usr/lib/gcc/x86_64-unknown-linux-gnu/4.3.2/libgcc.a(_powidf2.o) is referenced by DSO
    what do you think about it?
    p.s. i can compile UMFPACK without problems...the whole Suite on the contrary gives me this

  • [solved] Problems compiling hydrogen

    I'm trying to compile hydrogen version 0.9.4, so I can use Qt4. I made a PKGBUILD by editing the PKGBUILD of ABS and following the instructions of this page
    It compiles everything ok, but the problem is when running 'make install', I guess. I'm compiling it using makepkg, so I don't know why I'm having problems with permissions denied. These are the relevant error messages:
    cd gui/ && make -f Makefile install
    make[1]: Entering directory `/home/andre/tmp/hydrogen/src/hydrogen-build/gui'
    install -m 755 -p "../hydrogen" "/usr/bin/hydrogen"
    install: cannot create regular file `/usr/bin/hydrogen': Permission denied
    make[1]: [install_target] Error 1 (ignored)
    strip "/usr/bin/hydrogen"
    strip: '/usr/bin/hydrogen': No such file
    make[1]: [install_target] Error 1 (ignored)
    mkdir: cannot create directory `/usr//share/hydrogen': Permission denied
    make[1]: *** [install_documentation] Error 1
    make[1]: Leaving directory `/home/andre/tmp/hydrogen/src/hydrogen-build/gui'
    make: *** [sub-gui-install_subtargets] Error 2
    Even with the two errors, it finishes making the package, but it only has the /usr/share dir in it, there's no /usr/lib or /usr/bin.
    Here's the PKGBUILD:
    pkgname=hydrogen-qt4
    pkgver=248
    pkgrel=1
    pkgdesc="An advanced drum machine/pattern editor with midi support for GNU/Linux"
    url="http://www.hydrogen-music.org/"
    arch=(i686 x86_64)
    license=('GPL')
    depends=('qt' 'liblrdf' 'jack-audio-connection-kit>=0.102.20-2')
    makedepends=('subversion' 'lash' 'libtar')
    provides=('hydrogen')
    conflicts=('hydrogen')
    install=hydrogen.install
    source=(hydrogen.desktop)
    md5sums=('8d6eacef58aa22cdba97485f9bdbb4b3')
    options=('!makeflags')
    _svntrunk=http://hydrogen-music.org/svn/trunk
    _svnmod=hydrogen
    build() {
    cd ${startdir}/src
    msg "Connecting to $_svnmod SVN server...."
    svn co $_svntrunk $_svnmod
    [ -d ./$_svnmod-build ] && rm -fr ./$_svnmod-build
    cp -r ./$_svnmod ./$_svnmod-build
    cd ./$_svnmod-build
    msg "SVN checkout done or server timeout"
    msg "Starting make..."
    prefix=/usr/ ./configure || return 1
    make || return 1
    make DESTDIR=${startdir}/pkg install
    install -D -m644 ${startdir}/src/hydrogen.desktop \
    ${startdir}/pkg/usr/share/applications/hydrogen.desktop
    mkdir ${startdir}/pkg/usr/share/pixmaps
    cd ${startdir}/pkg/usr/share/pixmaps
    ln -s ../hydrogen/data/img/gray/icon.svg ./hydrogen.svg
    ln -s ../hydrogen/data/img/gray/icon64.png ./hydrogen.png
    The line "prefix=/usr/ ./configure" is correct, if you use --prefix=/usr/ after ./configure, configure will ignore it.
    What is wrong with it?
    Thanks
    Last edited by andre.ramaciotti (2008-07-17 00:31:10)

    you should keep:
    prefix=/usr/ ./configure
    because path given to the configure script can be hard-coded in the apps.
    instead use:
    make prefix=${startdir}/usr/pkg  install
    It's strange that the usual ./configure --prefix=/usr doesn't work. I haven't checked the sources BTW.

  • [solved] Problem compiling ConTeXt code

    I'd like to start learning ConTeXt and I've just tried to compile a simple hello world:
    \starttext
    Hello world.
    \stoptext
    when compiling with texexec I get this output:
    mtxrun | kpse fallback with progname 'context' initialized in 0.02 seconds/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:45:in `require': /usr/share/texmf-dist/scripts/context/ruby/base/switch.rb:501: invalid multibyte escape: /\xFF/ (SyntaxError)
    from /usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:45:in `require'
    from /usr/share/texmf-dist/scripts/context/ruby/texexec.rb:11:in `<main>'
    I have ruby and all texlive packags installed except texlive-lang*. Searching for an answer I found an old discussion on the forum (2008) where it was suggested to run
    luatools --generate
    before using texexec, but this lead me to another error:
    mtxrun | unknown script 'base.lua' or 'mtx-base.lua'
    Am I missing some package-stuff necessary to compile ConTeXt code?
    edit: looks like I was reading an obsolete guide. It is now reccomended to compile code with "context <filename>", which works fine.
    Last edited by Box0 (2013-04-15 09:18:52)

    Hi there,
    I tried
    g++ mclient.cpp -llibboost_filesystem -llibboost_program_options -llibboost_system -llibboost_thread -o tutorial
    and received
    /usr/bin/ld: cannot find -llibboost_filesystem
    /usr/bin/ld: cannot find -llibboost_program_options
    /usr/bin/ld: cannot find -llibboost_system
    /usr/bin/ld: cannot find -llibboost_thread
    collect2: error: ld returned 1 exit status

  • [Solved]Error compiling kernel from abs

    Hello Everyone,
    I've hit a wall trying to compile the kernel from the abs. I get this error message:
    patching file fs/fat/inode.c
    Hunk #1 succeeded at 800 (offset 74 lines).
    HOSTCC scripts/basic/fixdep
    /bin/sh: scripts/basic/fixdep: cannot execute binary file
    make[2]: *** [scripts/basic/fixdep] Error 126
    make[1]: *** [scripts_basic] Error 2
    SYSHDR arch/x86/syscalls/../include/generated/asm/unistd_32.h
    SYSHDR arch/x86/syscalls/../include/generated/asm/unistd_64.h
    make: *** No rule to make target `include/config/auto.conf', needed by `include/config/kernel.release'. Stop.
    make: *** Waiting for unfinished jobs....
    HOSTCC scripts/basic/fixdep
    SYSHDR arch/x86/syscalls/../include/generated/asm/unistd_x32.h
    SYSTBL arch/x86/syscalls/../include/generated/asm/syscalls_32.h
    /bin/sh: scripts/basic/fixdep: cannot execute binary file
    make[1]: *** [scripts/basic/fixdep] Error 126
    make: *** [scripts_basic] Error 2
    ==> ERROR: A failure occurred in build().
    Aborting...
    While trying to figure this out I came across this post: https://bbs.archlinux.org/viewtopic.php?id=99089 and have tried the solutions presented. I did end up having to change my fstab to include defaults,
    /dev/sda3 /home ext4 defaults,exec,rw,relatime,data=ordered 0 2
    and the permissions on scripts/basic/fixdep are: -rwxr-xr-x which i think it correct.
    Unfortunately, the problem still exists and I don't know how to continue trouble shooting. Can someone point me in a direction to troubleshoot this?
    Last edited by magyarm (2012-12-20 01:55:00)

    magyarm wrote:So now, I need to figure out a good way to handle multiple compilers on my system to prevent this from happening again. If anyone has any tips I would love to hear them.
    Set up a file that you source from bash to prepend the cross compiler to your path, that would only be active for that shell, and when you're done just close it. Means you only activate the cross compiler when you need it.

  • [Solved] Error compiling kernel 2.6.36.2 patched with MOSIX

    Hi, I'm a new user in this forum!
    I'm trying to compile manually the kernel version with MOSIX-2.29.0.1 for computer clustering. But When I try to compile it with make command there is an error:
    In file included from arch/x86/kernel/signal.c:17:0:
    include/linux/tracehook.h: In function ‘tracehook_unsafe_exec’:
    include/linux/tracehook.h:164:40: error: ‘struct task_struct’ has no member named ‘mflags’
    arch/x86/kernel/signal.c: In function ‘do_notify_resume’:
    arch/x86/kernel/signal.c:884:44: error: ‘struct task_struct’ has no member named ‘parent_waiting’
    make[2]: *** [arch/x86/kernel/signal.o] Error 1
    make[1]: *** [arch/x86/kernel] Error 2
    make: *** [arch/x86] Error 2
    I have launched make menuconfig and I have configured the kernel in this way:
    Configure the following option:
          CONFIG_FUSE_FS
            File systems  --->  FUSE (Filesystem in Userspace) support
          CONFIG_SYSVIPC
            General setup  --->  System V IPC
       But make sure that the following is NOT CONFIGURED:
       CONFIG_HEADERS_CHECK"
            'Kernel hacking' ---> 'Run 'make headers_check' when building vmlinux'
    What is the problem?
    Last edited by andychaser (2011-02-17 12:37:50)

    I've solved the issue, infact there was a problem with the patch. Now I am able to compile the kernel.
    Thanks anyway!

  • [SOLVED] error compiling kernel 2.6.29

    Hi,
    Due to having the DVD-S card mentioned here
    http://www.linuxtv.org/pipermail/linux- … 23265.html
    I am trying to compile kernel 2.6.29.6 with the above mentioned patch but get an error:
    include/sound/soc-dai.h: At top level:
    include/sound/soc-dai.h:224:25: error: duplicate member ‘codec’
    sound/soc/soc-core.c: In function ‘snd_soc_init_card’:
    sound/soc/soc-core.c:1360:18: warning: variable ‘ac97’ set but not used
    [-Wunused-but-set-variable]
    make[2]: *** [sound/soc/soc-core.o] Error 1
    make[1]: *** [sound/soc] Error 2
    make: *** [sound] Error 2
    bash: vim include/sound/soc-dai.h
            /* DAI runtime info */
            struct snd_pcm_runtime *runtime;
            struct snd_soc_codec *codec;
            unsigned int active;
            unsigned char pop_wait:1;
            void *dma_data;
            /* DAI private data */
            void *private_data;
            /* parent codec/platform */
            union {
                    struct snd_soc_codec *codec;
                    struct snd_soc_platform *platform;
    Note:
    I found a solution:
    http://mailman.alsa-project.org/piperma … 16949.html
    Last edited by casacristo (2011-10-19 07:46:01)

    I've solved the issue, infact there was a problem with the patch. Now I am able to compile the kernel.
    Thanks anyway!

  • Problems compiling Zaptel package [SOLVED-ISH]

    Hey guys, I'm on an Arch64 system and I'm having problems compiling Zaptel (a dependancy for Asterisk).
    Here's the pastebin of the errors I get from the Zaptel makefile: http://pastebin.com/776475
    Here's my analysis so far:
    There's a line in the Makefile for the zaptel driver that goes like this:
    make -C /lib/modules/2.6.17-ARCH/build/ SUBDIRS=/home/woogie/zaptel/src/zaptel-1.2.8 modules
    This line activates the kernel's makefile in order to build modules, but specifies that the source directory for zaptel should be included in the make process.
    Then things go down the proverbial drain - linux/err_kernel_only.h gets included in the build process, which is designed to do one thing only - stop the build process. So I'm not entirely too sure what's going on here. Is there something misconfigured on my system, or is the Zaptel build system flawed somehow, such that I need to compensate for it?

    Further information:
    I've manually run the problematic make command from /lib/modules/2.6.17-ARCH/build on my own. After reading the kernel makefile documentation, I've learned of the V=1 flag to show me exactly what's going on. The failing command is this one:
    gcc -Wp,-MD,/home/cestus/zaptel/src/zaptel-1.2.8/.zaptel.o.d -nostdinc -isystem /usr/lib/gcc/x86_64-unknown-linux-gnu/4.1.1/include -D__
    KERNEL__ -Iinclude -include include/linux/autoconf.h -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -O2
    -fomit-frame-pointer -m64 -mno-red-zone -mcmodel=kernel -pipe -fno-reorder-blocks -Wno-sign-compare -fno-asynchronous-unwind-tables -fun
    it-at-a-time -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -Wdeclaration-after-statement -Wno-pointer-sign -I. -Iinclude -O4 -g -Wall -DBUILDING_T
    ONEZONE -m64 -DSTANDALONE_ZAPATA -DZAPTEL_CONFIG="/etc/zaptel.conf" -DHOTPLUG_FIRMWARE -I/home/cestus/zaptel/src/zaptel-1.2.8//include
    -I/home/cestus/zaptel/src/zaptel-1.2.8//include/oct6100api -DMODULE -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(zaptel)" -D"KBUIL
    D_MODNAME=KBUILD_STR(zaptel)" -c -o /home/cestus/zaptel/src/zaptel-1.2.8/zaptel.o /home/cestus/zaptel/src/zaptel-1.2.8/zaptel.c
    I've figured out that the bit which causes the failure is "-include include/linux/autoconf.h", because autoconf.h just includes the "err_kernel_only" header automatically, which then slays the build process. And I've also discovered that the Zaptel devs are uber-leet. They've found the magical -O4 level in gcc. You know, the one above 3, where the supported optimization levels in gcc are -O, -Os, -O2 and -O3 

  • [SOLVED] Can't compile any kernels or modules

    I can't compile the kernel, or any kernel modules. I tried the [core] kernel from ABS and the linux-ck kernel from AUR. I also tried to build vhba and nvidia modules.
    I tried the standard cflags and many others.
    All kernel compiles fail (immediately) with:
    scripts/mod/empty.c:1:0: error: code model kernel does not support PIC mode
    /* empty file to figure out endianness / word size */
    ^
    edward_81 had the same problem, with a default makepkg.conf and linux-mainline, which was never resolved.
    I don't know why this file is being compiled in PIC mode. I have not explicitly enabled PIC anywhere I know of. I checked everywhere I know to look.
    Last edited by quequotion (2015-02-04 15:46:10)

    graysky wrote:Try building one of them in a clean chroot.
    Will try.
    Finally got this working:
    Please add V=1 to the make command on line 89 and rebuild with MAKEFLAGS="-j1" to get verbose output.
    make -f ./scripts/Makefile.build obj=scripts/genksyms
    [...snip...]
    gcc -Wp,-MD,scripts/mod/.empty.o.d -nostdinc -isystem /usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.2/include -I./arch/x86/include -Iarch/x86/include/generated -Iinclude -I./arch/x86/include/uapi -Iarch/x86/include/generated/uapi -I./include/uapi -Iinclude/generated/uapi -include ./include/linux/kconfig.h -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -m64 -mno-80387 -mno-fp-ret-in-387 -march=native -mno-red-zone -mcmodel=kernel -funit-at-a-time -maccumulate-outgoing-args -DCONFIG_X86_X32_ABI -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_FXSAVEQ=1 -DCONFIG_AS_CRC32=1 -DCONFIG_AS_AVX=1 -DCONFIG_AS_AVX2=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -fno-delete-null-pointer-checks -O2 --param=allow-store-data-races=0 -Wframe-larger-than=2048 -fstack-protector-strong -Wno-unused-but-set-variable -fno-var-tracking-assignments -pg -mfentry -DCC_USING_FENTRY -fno-inline-functions-called-once -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -Werror=date-time -DCC_HAVE_ASM_GOTO -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(empty)" -D"KBUILD_MODNAME=KBUILD_STR(empty)" -c -o scripts/mod/.tmp_empty.o scripts/mod/empty.c
    scripts/mod/empty.c:1:0: error: code model kernel does not support PIC mode
    /* empty file to figure out endianness / word size */
    ^
    scripts/Makefile.build:257: recipe for target 'scripts/mod/empty.o' failed
    Last edited by quequotion (2015-02-04 13:40:15)

  • [SOLVED-in-PART] recompiling kernel images, boot diferent from chroot

    Hi, I got into an dead end. Two days ago I was trying to solve some small annoying problems (ethernet driver, dkms not compiling automatically and difference in time hwclock and software clock) with my recent arch installation. I started with the time difference problem, for which I followed some solutions which I found in the internet, but all for no avail. So I postponed this for later and started to tackle the ethernet driver problem (Atheros AR8161) [https://wiki.archlinux.org/index.php/Ne … ros_AR8161]. I followed all described steps, I also did  the mentioned hack. After all, I turned my note at work off and at home on and surprise it found the GRUB menu, I started the option for the system, the disk was checked but, no system came up. It even messed up my window8 system as well. But that is now up and working. After windows came back GRUB was loading and I can start it from GRUB, but not Arch.
    I looked at the grub menu and as far as I could see and understand everything was pointing and the right direction. So I supposed that during the network driver compilation and module load, something went wrong with the images or images source (if they are important for booting). So reading around I got pointed to how to rebuild the kernel images (http://riskofruin.markmccracken.net/201 … image.html). I know the blog title is kreepy... but the procedure sounds very logic, correct and quite strait forward. So I got the latest Arch image, put it on an usb stick and chroot into my installed system.
    When I started the /sbin/depmod I immediately got an error saying that two files where missing for the kernels 3.7.9-2-ARCH. Well as far as I remember my installed system has the latest kernel (3.7.10-1-ARCH). So I though to update my pendrive system and so restart an both kernels would be equal. After restarting, I repeated al chroot protocol and then I saw that I still had the wrong kernel images. I suspect why, but I am not sure, may be the system is all memory loaded when it is booted up? Also, if I saw right, even the images are quite different (pendrive and harddrive). I surfed around to see how can I, in an chroot environment, where the hardrive installed system has an different kernel from the booted system, generate new kernel images for the hardrive system, soin a hope that  I can initialize my hardrive installed system? Is there someone that could guide me through this?
    PS.: Remember I suppose the problem is in the kernel, I do not not how to check for sure.
    Last edited by camarao (2013-03-10 03:10:56)

    Hi Trilby,
    No, just the initramfs. Because I think when I tryed to install my Atheros AR8161 drive I guess that something went wrong with the image or it could be something else.
    Do you think the vmlinuz-linux should also be reconstructed?
    Yesterday at night I found in the internet, someone using the "-k" option, of mkinitcpio, and pointing to the /boot/vmlinuz.linux directory. So if I understood well mkinitcpio using the options "-k", "-c" and "-g" you can point where to put the reconstructed images, vmlinuz and the initramfs, according to the "-c" pointed mkinitcpio.conf. This would allow me to reconstruct both images for the broken system which are from a different kernel version, than the one used to boot up and repair the broken system.
    Two last questions:
    1. Is it necessary to run /sbin/depmod before reconstructiong the images, as mentioned in the link (http://riskofruin.markmccracken.net/201 … image.html)?
    2. Will the two new images be automatically replaced in /boot?
    Sorry for asking this, but IT is just an hobby for me, and my IT knowledge is limited to what I read and understand. I like adventures and sometime dangerous one as well, I learn a lot. But if sometimes I can get a small help I like.
    Well thanks for everything

  • [SOLVED] Black screen after kernel boot after pacman -Syu

    Hi, after full system upgrade with pacman -Syu, I get after the kernel boot black screen and everything is freezing. Then need to manually shut down the power button!
    Normally when my system starts up after the kernel boot I get straight to the command line terminal login.
    Can anybody help me how to fix this? Any clues? Any advice is welcome!
    The problem is solved by downgrading to kernel 3.6.11.-1
    Many thanks for the help from the people on #archlinux !
    Last edited by OpenEye (2013-01-29 05:14:04)

    jasonwryan wrote:
    Please stop bumping your thread: use the edit button
    https://wiki.archlinux.org/index.php/Fo … te#Bumping
    What have you done about the errors being printed to your logs? You could start by fixing the network error and the broken udev rule...
    Are you still using intiscripts? They are no longer supported: https://www.archlinux.org/news/end-of-i … s-support/
    # edit: not a pacman issue, moving to Newbie Corner
    I have searched for many hours and days for solutions on the internet and forums, tried some things, but with no results! I don't know how to fix the errors! Do you know how to fix that? I'm a total n00b! I'm doing my best as I can! Need help, thanks!

  • [SOLVED] Cannot compile dvb drivers.

    Hi,
    I'm setting up a htpc media center based on arch with mythtv and xbmc. I've installed the base and base-devel packages and I need to compile the tbs-dvb-drivers to make my TBS 6280 DVB-T2 card work.
    Unfortunately I cannot compile the drivers as the compile process seems to enter in a loop, it continues to show the following output:
    TBS drivers configured for x86_64 platform.
    make -C /home/media/tbs-dvb-drivers/src/linux-tbs-drivers/v4l
    make[1]: ingresso nella directory "/home/media/tbs-dvb-drivers/src/linux-tbs-drivers/v4l"
    scripts/make_makefile.pl
    ./scripts/make_kconfig.pl /lib/modules/3.11.6-1-ARCH/build /lib/modules/3.11.6-1-ARCH/build
    Preparing to compile for kernel version 3.11.6
    ***WARNING:*** You do not have the full kernel sources installed.
    This does not prevent you from building the v4l-dvb tree if you have the
    kernel headers, but the full kernel source may be required in order to use
    make menuconfig / xconfig / qconfig.
    If you are experiencing problems building the v4l-dvb tree, please try
    building against a vanilla kernel before reporting a bug.
    Vanilla kernels are available at http://kernel.org.
    On most distros, this will compile a newly downloaded kernel:
    cp /boot/config-`uname -r` <your kernel dir>/.config
    cd <your kernel dir>
    make all modules_install install
    Please see your distro's web site for instructions to build a new kernel.
    ./scripts/make_myconfig.pl
    scripts/make_makefile.pl
    ./scripts/make_kconfig.pl /lib/modules/3.11.6-1-ARCH/build /lib/modules/3.11.6-1-ARCH/build
    Preparing to compile for kernel version 3.11.6
    ***WARNING:*** You do not have the full kernel sources installed.
    This does not prevent you from building the v4l-dvb tree if you have the
    kernel headers, but the full kernel source may be required in order to use
    make menuconfig / xconfig / qconfig.
    If you are experiencing problems building the v4l-dvb tree, please try
    building against a vanilla kernel before reporting a bug.
    Vanilla kernels are available at http://kernel.org.
    On most distros, this will compile a newly downloaded kernel:
    cp /boot/config-`uname -r` <your kernel dir>/.config
    cd <your kernel dir>
    make all modules_install install
    Please see your distro's web site for instructions to build a new kernel.
    ./scripts/make_myconfig.pl
    scripts/make_makefile.pl
    ./scripts/make_kconfig.pl /lib/modules/3.11.6-1-ARCH/build /lib/modules/3.11.6-1-ARCH/build
    Preparing to compile for kernel version 3.11.6
    ***WARNING:*** You do not have the full kernel sources installed.
    This does not prevent you from building the v4l-dvb tree if you have the
    kernel headers, but the full kernel source may be required in order to use
    make menuconfig / xconfig / qconfig.
    If you are experiencing problems building the v4l-dvb tree, please try
    building against a vanilla kernel before reporting a bug.
    Vanilla kernels are available at http://kernel.org.
    On most distros, this will compile a newly downloaded kernel:
    cp /boot/config-`uname -r` <your kernel dir>/.config
    cd <your kernel dir>
    make all modules_install install
    Please see your distro's web site for instructions to build a new kernel.
    ./scripts/make_myconfig.pl
    scripts/make_makefile.pl
    ./scripts/make_kconfig.pl /lib/modules/3.11.6-1-ARCH/build /lib/modules/3.11.6-1-ARCH/build
    Preparing to compile for kernel version 3.11.6
    I've waited up to 20 minutes, but the process seems stucked and the size of the folder doesn't grow up.
    It's true that I have just the kernel-headers installed. In addition make continues to warn me that the edit date of several files is newer than the actual. Initially the date of the system was wrong (but not older than the file's) but now I've fixed it with the correct date in UTC. The problem persists.
    I've also tried to compile from source directly but make enters into the same loop and gives me the same warnings.
    Thank you in advance for any kind of help.
    Regards.
    Last edited by fasigno (2013-11-03 21:40:00)

    First make sure you have the core-devel package group installed. This is required to build AUR package in general.
    Next, check to see if you have kernel-headers and v4l-utils installed? If not install them both and try again. I'm not sure if they are hard dependancies or not.
    EDIT: Sorry, I see you wrote that you installed core-devel and kernel-headers already. It looks like you may have a time zone and hardware clock sync problem. If you just installed arch, make sure the timezone and locale are correct and havn't been altered since you first installed your system. If that's all good, then install the AUR package cleanly from scratch again.
    Do you have NTP running?
    Last edited by wdirksen (2013-11-03 20:36:18)

  • Compiling updated kernel version

    In another thread, I found out that a fix for my cardbus problems had been put in the kernel's git tree (changeset 02caa56e), which has been in mainline long enough to be in 2.6.35-rc6. The other thread's author mentioned manually updating the kernel source. I searched the wiki for information on how to do so, and mostly the information I found was just on how to compile a kernel with patches or a customized config.
    After some more research, I concluded that the most likely course of action would be to copy the kernel26 directory from my ABS tree, change the version from '2.6.34' to '2.6.35-rc6', and just makepkg and pacman -U, then update my GRUB entry. However, the kernel26 PKGBUILD is quite complex. (And even if it wasn't, I would still like confirmation before doing something this important.) Does anyone have instructions on how to install this kernel (or at least a kernel with that changeset)?

    With a bit of extra research (and if the fix is a patch that applies cleanly to 2.6.34.x code) you could also just rebuild that one module that you need (if it's one module). It is possible to build kernel modules separately and re-integrate them into the installed kernel's module tree after that.
    If I'm not mistaken most modules have separate Makefiles themselves. This link has an example on how to do it.

Maybe you are looking for

  • Need Help to Draw and Drag Triangle - URGENT

    Hi everyone - I am developing various proofs of the pythagora's theorem and the following code draws a triangle on screen and the proof follows - but i need to know how to drag the triangle such tht 1 angle is always set to 90 degrees. i.e. i need to

  • Webservice Call

    Hi , I have to call a webservice in one of my scenarios , can someone help me on providing information on how to create WSDL for calling a web service or any link to already discussed forum.

  • Airport Extreme for my ibook G3

    Im just about to order a airport extreme card for my ibook G3. i was just wondering if anyone knows if it will definately work for it.i dont have wireless in my house.will i still beable to connect using my laptop?

  • Incremental Agg

    I have a compressed and partitioned cube on 10.2.0.4 (AWM 10.2.0.3 A). I have a basic measure QC which I would like to clear based on various criteria (custom) and then repopulate. So, I have written a DML program which using the custom criteria and

  • Images Sync

    Hi, I have just upgraded my iPhone 3gs to OS 4.1 and itunes to version10 and have encountered an error when I open my photos folder. I think it is because my phone has photos from a previous PC itunes but I have been using a Mc for a year now with no