Jivin Mike Frysinger lays it down ... > This allows people to install kernel modules from the dist by using the -M > option. For example: > $(ROMFSINTS) -M local/path/to/kern.ko subdir/kern.ko > This will install kern.ko into the appropriate place under the romfs dir: > /lib/modules/<kernel version>/subdir/kern.ko > > Signed-off-by: Mike Frysinger <[EMAIL PROTECTED]>
Applied, Thanks, Davidm > --- > --- romfs-inst.sh (revision 5667) > +++ romfs-inst.sh (revision 5668) > @@ -24,6 +24,7 @@ $0: [options] [src] dst > -A pattern : only append text if pattern doesn't exist in file > -l link : dst is a hard link to 'link'. > -s sym-link : dst is a sym-link to 'sym-link'. > + -M : install kernel module into dst subdir of module dir > > if "src" is not provided, basename is run on dst to determine the > source in the current directory. > @@ -149,13 +150,15 @@ mdir= > src= > dst= > strip=1 > +kernmod= > > -while getopts 'dSve:o:A:p:a:l:s:' opt "$@" > +while getopts 'dSMve:o:A:p:a:l:s:' opt "$@" > do > case "$opt" in > v) v="1"; ;; > d) mdir="1"; ;; > S) strip=; ;; > + M) kernmod="1"; ;; > o) option="$OPTARG"; ;; > e) eval option=\"\$$OPTARG\"; ;; > p) perm="$OPTARG"; ;; > @@ -203,6 +206,14 @@ case $# in > ;; > esac > > +if [ -n "$kernmod" ]; then > + strip= > + kerndir=${ROOTDIR}/${LINUXDIR} > + # could prob take from UTS headers as well ... > + kernver=$(cat ${kerndir}/include/config/kernel.release) > + dst="/lib/modules/${kernver}/${dst}" > +fi > + > if [ "$mdir" -a ! -d "`dirname ${ROMFSDIR}${dst}`/." ] > then > mkdir -p "`dirname ${ROMFSDIR}${dst}`/." || exit 1 > > _______________________________________________ > uClinux-dev mailing list > uClinux-dev@uclinux.org > http://mailman.uclinux.org/mailman/listinfo/uclinux-dev > This message was resent by uclinux-dev@uclinux.org > To unsubscribe see: > http://mailman.uclinux.org/mailman/options/uclinux-dev > -- David McCullough, [EMAIL PROTECTED], Ph:+61 734352815 Secure Computing - SnapGear http://www.uCdot.org http://www.cyberguard.com _______________________________________________ uClinux-dev mailing list uClinux-dev@uclinux.org http://mailman.uclinux.org/mailman/listinfo/uclinux-dev This message was resent by uclinux-dev@uclinux.org To unsubscribe see: http://mailman.uclinux.org/mailman/options/uclinux-dev