AMiLDA FORUM

You are not logged in.

Announcement

### Our Homepage is down at the moment...work in progress !! ###

#1 2007-01-11 02:23:50

supaplex
New member
Registered: 2006-10-18
Last visit: 2007-01-15
Posts: 4

Kernel top level makefile differences

I've managed to patch and upgrade the kernel to 2.4.34. (Makefile diffs below) It compiles ok if I disable the serial terminal options and related misc.  I'll worry about those a little later when I'm ready to create an image for upgrade.  But first I'd like to review changes that exist between the top level makefile for the kernel that amilda is using, and what's available in the plain vanilla mainstream release.  I haven't tested any of this in action until I understand some of the missing pieces.

Lines 1-9 are not all that important.
Lines 13-14 show amilda differences forcing the ARCH.  This change is actually unneeded to target the ARCH.  When the Makefile is called, a command line parameter can be provided to override the Makefile internals.  Eg, make -C linux/ ARCH=mips

I'm not sure what to make of some of the other changes, however Lines 57-58 raise a few questions in my mind.  Can this be moved out of the kernel Makefile? (if we ever expect acceptance into the mainstream kernel, we want as little contention introduced as possible)  I think it's better to operate these tasks in the amilda makefile after the kernel build tasks are complete.  Eventually they should be supported in a script the devices could take care of during upgrade.  To prevent doing the same thing twice, keep the output files where they are until a make clean.  gzip could make vmlinuz.bin.gz for the other tools to operate on.  Eg, image/Makefile could use ./cvimg .../vmlinuz.bin.gz linux-adm.bin.  I'm not as sharp as I'd like to be with makefiles, but I know there's someway to have make skip/ignore work that's already complete.

Any feedback or suggestions?  I have some interesting alternatives and suprises in store, I'll keep you posted after I understand some of the gaps.

Thanks.

