LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   modinst error when "make modules_install", kernel 2.4.22 (https://www.linuxquestions.org/questions/slackware-14/modinst-error-when-make-modules_install-kernel-2-4-22-a-123793/)

kc00l 12-08-2003 04:25 AM

modinst error when "make modules_install", kernel 2.4.22
 
I'm using Slackware 9.1 kernel 2.4.22 already recompiled for my Omnibook xe3 GF.
I had successfully recompiled my kernel several times in the past, and even used some branches of the 2.6.0 test kernel. Never had a problem which I couldn't solve by reading READMEs, HOWTOs or searching the web.

So, I decided to add PPP kernel support to use my home ADSL connection.
[Yes, I know I didn't need to recompile the entire kernel sources for that, but didn't think about that before starting the compile process.]
Anyway, I started making the correct symbolic link for the source:
Code:

cd /usr/src/
ln -s linux-2.4.22 linux

then the usual cleaning:
Code:

cd linux
make clean
make mrproper

and following the usual 2.4.XX procedure:
Code:

cp ../kernelconfigs/config-2.4.22 .config
make menuconfig

I enabled PPP as a module then:
Code:

make dep
make bzImage; make modules

all this procedure without errors. So I went on and did:
Code:

make modules_install
and then I got the following error:
Code:

ln: when making multiple links, last argument must be a directory
make: *** [_modinst_] Error 1

I then searched the Makefile for the lines referring to the "make modules_install" procedure, and found the following:
Code:

_modinst_:
        @rm -rf $(MODLIB)/kernel
        @rm -f $(MODLIB)/build
        @mkdir -p $(MODLIB)/kernel
        @ln -s $(TOPDIR) $(MODLIB)/build

This fails me... is this procedure interpreted as if I were making multiple links?
Could be due to the fact I've made some modifications to my
/etc/profile
/etc/bashrc
/etc/inputrc
?
Thanks for your attention and I'm sorry for the lenght of the post.

Misel 12-08-2003 06:52 AM

hmmm, I don't know what the error means but usually it helps when you do a "make mrproper" and recompile again.

Don't forget to backup your kernel config ;)

kc00l 12-09-2003 01:30 AM

Quote:

Originally posted by Misel
hmmm, I don't know what the error means but usually it helps when you do a "make mrproper" and recompile again.

Don't forget to backup your kernel config ;)

I've done both, as usual, but still no cigar...
Thanks for your reply, anyway.

kc00l 12-09-2003 06:06 AM

Well I didn't attach my
/etc/profile
/etc/bashrc
/etc/inputrc

to the original post so maybe I could do that now, instead of just *bumping* the post...
Code:

# Begin /etc/profile
# Written for Beyond Linux From Scratch
# by James Robertson <jameswrobertson@earthlink.net>

# System wide environment variables and startup programs.

# System wide aliases and functions should go in /etc/bashrc.  Personal
# environment variables and startup programs should go into
# ~/.bash_profile.  Personal aliases and functions should go into
# ~/.bashrc.

# Function to help us manage paths
pathman () {
        if ! echo $PATH | /bin/egrep -q "(^|:)$1($|:)" ; then
                if [ "$2" = "last" ] ; then
                        PATH=$PATH:$1
                else
                        PATH=$1:$PATH
                fi
        fi
}

# Add to the standard path.
if [ $(id -u) = 0 ] ; then
        if [ -d "/usr/local/sbin" ] ; then
                pathman /usr/local/sbin last
        fi
fi

if [ $(id -u) != 0 ] ; then
        if [ -d "/usr/local/bin" ] ; then
                pathman /usr/local/bin last
        fi
fi

if [ -d "/usr/X11R6/bin" ] ; then
        pathman /usr/X11R6/bin last
fi

# Setup some environment variables.
HISTSIZE=1000
HISTIGNORE="&:[bf]g:exit"
PS1="[\u@\h \w]\\$ "

# Setup the INPUTRC environment variable.
if [ -z "$INPUTRC" -a ! -f "$HOME/.inputrc" ] ; then
        INPUTRC=/etc/inputrc
fi

# Setup for /bin/ls to support color, the alias is in /etc/bashrc.
if [ -f "/etc/DIR_COLORS" ] ; then
        eval $(dircolors -b /etc/DIR_COLORS)

        if [ -f "$HOME/.dir_colors" ] ; then
                eval $(dircolors -b $HOME/.dir_colors)
        fi
fi


PATH="$PATH:/usr/X11R6/bin:/usr/games:$HOME/bin:/usr/local/mozilla:/usr/local/bin:/usr/share/texmf:/usr/local/Acrobat5/bin:."

export PATH HISTSIZE HISTIGNORE PS1 LS_COLORS INPUTRC

# End /etc/profile# /etc/inputrc
# This file configures keyboard input for programs using readline.
# See "man 3 readline" for more examples.

# Configure the system bell.  Options are none, visible, and audible.
#set bell-style none

# Enable 8 bit input.
set meta-flag On
set input-meta On
set convert-meta Off
set output-meta On

# Set various nice escape sequences:
"\eOd": backward-word
"\eOc": forward-word

# for linux console
"\e[1~": beginning-of-line
"\e[4~": end-of-line
"\e[5~": beginning-of-history
"\e[6~": end-of-history
"\e[3~": delete-char
"\e[2~": quoted-insert

# for xterm
"\eOH": beginning-of-line
"\eOF": end-of-line

# for freebsd console
"\e[H": beginning-of-line
"\e[F": end-of-line
# Begin /etc/bashrc
# Written for Beyond Linux From Scratch
# by James Robertson <jameswrobertson@earthlink.net>

# System wide aliases and functions.

# System wide environment variables and startup programs should go into
# /etc/profile.  Personal environment variables and startup programs
# should go into ~/.bash_profile.  Personal aliases and functions should
# go into ~/.bashrc

# By default we want the umask to get set.
# Even for non-interactive and non-login shells.
if [ "$(id -gn)" = "$(id -un)" -a $(id -u) -gt 99 ] ; then
        umask 002
else
        umask 022
fi

# Provides a colored /bin/ls command.  Used in conjunction with code in
# /etc/profile.
alias ls='ls --color=auto'

# Provides prompt for non-interactive shells, specifically shells started
# in the xfree environment. [Review archive thread titled PS1
# Environment Variable for a great case study behind this script
# addendum.]
export PS1="[\u@\h \w]\\$ "

# End /etc/bashrc

Again, sorry for the long post.

cimmer 12-09-2003 08:34 AM

post a few lines preceeding the error

kc00l 12-09-2003 09:33 AM

Unfortunately there are no preceding lines...
"make modules_install" just tries to create the modules directory for the custom kernel (I've modified the Makefile extraversion) and then stops cause it doesn't interpret correctly this part:

Code:

@ln -s $(TOPDIR) $(MODLIB)/build
Actually it's some part of $MODLIB which I think it's not recognized as a directory...
Code:

TOPDIR        := $(shell /bin/pwd)
MODLIB        := $(INSTALL_MOD_PATH)/lib/modules/$(KERNELRELEASE)
KERNELRELEASE=$(VERSION).$(PATCHLEVEL).$(SUBLEVEL)$(EXTRAVERSION)

Maybe I could just manually install modules by making what "make modules_install" does but this won't solve the problem and won't help me understand where's the problem.

kc00l 12-10-2003 09:12 AM

So, after a little bit more googling (I searched for the complete error msg I get) I found I'm not the only one (are we ever the only ones to experience problems?) to get this error message when recompiling the kernel.
From what I found it seems the point is the syntax of the EXTRAVERSION in the top Makefile. My EXTRAVERSION is:
Code:

EXTRAVERSION = -myker.091203
Looking at the other kernels images I have in my /boot directory it seems they don't have a
"." in their name...

Anyway I'm recompiling now without that dot in the extraversion. I feel that's the error.

I hope this little kernel experience may help others which have/have had/will have the same error message.

EDIT:
I found the error:

"make dep" before editing the EXTRAVERSION of the top Makefile
ie, I made sure to have an empty EXTRAVERSION Makefile before doing "make dep" and only after "make dep" has finished change the EXTRAVERSION.

maykon 01-23-2004 02:28 PM

Normally this occurs when you leave a blank space in the field EXTRAVERSION=

For example: edit the Makefile, locate the EXTRAVERSION line end verify if you have the blank space "EXTRAVERSION= -1.mcs ". Erase the blank space "EXTRAVERSION= -1.mcs" end re-compile the kernel.

Bye.


All times are GMT -5. The time now is 03:04 AM.