supaplex@riddle:/usr/local/src/AMiLDA$ diff -dwu linux-2.4.34-amilda/Makefile* | cat -n
     1  --- linux-2.4.34-amilda/Makefile        2007-01-10 16:36:17.000000000 -0700
     2  +++ linux-2.4.34-amilda/Makefile.amilda 2006-04-07 18:26:48.000000000 -0600
     3  @@ -1,11 +1,11 @@
     4   VERSION = 2
     5   PATCHLEVEL = 4
     6  -SUBLEVEL = 34
     7  -EXTRAVERSION =
     8  +SUBLEVEL = 32
     9  +EXTRAVERSION = -amilda
    10
    11   KERNELRELEASE=$(VERSION).$(PATCHLEVEL).$(SUBLEVEL)$(EXTRAVERSION)
    12
    13  -ARCH := $(shell uname -m | sed -e s/i.86/i386/ -e s/sun4u/sparc64/ -e s/arm.*/arm/ -e s/sa110/arm/)
    14  +ARCH := mips
    15   KERNELPATH=kernel-$(shell echo $(KERNELRELEASE) | sed -e "s/-//g")
    16
    17   CONFIG_SHELL := $(shell if [ -x "$$BASH" ]; then echo $$BASH; \
    18  @@ -93,17 +93,11 @@
    19
    20   CFLAGS := $(CPPFLAGS) -Wall -Wstrict-prototypes -Wno-trigraphs -O2 \
    21            -fno-strict-aliasing -fno-common
    22  -CFLAGS += -fno-builtin-sprintf
    23   ifndef CONFIG_FRAME_POINTER
    24   CFLAGS += -fomit-frame-pointer
    25   endif
    26   AFLAGS := -D__ASSEMBLY__ $(CPPFLAGS)
    27
    28  -check_gcc = $(shell if $(CC) $(1) -S -o /dev/null -xc /dev/null > /dev/null 2>&1; then echo "$(1)"; else echo "$(2)"; fi)
    29  -
    30  -# disable pointer signedness warnings in gcc 4.0
    31  -CFLAGS += $(call check_gcc,-Wno-pointer-sign,)
    32  -
    33   #
    34   # ROOT_DEV specifies the default root-device when making the image.
    35   # This can be either FLOPPY, CURRENT, /dev/xxxx or empty, in which case
    36  @@ -249,14 +243,14 @@
    37          drivers/sound/pndsperm.c \
    38          drivers/sound/pndspini.c \
    39          drivers/atm/fore200e_*_fw.c drivers/atm/.fore200e_*.fw \
    40  -       .version .config* config.in config.old \
    41  +       .version config.in config.old \
    42          scripts/tkparse scripts/kconfig.tk scripts/kconfig.tmp \
    43          scripts/lxdialog/*.o scripts/lxdialog/lxdialog \
    44          .menuconfig.log \
    45          include/asm \
    46          .hdepend scripts/mkdep scripts/split-include scripts/docproc \
    47          $(TOPDIR)/include/linux/modversions.h \
    48  -       kernel.spec
    49  +       kernel.spec vmlinuz vmlinux.bin
    50
    51   # directories removed with 'make mrproper'
    52   MRPROPER_DIRS = \
    53  @@ -301,6 +295,8 @@
    54                  --end-group \
    55                  -o vmlinux
    56          $(NM) vmlinux | grep -v '\(compiled\)\|\(\.o$$\)\|\( [aUw] \)\|\(\.\.ng$$\)\|\(LASH[RL]DI\)' | sort > System.map
    57  +       $(OBJCOPY) -O binary vmlinux vmlinux.bin
    58  +       gzip -c vmlinux.bin > vmlinuz
    59
    60   symlinks:
    61          rm -f include/asm

Offline

 

#2 2007-01-12 04:36:06

sergioag
Developer
Peru
From: Lima
Registered: 2006-02-16
Last visit: 2011-08-15
Posts: 166
Website

Re: Kernel top level makefile differences

Hi

Merging ADM5120 into mainstream is not currently planned. I think 2.4 is only open to bugfixes, but not for anything else though.

The changes in the makefile were mostly copied from the 2.4.18 kernel's makefile. I also make mrproper doesn't delete .config so it is easier for me to prepare a source package for release big_smile

Hope this helps you

Sergio

Offline

 

#3 2007-01-12 06:03:54

supaplex
New member
Registered: 2006-10-18
Last visit: 2007-01-15
Posts: 4

Re: Kernel top level makefile differences

Okay.  however, is this busy work around lines 57+58 prepare the kernel for use by the boot loader?  I assume the boot loader decompresses the kernel and launches it from there? Are there any sections objdump should discard to save space?

Can you also describe in detail how the MTD is laid out, and how the partitions work?  How are they accessed from a shell prompt after you telnet into it?  What in depth information is around for the jtag details?  Is there anything special I need to know?  I have yet to make my own cable, but I can almost bet money I'll brick this with my testing before I get it working the way I want.

I guess I should record the mac address before I do anything so I can use the tftp trick.  What routers is this available on?  I have a USR that's b0ked until I reflash it somehow...  roll

Thanks for all the help.  BTW, compare http://amilda.org/ and http://www.amilda.org/ and ask yourself what's wrong.  I think you just need a serveralias amilda.org in the section you have running wwwamilda.orgbig_smile   And is there a mediawiki section here somewhere?

Offline

 

#4 2007-01-12 19:53:51

MrZack
Administrator
Austria
Registered: 2006-02-15
Last visit: 2017-10-23
Posts: 106

Re: Kernel top level makefile differences

supaplex wrote:

Thanks for all the help.  BTW, compare http://amilda.org/ and http://www.amilda.org/ and ask yourself what's wrong.  I think you just need a serveralias amilda.org in the section you have running wwwamilda.org.  big_smile   And is there a mediawiki section here somewhere?

Thanks for the great tip.....done big_smile

Mediawiki.....no..do we need one?

--
MrZack
wwwamilda.org
and smile
amilda.org


Nothing is impossible....except that the state of your mind makes it so.

Offline

 

#5 2007-01-13 04:35:31

supaplex
New member
Registered: 2006-10-18
Last visit: 2007-01-15
Posts: 4

Re: Kernel top level makefile differences

A wiki (eg, using mediawiki) would allow all of us to colaborate on common topics of the project.  Mundane FAQ's could be reduced to a url into the wiki.  It's the next best thing to a real manual, because bits and pieces of it could be written by anyone, on demand (or impulse).  It'd be sort of the amilda knowledge base  cool .  If you're still left with questions, fire them off me and I'll let you know.

Offline

 

Board footer

Powered by PunBB
© Copyright 2002–2008 PunBB