Still want the binary rpm to kernel-n900 or want a new name of 
kernel-adaption-n900. Suggest the latter

Peter

> -----Original Message-----
> From: [email protected]
> [mailto:[email protected]] On Behalf Of ikoskine
> Sent: Tuesday, December 28, 2010 6:18 PM
> To: [email protected]
> Subject: [meego-commits] 11293: New package
> Trunk:Testing/kernel-adaptation-n900
>
> Hi,
> Adding new package kernel-adaptation-n900 in project Trunk:Testing. Please
> review and accept ASAP.
>
> Justification for this new package:
>
> Move to adaptation kernel as per new kernel policy. Obsoletes kernel-n900 and
> fixes its build failure
>
> Thank You,
> ikoskine
>
> [This message was auto-generated]
>
> ---
>
> Request #11293:
>
>   submit:   devel:devices:n900/kernel-adaptation-n900(r3) ->
> Trunk:Testing/kernel-adaptation-n900
>
>
> Message:
>     Move to adaptation kernel as per new kernel policy. Obsoletes kernel-n900
> and fixes its build failure
>
> State:   new          2010-12-28T02:18:22 ikoskine
> Comment: None
>
>
> This is a NEW package in Trunk:Testing project.
> The files in the new package:
> kernel-adaptation-n900/
>   |__  COPYING.modules
>   |__  Makefile
>   |__  Makefile.config
>   |__  compat-wireless-2010-10-19.tar.bz2
>   |__  config-arm-n900
>   |__  config-generic
>   |__  configcommon.pl
>   |__  configdiff.pl
>   |__  kernel-adaptation-n900.spec
>   |__  kernel-n900.config
>   |__  kernel.changes
>   |__  kernel.spec.in
>   |__
> linux-2.6-37-leds-driver-for-LP5523-chips-from-National-Semicondu.patch
>   |__  linux-2.6-ASoC-RX-51-Add-Jack-Function-kcontrol.patch
>   |__
> linux-2.6-ASoC-RX-51-Add-aic34b_dummy-driver-only-for-the-RX-5.patch
>   |__  linux-2.6-ASoC-RX-51-Add-basic-jack-detection.patch
>   |__  linux-2.6-ASoC-RX-51-Add-mic-input-to-AV-jack.patch
>   |__  linux-2.6-ASoC-RX-51-Add-stereo-audio-output-to-AV-jack.patch
>   |__  linux-2.6-ASoC-RX-51-Add-support-for-FM-transmitter.patch
>   |__  linux-2.6-ASoC-RX-51-Add-support-for-earpiece.patch
>   |__  linux-2.6-Bluetooth-Support-for-n900-bluetooth-hardware.patch
>   |__  linux-2.6-CMT-Add-Nokia-CMT-driver-to-the-configuration.patch
>   |__  linux-2.6-CMT-Introduces-the-Nokia-CMT-driver.patch
>   |__  linux-2.6-HACK-mfd-twl4030-power-disable-scripts.patch
>   |__  linux-2.6-HACK-sysfs_notify-support-for-isp1704-charger-driver.patch
>   |__  linux-2.6-HSI-Add-HSI-API-documentation.patch
>   |__  linux-2.6-HSI-Introducing-HSI-framework.patch
>   |__  linux-2.6-HSI-cmt_speech-Adapt-to-kernel-API-changes-in-2.6.35.patch
>   |__
> linux-2.6-HSI-cmt_speech-Add-CMT-SPEECH-to-the-configuration.patch
>   |__  linux-2.6-HSI-cmt_speech-Add-CMT_SPEECH-driver.patch
>   |__  linux-2.6-HSI-hsi_char-Add-HSI-char-device-driver.patch
>   |__  linux-2.6-HSI-hsi_char-Add-HSI-char-device-kernel-configuratio.patch
>   |__  linux-2.6-HSI-omap_ssi-Add-OMAP-SSI-to-the-kernel-configuratio.patch
>   |__  linux-2.6-HSI-omap_ssi-Introducing-OMAP-SSI-driver.patch
>   |__  linux-2.6-HSI-ssip-Add-SSI-protocol-to-the-kernel-configuratio.patch
>   |__  linux-2.6-HSI-ssip-Introducing-SSI-protocol-aka-McSAAB.patch
>   |__
> linux-2.6-OMAP2-3-PRCM-export-cm_read_mod_reg-and-cm_write_mod.patch
>   |__
> linux-2.6-OMAP2-3-clock-implement-clock-rate-parent-change-not.patch
>   |__  linux-2.6-PM-export-missing-symbols.patch
>   |__  linux-2.6-SoC-RX-51-Add-route-for-AIC34B-generated-mic-bias.patch
>   |__  linux-2.6-Updated-rx51_defconfig.patch
>   |__
> linux-2.6-V4L-DVB-radio-si4713-Add-regulator-framework-support.patch
>   |__  linux-2.6-V4L-DVB-radio-si4713-Release-i2c-adapter-in-driver-c.patch
>   |__  linux-2.6-build-nonintconfig.patch
>   |__  linux-2.6-gpu-pvr-Add-PVR-GPU-driver.patch
>   |__  linux-2.6-gpu-pvr-compilation-fixes-for-kernel-2.6.33.patch
>   |__  linux-2.6-hci_h4p-Fix-module-auto-loading.patch
>   |__  linux-2.6-mfd-implement-twl4030-poweroff.patch
>   |__  linux-2.6-mfd-twl4030-Driver-for-twl4030-madc-module.patch
>   |__  linux-2.6-musb_gadget-notifier-hack.patch
>   |__  linux-2.6-omap-rx51-Add-initialization-and-platform-data-for-S.patch
>   |__  linux-2.6-omap-rx51-Add-platform_data-for-tlv320aic3x-with-res.patch
>   |__
> linux-2.6-omap-rx51-Add-second-instance-of-the-TLV320AIC34-cod.patch
>   |__
> linux-2.6-omap-rx51-Add-supply-and-data-for-the-tpa6130a2-head.patch
>   |__  linux-2.6-omap-rx51-Set-regulator-V28-always-on.patch
>   |__
> linux-2.6-omap-rx51-Use-REGULATOR_SUPPLY-macro-when-initializi.patch
>   |__  linux-2.6-omap3isp-rx51.patch
>   |__  linux-2.6-power_supply-Add-maximum-current-property.patch
>   |__  linux-2.6-power_supply-isp1704-Detect-HUB-Host-chargers.patch
>   |__  linux-2.6-power_supply-isp1704-Detect-charger-after-probe.patch
>   |__  linux-2.6-power_supply-isp1704-Set-isp-dev-before-anything-nee.patch
>   |__  linux-2.6-power_supply-isp1704-correct-length-for-storing-mode.patch
>   |__  linux-2.6-rx51-Add-SSI-related-support-to-board.patch
>   |__  linux-2.6-usb-musb-add-mA-and-charger-sysfs-entries.patch
>   |__  linux-2.6-usb-musb-add-suspend-sysfs-entry.patch
>   |__  linux-2.6-usb-musb-ignore-spurious-SESSREQ-interrupts-v1.patch
>   |__  linux-2.6-usb-musb-ignore-spurious-SESSREQ-interrupts-v2.patch
>   |__  linux-2.6-usb-otg-add-detect_charger-field-to-otg_transceiver.patch
>   |__  linux-2.6.29-dont-wait-for-mouse.patch
>   |__  linux-2.6.29-sreadahead.patch
>   |__  linux-2.6.33-vfs-tracepoints.patch
>   |__  linux-2.6.35-CMT-Add-field-for-irq-flags-to-driver-platform-data.patch
>   |__
> linux-2.6.35-HSI-cmt_speech-Free-allocated-pages-in-case-open-fai.patch
>   |__
> linux-2.6.35-HSI-cmt_speech-avoid-GFP_ATOMIC-in-cs_char_open.patch
>   |__
> linux-2.6.35-HSI-cmt_speech-return-error-if-HSI-port-not-configur.patch
>   |__
> linux-2.6.35-HSI-ssip-add-ssip_slave_running-to-ssi_protocol-inte.patch
>   |__  linux-2.6.35-board-rx51-set-cmt_rst_ind_flags.patch
>   |__  linux-2.6.35-dont-skew-the-tick.patch
>   |__  linux-2.6.35-fatal-signals.patch
>   |__  linux-2.6.35-slab-timer.patch
>   |__  linux-2.6.35.tar.bz2
>   |__
> linux-2.6.36-Adding-CS_FEAT_BURST_MODE-for-cmt_speech-driver.patch
>   |__  linux-2.6.36-PM-Runtime-Lenient-generic-runtime-pm-callbacks.patch
>   |__
> linux-2.6.36-omap-rx51-Platform-support-for-lis3lv02d-acceleromet.patch
>   |__  linux-2.6.36-omap-rx51-Platform-support-for-tsl2563-ALS.patch
>   |__  linux-2.6.36-tidspbridge.patch
>   |__
> linux-2.6.36-wl1251-Use-MODULE_ALIAS-macro-at-correct-postion-for.patch
>   |__  linux-2.6.36-wl1271-add-platform_data.patch
>   |__  linux-2.6.37-EEM-support-for-g_nokia.patch
>   |__  linux-2.6.37-N900-Set-keypad-slide-gpio-as-active-low.patch
>   |__
> linux-2.6.37-OMAP3-DMA-Errata-i541-sDMA-FIFO-draining-does-not-fi.patch
>   |__  linux-2.6.37-omap-rx51-add-support-for-USB-chargers.patch
>   |__  linux-2.6.37-omap3-rx51-Platform-support-for-lp5523-led-chip.patch
>   |__  linux-2.6.37-power_supply-add-isp1704-charger-detection-driver.patch
>   |__  linux-2.6.37-power_supply-add-types-for-USB-chargers.patch
>   |__  linux-2.6.37-timer-Added-usleep_range-timer.patch
>   |__  linux-2.6.38-input-touchscreen-introduce-tsc2005-driver.patch
>   |__  linux-2.6.38-omap-rx-51-enable-tsc2005.patch
>   |__  makespec.pl
>   |__  merge.pl
>   |__  patch-2.6.35.9.bz2
>   |__  series
>
> The content of the spec file, kernel-adaptation-n900.spec:
> ================================================================
> ===
> #
> # Spec file originally created for Fedora, modified for Moblin Linux
> #
>
> Summary: The Linux kernel (the core of the Linux operating system)
>
>
> # For a stable, released kernel, released_kernel should be 1. For rawhide
> # and/or a kernel built from an rc snapshot, released_kernel should
> # be 0.
> %define released_kernel 1
>
> # Versions of various parts
>
> # base_sublevel is the kernel version we're starting with and patching
> # on top of -- for example, 2.6.22-rc7 starts with a 2.6.21 base,
> # which yields a base_sublevel of 21.
>
> %define base_sublevel 35
>
>
> ## If this is a released kernel ##
> %if 0%{?released_kernel}
> # Do we have a 2.6.21.y update to apply?
> %define stable_update 9
> # Set rpm version accordingly
> %if 0%{?stable_update}
> %define stablerev .%{stable_update}
> %endif
> %define rpmversion 2.6.%{base_sublevel}%{?stablerev}
>
> ## The not-released-kernel case ##
> %else
> # The next upstream release sublevel (base_sublevel+1)
> %define upstream_sublevel %(expr %{base_sublevel} + 1)
> # The rc snapshot level
>
> %define rcrev 0
>
>
> %if 0%{?rcrev}
> %define rctag ~rc%rcrev
> %endif
>
> %if !0%{?rcrev}
> %define rctag ~rc0
> %endif
>
> # Set rpm version accordingly
> %define rpmversion 2.6.%{upstream_sublevel}%{?rctag}
> %endif
>
> # The kernel tarball/base version
> %define kversion 2.6.%{base_sublevel}
>
> %define make_target bzImage
>
> %define KVERREL %{version}-%{release}
> %define hdrarch %_target_cpu
>
> %define compat_wireless_ver 2010-10-19
>
> %define all_x86 i386 i586 i686 %{ix86}
>
> %define all_arm %{arm}
>
> %define _default_patch_fuzz 0
>
> # Per-arch tweaks
>
> %ifarch %{all_x86}
> %define image_install_path boot
> %define hdrarch i386
> %define kernel_image arch/x86/boot/bzImage
> %endif
>
> %ifarch x86_64
> %define image_install_path boot
> %define kernel_image arch/x86/boot/bzImage
> %endif
>
> %ifarch %{all_arm}
> %define image_install_path boot
> %define kernel_image arch/arm/boot/zImage
> %define make_target zImage
> %endif
>
> %define oldconfig_target nonint_oldconfig
>
> ExclusiveArch: %{all_arm}
> #
> # Packages that need to be installed before the kernel is, because the %post
> # scripts use them.
> #
> %define kernel_prereq  fileutils, module-init-tools, fastinit, mkinitrd >=
> 6.0.39-1
>
> #
> # This macro does requires, provides, conflicts, obsoletes for a kernel 
> package.
> #     %%kernel_reqprovconf <subpackage>
> # It uses any kernel_<subpackage>_conflicts and
> kernel_<subpackage>_obsoletes
> # macros defined above.
> #
> %define kernel_reqprovconf \
> Provides: kernel = %{rpmversion}-%{release}\
> Provides: kernel-uname-r = %{KVERREL}%{?1:-%{1}}\
> Requires(pre): %{kernel_prereq}\
> %{?1:%{expand:%%{?kernel_%{1}_conflicts:Conflicts: %%{kernel_%{1}_conflicts
> }}}}\
> %{?1:%{expand:%%{?kernel_%{1}_provides:Provides: %%{kernel_%{1}_provides
> }}}}\
> # We can't let RPM do the dependencies automatic because it'll then pick up\
> # a correct but undesirable perl dependency from the module headers which\
> # isn't required for the kernel proper to function\
> AutoReq: no\
> AutoProv: yes\
> %{nil}
>
> Name: kernel-n900
>
> Group: System/Kernel
> License: GPLv2
> URL: http://www.kernel.org/
> Version: %{rpmversion}
> Release: 6
>
> %kernel_reqprovconf
>
> #
> # List the packages used during the kernel build
> #
> BuildRequires: module-init-tools, bash >= 2.03, sh-utils
> BuildRequires:  findutils,  make >= 3.78
> BuildRequires: linux-firmware
> BuildRequires: elfutils-libelf-devel binutils-devel newt-devel
>
> Source0: ftp://ftp.kernel.org/pub/linux/kernel/v2.6/linux-%{kversion}.tar.bz2
> Source1: compat-wireless-%{compat_wireless_ver}.tar.bz2
> Source2: series
>
> Source10: COPYING.modules
>
> Source15: merge.pl
> Source20: Makefile.config
>
> Source100: config-generic
> Source101: config-arm-n900
>
> # For a stable release kernel
> %if 0%{?stable_update}
> Patch00: patch-2.6.%{base_sublevel}.%{stable_update}.bz2
> %endif
> %if 0%{?rcrev}
> Patch00: patch-2.6.%{upstream_sublevel}-rc%{rcrev}.bz2
> %endif
>
> # Reminder of the patch filename format:
> # linux-<version it is supposed to be
> upstream>-<description-separated-with-dashes>.patch
> #
>
>
> #
> # Stable patch - critical bugfixes
> #
>
> Patch1: patch-2.6.35.9.bz2
>
>
> #
> # Patch to add a "nonintconfig" option to the Makefile
> # needed for unattended builds
> #
> Patch2: linux-2.6-build-nonintconfig.patch
>
>
>
> ################################################################
> #####
> #
> # Direct Backport section.. only patches already in Linus' or maintainer git 
> trees
> # (for linux-next) should go here.
> # We will regularly drop patches from this section as we rebase to newer
> # kernels.
> #
>
>
> Patch100:
> linux-2.6.36-PM-Runtime-Lenient-generic-runtime-pm-callbacks.patch
>
>
> # cherry picking the important security/corruption fixes from
> # the stable series
>
>
> # Kernel CVE patches - these go last in the backport section
> # no non-cve patches should go here!
>
>
>
> #
> # End of the Direct Backports section
> #
> ################################################################
> #####
>
>
>
>
>
> ################################################################
> #####
> #
> # Moorestown and Medfield architecture patches
> # Section maintainer: Arjan van de Ven <[email protected]>
> #
>
> #
> # The main consolidated MRST/MFLD tree from
> # git://git.kernel.org/pub/scm/linux/kernel/git/alan/linux-2.6-mid-ref
> #
>
> # wifi/bluetooth connectivity
> Patch200: linux-2.6.36-wl1271-add-platform_data.patch
>
> #
> # End of the Moorestown and Medfield architecture patches
> #
> ################################################################
> #####
>
>
>
>
> ################################################################
> #####
> #
> # Nokia N900 patches
> # Section maintainer: Ilkka Koskinen <[email protected]>
> #
>
> # Hacks
> Patch300: linux-2.6-usb-musb-add-mA-and-charger-sysfs-entries.patch
> Patch301: linux-2.6-usb-musb-add-suspend-sysfs-entry.patch
> Patch302: linux-2.6-usb-otg-add-detect_charger-field-to-otg_transceiver.patch
> Patch303:
> linux-2.6-OMAP2-3-clock-implement-clock-rate-parent-change-not.patch
> Patch304: linux-2.6-PM-export-missing-symbols.patch
>
> # Touch screen
> Patch305: linux-2.6.38-input-touchscreen-introduce-tsc2005-driver.patch
> Patch306: linux-2.6.38-omap-rx-51-enable-tsc2005.patch
>
> # Bluetooth
> Patch307: linux-2.6-Bluetooth-Support-for-n900-bluetooth-hardware.patch
> Patch308: linux-2.6-hci_h4p-Fix-module-auto-loading.patch
>
> # Ambient light sensor
> Patch309: linux-2.6.36-omap-rx51-Platform-support-for-tsl2563-ALS.patch
>
> # Accelerometer
> Patch310:
> linux-2.6.36-omap-rx51-Platform-support-for-lis3lv02d-acceleromet.patch
>
> #Aic34b
> # FM TX, headphone, TV-out and basic jack detection
> Patch311:
> linux-2.6-omap-rx51-Add-platform_data-for-tlv320aic3x-with-res.patch
> Patch312:
> linux-2.6-omap-rx51-Use-REGULATOR_SUPPLY-macro-when-initializi.patch
> Patch313:
> linux-2.6-omap-rx51-Add-supply-and-data-for-the-tpa6130a2-head.patch
> Patch314: linux-2.6-ASoC-RX-51-Add-Jack-Function-kcontrol.patch
> Patch315: linux-2.6-ASoC-RX-51-Add-basic-jack-detection.patch
> Patch316: linux-2.6-ASoC-RX-51-Add-stereo-audio-output-to-AV-jack.patch
> Patch317:
> linux-2.6-V4L-DVB-radio-si4713-Release-i2c-adapter-in-driver-c.patch
> Patch318:
> linux-2.6-V4L-DVB-radio-si4713-Add-regulator-framework-support.patch
> Patch319: linux-2.6-omap-rx51-Set-regulator-V28-always-on.patch
> Patch320: linux-2.6-omap-rx51-Add-initialization-and-platform-data-for-S.patch
> Patch321: linux-2.6-ASoC-RX-51-Add-support-for-FM-transmitter.patch
>
> # Earpiece and headset support
> Patch322:
> linux-2.6-ASoC-RX-51-Add-aic34b_dummy-driver-only-for-the-RX-5.patch
> Patch323:
> linux-2.6-omap-rx51-Add-second-instance-of-the-TLV320AIC34-cod.patch
> Patch324: linux-2.6-ASoC-RX-51-Add-support-for-earpiece.patch
> Patch325: linux-2.6-ASoC-RX-51-Add-mic-input-to-AV-jack.patch
> Patch326: linux-2.6-SoC-RX-51-Add-route-for-AIC34B-generated-mic-bias.patch
>
> # Cellular modem support
> Patch327:
> linux-2.6-OMAP2-3-PRCM-export-cm_read_mod_reg-and-cm_write_mod.patch
> Patch328: linux-2.6-HSI-Introducing-HSI-framework.patch
> Patch329: linux-2.6-HSI-omap_ssi-Introducing-OMAP-SSI-driver.patch
> Patch330:
> linux-2.6-HSI-omap_ssi-Add-OMAP-SSI-to-the-kernel-configuratio.patch
> Patch331: linux-2.6-HSI-hsi_char-Add-HSI-char-device-driver.patch
> Patch332: linux-2.6-HSI-hsi_char-Add-HSI-char-device-kernel-configuratio.patch
> Patch333: linux-2.6-HSI-Add-HSI-API-documentation.patch
> Patch334: linux-2.6-HSI-ssip-Add-SSI-protocol-to-the-kernel-configuratio.patch
> Patch335: linux-2.6-HSI-cmt_speech-Add-CMT_SPEECH-driver.patch
> Patch336:
> linux-2.6-HSI-cmt_speech-Add-CMT-SPEECH-to-the-configuration.patch
> Patch337: linux-2.6-CMT-Introduces-the-Nokia-CMT-driver.patch
> Patch338: linux-2.6-CMT-Add-Nokia-CMT-driver-to-the-configuration.patch
> Patch339: linux-2.6-rx51-Add-SSI-related-support-to-board.patch
> Patch340: linux-2.6-HSI-ssip-Introducing-SSI-protocol-aka-McSAAB.patch
> Patch341:
> linux-2.6-HSI-cmt_speech-Adapt-to-kernel-API-changes-in-2.6.35.patch
>
> # TI dspbridge driver
> Patch342: linux-2.6.36-tidspbridge.patch
>
> # lp5523 and corresponding platform data for rx51 board
> Patch343:
> linux-2.6-37-leds-driver-for-LP5523-chips-from-National-Semicondu.patch
> Patch344: linux-2.6.37-omap3-rx51-Platform-support-for-lp5523-led-chip.patch
>
> # omap3isp-rx51 driver
> Patch345: linux-2.6-omap3isp-rx51.patch
>
> #Bugfixes
> Patch346: linux-2.6.37-N900-Set-keypad-slide-gpio-as-active-low.patch
>
> #General
> Patch347: linux-2.6.37-timer-Added-usleep_range-timer.patch
>
> #N900 defconfig
> Patch348: linux-2.6-Updated-rx51_defconfig.patch
>
> # GPU
> Patch349: linux-2.6-gpu-pvr-Add-PVR-GPU-driver.patch
> Patch350: linux-2.6-gpu-pvr-compilation-fixes-for-kernel-2.6.33.patch
>
> # TWL4030 MADC (Battery Charging)
> Patch351: linux-2.6-mfd-twl4030-Driver-for-twl4030-madc-module.patch
> Patch352: linux-2.6-mfd-implement-twl4030-poweroff.patch
> Patch353: linux-2.6-HACK-mfd-twl4030-power-disable-scripts.patch
>
> #Bugfixes
> Patch354:
> linux-2.6.36-Adding-CS_FEAT_BURST_MODE-for-cmt_speech-driver.patch
>
> Patch355:
> linux-2.6.35-CMT-Add-field-for-irq-flags-to-driver-platform-data.patch
> Patch356: linux-2.6.35-board-rx51-set-cmt_rst_ind_flags.patch
>
> Patch357:
> linux-2.6.35-HSI-cmt_speech-Free-allocated-pages-in-case-open-fai.patch
> Patch358:
> linux-2.6.35-HSI-cmt_speech-avoid-GFP_ATOMIC-in-cs_char_open.patch
> Patch359:
> linux-2.6.35-HSI-ssip-add-ssip_slave_running-to-ssi_protocol-inte.patch
> Patch360:
> linux-2.6.35-HSI-cmt_speech-return-error-if-HSI-port-not-configur.patch
>
> # usb charger platform device support
> # isp1704 usb charger detection driver
> Patch361:
> linux-2.6.37-power_supply-add-isp1704-charger-detection-driver.patch
> Patch362: linux-2.6.37-omap-rx51-add-support-for-USB-chargers.patch
> Patch363: linux-2.6.37-power_supply-add-types-for-USB-chargers.patch
> Patch364: linux-2.6-usb-musb-ignore-spurious-SESSREQ-interrupts-v1.patch
> Patch365: linux-2.6-usb-musb-ignore-spurious-SESSREQ-interrupts-v2.patch
> Patch366:
> linux-2.6-power_supply-isp1704-correct-length-for-storing-mode.patch
> Patch367: linux-2.6-power_supply-isp1704-Detect-HUB-Host-chargers.patch
> Patch368:
> linux-2.6-power_supply-isp1704-Set-isp-dev-before-anything-nee.patch
> Patch369: linux-2.6-power_supply-isp1704-Detect-charger-after-probe.patch
> Patch370: linux-2.6-power_supply-Add-maximum-current-property.patch
> Patch371:
> linux-2.6-HACK-sysfs_notify-support-for-isp1704-charger-driver.patch
> Patch372: linux-2.6-musb_gadget-notifier-hack.patch
>
> # Fixes
> Patch373:
> linux-2.6.36-wl1251-Use-MODULE_ALIAS-macro-at-correct-postion-for.patch
> Patch374:
> linux-2.6.37-OMAP3-DMA-Errata-i541-sDMA-FIFO-draining-does-not-fi.patch
>
> # Introduce EEM support in g_nokia which should fix usb networking
> Patch375: linux-2.6.37-EEM-support-for-g_nokia.patch
>
>
>
> #
> # End of the Nokia N900 patches
> #
> ################################################################
> #####
>
>
>
>
> ################################################################
> #####
> #
> # Netbook hardware patches
> # Section maintainer: Yong Wang <[email protected]>
> #
>
> #
> # Quiet down some printks that shows up falsly during boot
> #
>
>
>
> #
> # End of the Netbook hardware patches
> #
> ################################################################
> #####
>
>
> ################################################################
> #####
> #
> # IVI hardware patches
> # Section maintainer: Yin Kangkai <[email protected]>
> #
>
>
>
>
> #
> # End of the IVI hardware patches
> #
> ################################################################
> #####
>
>
> ################################################################
> #####
> #
> # Intel Integrated Graphics patches
> # Section maintainer:  Li Peng <[email protected]>
> #
>
> #
> # KMS (note: upstream backports go in the backport section higher up!)
> #
> #linux-2.6.29-kms-edid-cache.patch
> #linux-2.6.29-kms-run-async.patch
> #linux-2.6.29-kms-after-sata.patch
>
>
> #
> # End of the Intel Integrated Graphics patches
> #
> ################################################################
> #####
>
>
>
> ################################################################
> #####
> #
> # Boot time and power patches
> # Section maintainer:  Arjan van de Ven <[email protected]
> #
>
> #
> # Patch to try mounting / before all devices (the mouse)
> # are done probing. This saves several seconds of boot time.
> #
> Patch700: linux-2.6.29-dont-wait-for-mouse.patch
> #
> # Patch to support the old sreadahead versions
> #
> Patch701: linux-2.6.29-sreadahead.patch
>
>
>
> #
> # Patches to help PowerTOP
> #
> Patch702: linux-2.6.33-vfs-tracepoints.patch
>
> #
> # Fix the slab timer to not be a power hog
> #
> Patch703: linux-2.6.35-slab-timer.patch
>
> #
> # Fix Linux deliberately skewing the timer for
> # historic reasons that are no longer true.
> #
> Patch704: linux-2.6.35-dont-skew-the-tick.patch
>
>
> #
> # End of the boot time and power patches
> #
> ################################################################
> #####
>
>
>
> ################################################################
> #####
> #
> # All other patches
> #
>
>
>
>
> # turn on "print fatal signals" by default, so that we can debug /sbin/init
> # crashes
> Patch705: linux-2.6.35-fatal-signals.patch
>
>
> BuildRoot: %{_tmppath}/kernel-%{KVERREL}-root
>
>
>
> #
> # This macro creates a kernel-<subpackage>-devel package.
> #     %%kernel_devel_package <subpackage> <pretty-name>
> #
> %define kernel_devel_package() \
> %package -n kernel-%{?1:%{1}-}devel\
> Summary: Development package for building kernel modules to match
> the %{?2:%{2} }kernel\
> Group: System/Kernel\
> Provides: kernel%{?1:-%{1}}-devel = %{version}-%{release}\
> Provides: kernel-devel = %{version}-%{release}%{?1:-%{1}}\
> Provides: kernel-devel = %{version}-%{release}%{?1:-%{1}}\
> Provides: kernel-devel-uname-r = %{KVERREL}%{?1:-%{1}}\
> Requires: kernel%{?1:-%{1}} = %{version}-%{release}\
> Requires: hardlink \
> AutoReqProv: no\
> Requires(pre): /usr/bin/find\
> %description -n kernel%{?1:-%{1}}-devel\
> This package provides kernel headers and makefiles sufficient to build 
> modules\
> against the %{?2:%{2} }kernel package.\
> %{nil}
>
> #
> # This macro creates a kernel-<subpackage> and its -devel too.
> #     %%define variant_summary The Linux kernel compiled for <configuration>
> #     %%kernel_variant_package [-n <pretty-name>] <subpackage>
> #
> %define kernel_variant_package(n:) \
> %package -n kernel-%1\
> Summary: %{variant_summary}\
> Group: System/Kernel\
> %kernel_reqprovconf\
> %{nil}
>
>
> # First the auxiliary packages of the main kernel package.
> %kernel_devel_package
>
>
>
>
> # Now, each variant package.
>
> %ifarch %all_x86
>
>
>
>
> %endif
>
> %ifarch %{all_arm}
>
> %kernel_devel_package n900
> %description -n kernel-n900
> This package contains the kernel optimized for the Nokia N900 device
>
> #Put other ARM variants here
>
> %endif
>
>
> %prep
>
> # First we unpack the kernel tarball.
> # If this isn't the first make prep, we use links to the existing clean 
> tarball
> # which speeds things up quite a bit.
>
> # Update to latest upstream.
> %if 0%{?released_kernel}
> %define vanillaversion 2.6.%{base_sublevel}
> # released_kernel with stable_update available case
> %if 0%{?stable_update}
> %define vanillaversion 2.6.%{base_sublevel}.%{stable_update}
> %endif
> # non-released_kernel case
> %else
> %if 0%{?rcrev}
> %define vanillaversion 2.6.%{upstream_sublevel}-rc%{rcrev}
> %endif
> %else
> # pre-{base_sublevel+1}-rc1 case
> %endif
>
>
> #
> # Unpack the kernel tarbal
> #
> %setup -q -c
> cd linux-%{kversion}
>
>
> #
> # The add an -rc patch if needed
> #
> %if 0%{?rcrev}
> # patch-2.6.%{upstream_sublevel}-rc%{rcrev}.bz2
> %patch00 -p1
> %endif
>
>
> #
> # Then apply all the patches
> #
> # Reminder of the patch filename format:
> # linux-<version it is supposed to be
> upstream>-<description-separated-with-dashes>.patch
> #
>
>
> #
> # Stable patch - critical bugfixes
> #
>
> # patch-2.6.35.9.bz2
> %patch1 -p1
>
>
> #
> # Patch to add a "nonintconfig" option to the Makefile
> # needed for unattended builds
> #
> # linux-2.6-build-nonintconfig.patch
> %patch2 -p1
>
>
>
> ################################################################
> #####
> #
> # Direct Backport section.. only patches already in Linus' or maintainer git 
> trees
> # (for linux-next) should go here.
> # We will regularly drop patches from this section as we rebase to newer
> # kernels.
> #
>
>
> # linux-2.6.36-PM-Runtime-Lenient-generic-runtime-pm-callbacks.patch
> %patch100 -p1
>
>
> # cherry picking the important security/corruption fixes from
> # the stable series
>
>
> # Kernel CVE patches - these go last in the backport section
> # no non-cve patches should go here!
>
>
>
> #
> # End of the Direct Backports section
> #
> ################################################################
> #####
>
>
>
>
>
> ################################################################
> #####
> #
> # Moorestown and Medfield architecture patches
> # Section maintainer: Arjan van de Ven <[email protected]>
> #
>
> #
> # The main consolidated MRST/MFLD tree from
> # git://git.kernel.org/pub/scm/linux/kernel/git/alan/linux-2.6-mid-ref
> #
>
> # wifi/bluetooth connectivity
> # linux-2.6.36-wl1271-add-platform_data.patch
> %patch200 -p1
>
> #
> # End of the Moorestown and Medfield architecture patches
> #
> ################################################################
> #####
>
>
>
>
> ################################################################
> #####
> #
> # Nokia N900 patches
> # Section maintainer: Ilkka Koskinen <[email protected]>
> #
>
> # Hacks
> # linux-2.6-usb-musb-add-mA-and-charger-sysfs-entries.patch
> %patch300 -p1
> # linux-2.6-usb-musb-add-suspend-sysfs-entry.patch
> %patch301 -p1
> # linux-2.6-usb-otg-add-detect_charger-field-to-otg_transceiver.patch
> %patch302 -p1
> # linux-2.6-OMAP2-3-clock-implement-clock-rate-parent-change-not.patch
> %patch303 -p1
> # linux-2.6-PM-export-missing-symbols.patch
> %patch304 -p1
>
> # Touch screen
> # linux-2.6.38-input-touchscreen-introduce-tsc2005-driver.patch
> %patch305 -p1
> # linux-2.6.38-omap-rx-51-enable-tsc2005.patch
> %patch306 -p1
>
> # Bluetooth
> # linux-2.6-Bluetooth-Support-for-n900-bluetooth-hardware.patch
> %patch307 -p1
> # linux-2.6-hci_h4p-Fix-module-auto-loading.patch
> %patch308 -p1
>
> # Ambient light sensor
> # linux-2.6.36-omap-rx51-Platform-support-for-tsl2563-ALS.patch
> %patch309 -p1
>
> # Accelerometer
> # linux-2.6.36-omap-rx51-Platform-support-for-lis3lv02d-acceleromet.patch
> %patch310 -p1
>
> #Aic34b
> # FM TX, headphone, TV-out and basic jack detection
> # linux-2.6-omap-rx51-Add-platform_data-for-tlv320aic3x-with-res.patch
> %patch311 -p1
> # linux-2.6-omap-rx51-Use-REGULATOR_SUPPLY-macro-when-initializi.patch
> %patch312 -p1
> # linux-2.6-omap-rx51-Add-supply-and-data-for-the-tpa6130a2-head.patch
> %patch313 -p1
> # linux-2.6-ASoC-RX-51-Add-Jack-Function-kcontrol.patch
> %patch314 -p1
> # linux-2.6-ASoC-RX-51-Add-basic-jack-detection.patch
> %patch315 -p1
> # linux-2.6-ASoC-RX-51-Add-stereo-audio-output-to-AV-jack.patch
> %patch316 -p1
> # linux-2.6-V4L-DVB-radio-si4713-Release-i2c-adapter-in-driver-c.patch
> %patch317 -p1
> # linux-2.6-V4L-DVB-radio-si4713-Add-regulator-framework-support.patch
> %patch318 -p1
> # linux-2.6-omap-rx51-Set-regulator-V28-always-on.patch
> %patch319 -p1
> # linux-2.6-omap-rx51-Add-initialization-and-platform-data-for-S.patch
> %patch320 -p1
> # linux-2.6-ASoC-RX-51-Add-support-for-FM-transmitter.patch
> %patch321 -p1
>
> # Earpiece and headset support
> # linux-2.6-ASoC-RX-51-Add-aic34b_dummy-driver-only-for-the-RX-5.patch
> %patch322 -p1
> # linux-2.6-omap-rx51-Add-second-instance-of-the-TLV320AIC34-cod.patch
> %patch323 -p1
> # linux-2.6-ASoC-RX-51-Add-support-for-earpiece.patch
> %patch324 -p1
> # linux-2.6-ASoC-RX-51-Add-mic-input-to-AV-jack.patch
> %patch325 -p1
> # linux-2.6-SoC-RX-51-Add-route-for-AIC34B-generated-mic-bias.patch
> %patch326 -p1
>
> # Cellular modem support
> #
> linux-2.6-OMAP2-3-PRCM-export-cm_read_mod_reg-and-cm_write_mod.patch
> %patch327 -p1
> # linux-2.6-HSI-Introducing-HSI-framework.patch
> %patch328 -p1
> # linux-2.6-HSI-omap_ssi-Introducing-OMAP-SSI-driver.patch
> %patch329 -p1
> # linux-2.6-HSI-omap_ssi-Add-OMAP-SSI-to-the-kernel-configuratio.patch
> %patch330 -p1
> # linux-2.6-HSI-hsi_char-Add-HSI-char-device-driver.patch
> %patch331 -p1
> # linux-2.6-HSI-hsi_char-Add-HSI-char-device-kernel-configuratio.patch
> %patch332 -p1
> # linux-2.6-HSI-Add-HSI-API-documentation.patch
> %patch333 -p1
> # linux-2.6-HSI-ssip-Add-SSI-protocol-to-the-kernel-configuratio.patch
> %patch334 -p1
> # linux-2.6-HSI-cmt_speech-Add-CMT_SPEECH-driver.patch
> %patch335 -p1
> # linux-2.6-HSI-cmt_speech-Add-CMT-SPEECH-to-the-configuration.patch
> %patch336 -p1
> # linux-2.6-CMT-Introduces-the-Nokia-CMT-driver.patch
> %patch337 -p1
> # linux-2.6-CMT-Add-Nokia-CMT-driver-to-the-configuration.patch
> %patch338 -p1
> # linux-2.6-rx51-Add-SSI-related-support-to-board.patch
> %patch339 -p1
> # linux-2.6-HSI-ssip-Introducing-SSI-protocol-aka-McSAAB.patch
> %patch340 -p1
> # linux-2.6-HSI-cmt_speech-Adapt-to-kernel-API-changes-in-2.6.35.patch
> %patch341 -p1
>
> # TI dspbridge driver
> # linux-2.6.36-tidspbridge.patch
> %patch342 -p1
>
> # lp5523 and corresponding platform data for rx51 board
> # linux-2.6-37-leds-driver-for-LP5523-chips-from-National-Semicondu.patch
> %patch343 -p1
> # linux-2.6.37-omap3-rx51-Platform-support-for-lp5523-led-chip.patch
> %patch344 -p1
>
> # omap3isp-rx51 driver
> # linux-2.6-omap3isp-rx51.patch
> %patch345 -p1
>
> #Bugfixes
> # linux-2.6.37-N900-Set-keypad-slide-gpio-as-active-low.patch
> %patch346 -p1
>
> #General
> # linux-2.6.37-timer-Added-usleep_range-timer.patch
> %patch347 -p1
>
> #N900 defconfig
> # linux-2.6-Updated-rx51_defconfig.patch
> %patch348 -p1
>
> # GPU
> # linux-2.6-gpu-pvr-Add-PVR-GPU-driver.patch
> %patch349 -p1
> # linux-2.6-gpu-pvr-compilation-fixes-for-kernel-2.6.33.patch
> %patch350 -p1
>
> # TWL4030 MADC (Battery Charging)
> # linux-2.6-mfd-twl4030-Driver-for-twl4030-madc-module.patch
> %patch351 -p1
> # linux-2.6-mfd-implement-twl4030-poweroff.patch
> %patch352 -p1
> # linux-2.6-HACK-mfd-twl4030-power-disable-scripts.patch
> %patch353 -p1
>
> #Bugfixes
> # linux-2.6.36-Adding-CS_FEAT_BURST_MODE-for-cmt_speech-driver.patch
> %patch354 -p1
>
> # linux-2.6.35-CMT-Add-field-for-irq-flags-to-driver-platform-data.patch
> %patch355 -p1
> # linux-2.6.35-board-rx51-set-cmt_rst_ind_flags.patch
> %patch356 -p1
>
> # linux-2.6.35-HSI-cmt_speech-Free-allocated-pages-in-case-open-fai.patch
> %patch357 -p1
> # linux-2.6.35-HSI-cmt_speech-avoid-GFP_ATOMIC-in-cs_char_open.patch
> %patch358 -p1
> # linux-2.6.35-HSI-ssip-add-ssip_slave_running-to-ssi_protocol-inte.patch
> %patch359 -p1
> # linux-2.6.35-HSI-cmt_speech-return-error-if-HSI-port-not-configur.patch
> %patch360 -p1
>
> # usb charger platform device support
> # isp1704 usb charger detection driver
> # linux-2.6.37-power_supply-add-isp1704-charger-detection-driver.patch
> %patch361 -p1
> # linux-2.6.37-omap-rx51-add-support-for-USB-chargers.patch
> %patch362 -p1
> # linux-2.6.37-power_supply-add-types-for-USB-chargers.patch
> %patch363 -p1
> # linux-2.6-usb-musb-ignore-spurious-SESSREQ-interrupts-v1.patch
> %patch364 -p1
> # linux-2.6-usb-musb-ignore-spurious-SESSREQ-interrupts-v2.patch
> %patch365 -p1
> # linux-2.6-power_supply-isp1704-correct-length-for-storing-mode.patch
> %patch366 -p1
> # linux-2.6-power_supply-isp1704-Detect-HUB-Host-chargers.patch
> %patch367 -p1
> # linux-2.6-power_supply-isp1704-Set-isp-dev-before-anything-nee.patch
> %patch368 -p1
> # linux-2.6-power_supply-isp1704-Detect-charger-after-probe.patch
> %patch369 -p1
> # linux-2.6-power_supply-Add-maximum-current-property.patch
> %patch370 -p1
> # linux-2.6-HACK-sysfs_notify-support-for-isp1704-charger-driver.patch
> %patch371 -p1
> # linux-2.6-musb_gadget-notifier-hack.patch
> %patch372 -p1
>
> # Fixes
> # linux-2.6.36-wl1251-Use-MODULE_ALIAS-macro-at-correct-postion-for.patch
> %patch373 -p1
> # linux-2.6.37-OMAP3-DMA-Errata-i541-sDMA-FIFO-draining-does-not-fi.patch
> %patch374 -p1
>
> # Introduce EEM support in g_nokia which should fix usb networking
> # linux-2.6.37-EEM-support-for-g_nokia.patch
> %patch375 -p1
>
>
>
> #
> # End of the Nokia N900 patches
> #
> ################################################################
> #####
>
>
>
>
> ################################################################
> #####
> #
> # Netbook hardware patches
> # Section maintainer: Yong Wang <[email protected]>
> #
>
> #
> # Quiet down some printks that shows up falsly during boot
> #
>
>
>
> #
> # End of the Netbook hardware patches
> #
> ################################################################
> #####
>
>
> ################################################################
> #####
> #
> # IVI hardware patches
> # Section maintainer: Yin Kangkai <[email protected]>
> #
>
>
>
>
> #
> # End of the IVI hardware patches
> #
> ################################################################
> #####
>
>
> ################################################################
> #####
> #
> # Intel Integrated Graphics patches
> # Section maintainer:  Li Peng <[email protected]>
> #
>
> #
> # KMS (note: upstream backports go in the backport section higher up!)
> #
> #linux-2.6.29-kms-edid-cache.patch
> #linux-2.6.29-kms-run-async.patch
> #linux-2.6.29-kms-after-sata.patch
>
>
> #
> # End of the Intel Integrated Graphics patches
> #
> ################################################################
> #####
>
>
>
> ################################################################
> #####
> #
> # Boot time and power patches
> # Section maintainer:  Arjan van de Ven <[email protected]
> #
>
> #
> # Patch to try mounting / before all devices (the mouse)
> # are done probing. This saves several seconds of boot time.
> #
> # linux-2.6.29-dont-wait-for-mouse.patch
> %patch700 -p1
> #
> # Patch to support the old sreadahead versions
> #
> # linux-2.6.29-sreadahead.patch
> %patch701 -p1
>
>
>
> #
> # Patches to help PowerTOP
> #
> # linux-2.6.33-vfs-tracepoints.patch
> %patch702 -p1
>
> #
> # Fix the slab timer to not be a power hog
> #
> # linux-2.6.35-slab-timer.patch
> %patch703 -p1
>
> #
> # Fix Linux deliberately skewing the timer for
> # historic reasons that are no longer true.
> #
> # linux-2.6.35-dont-skew-the-tick.patch
> %patch704 -p1
>
>
> #
> # End of the boot time and power patches
> #
> ################################################################
> #####
>
>
>
> ################################################################
> #####
> #
> # All other patches
> #
>
>
>
>
> # turn on "print fatal signals" by default, so that we can debug /sbin/init
> # crashes
> # linux-2.6.35-fatal-signals.patch
> %patch705 -p1
>
> # Drop some necessary files from the source dir into the buildroot
> cp $RPM_SOURCE_DIR/config-* .
> cp %{SOURCE15} .
>
> #
> # Add the compat-wireless package
> #
> tar -axf %{SOURCE1}
>
> # Dynamically generate kernel .config files from config-* files
> make -f %{SOURCE20} VERSION=%{version} configs
>
>
> # Any further pre-build tree manipulations happen here.
>
> chmod +x scripts/checkpatch.pl
>
> cp %{SOURCE10} Documentation/
>
>
> mkdir configs
>
> #
> # We want to run the config checks of all configurations for all architectures
> always.
> # That way, developers immediately found out if they forget to enable
> not-their-native
> # architecture. It's cheap to run anyway.
> #
>
> # now run oldconfig over all the config files
> for i in kernel-*.config
> do
>   mv $i .config
>   Arch="x86"
>
>   #get ARCH from .config file for other platforms
>   if [ `cat .config | grep -c CONFIG_ARM=y` -eq 1 ]; then
>     Arch="arm"
>   fi
>
>   # make oldconfig > /dev/null
>   echo Doing $i
>   make ARCH=$Arch %{oldconfig_target} > /dev/null
>   echo "# $Arch" > configs/$i
>   cat .config >> configs/$i
> done
>
> #
> # get rid of unwanted files resulting from patch fuzz
> # (not that we can have any)
> #
> find . \( -name "*.orig" -o -name "*~" \) -exec rm -f {} \; >/dev/null
>
> cd ..
>
>
> ###
> ### build
> ###
> %build
>
>
> cp_vmlinux()
> {
>   eu-strip --remove-comment -o "$2" "$1"
> }
>
> BuildKernel() {
>     MakeTarget=$1
>     KernelImage=$2
>     TargetArch=$3
>     Flavour=$4
>     InstallName=${5:-vmlinuz}
>
>     # Pick the right config file for the kernel we're building
>     Config=kernel${Flavour:+-${Flavour}}.config
>     DevelDir=/usr/src/kernels/%{KVERREL}${Flavour:+-${Flavour}}
>
>     # When the bootable image is just the ELF kernel, strip it.
>     # We already copy the unstripped file into the debuginfo package.
>     if [ "$KernelImage" = vmlinux ]; then
>       CopyKernel=cp_vmlinux
>     else
>       CopyKernel=cp
>     fi
>
>     KernelVer=%{version}-%{release}${Flavour:+-${Flavour}}
>     ExtraVer=%{?stablerev}%{?rctag}-%{release}${Flavour:+-${Flavour}}
>     Arch="x86"
> %ifarch %{all_arm}
>     Arch="arm"
> %endif
>
>
>     if [ "$Arch" = "$TargetArch" ]; then
>         echo BUILDING A KERNEL FOR ${Flavour} %{_target_cpu}...
> ${KernelVer}
>         echo USING ARCH=$Arch
>
>         # make sure EXTRAVERSION says what we want it to say
>         perl -p -i -e "s/^EXTRAVERSION.*/EXTRAVERSION = ${ExtraVer}/"
> Makefile
>
>         # and now to start the build process
>
>         make -s mrproper
>         cp configs/$Config .config
>
>         make -s ARCH=$Arch %{oldconfig_target} > /dev/null
>         make -s CONFIG_DEBUG_SECTION_MISMATCH=y
> ARCH=$Arch %{?_smp_mflags} $MakeTarget %{?sparse_mflags}
>         make -s CONFIG_DEBUG_SECTION_MISMATCH=y
> ARCH=$Arch %{?_smp_mflags} modules %{?sparse_mflags} || exit 1
>
> %ifnarch %{all_arm}
>
>       cd compat-wireless-%{compat_wireless_ver}
>       make -s CONFIG_DEBUG_SECTION_MISMATCH=y ARCH=$Arch KLIB=../
> KLIB_BUILD=../ %{?_smp_mflags}
>       cd ..
> %endif
>
>         # Start installing the results
>         mkdir -p $RPM_BUILD_ROOT/%{image_install_path}
>         install -m 644 .config $RPM_BUILD_ROOT/boot/config-$KernelVer
>         install -m 644 System.map
> $RPM_BUILD_ROOT/boot/System.map-$KernelVer
>         touch $RPM_BUILD_ROOT/boot/initrd-$KernelVer.img
>         if [ -f arch/$Arch/boot/zImage.stub ]; then
>           cp arch/$Arch/boot/zImage.stub
> $RPM_BUILD_ROOT/%{image_install_path}/zImage.stub-$KernelVer || :
>         fi
>         $CopyKernel $KernelImage \
>
>       $RPM_BUILD_ROOT/%{image_install_path}/$InstallName-$KernelVer
>         chmod 755
> $RPM_BUILD_ROOT/%{image_install_path}/$InstallName-$KernelVer
>
>         mkdir -p $RPM_BUILD_ROOT/lib/modules/$KernelVer
>         make -s ARCH=$Arch INSTALL_MOD_PATH=$RPM_BUILD_ROOT
> modules_install KERNELRELEASE=$KernelVer
> %ifnarch %{all_arm}
>         make -s ARCH=$Arch INSTALL_MOD_PATH=$RPM_BUILD_ROOT
> vdso_install KERNELRELEASE=$KernelVer
>
>       cd compat-wireless-%{compat_wireless_ver}
>       make -s -i ARCH=$Arch KLIB=$RPM_BUILD_ROOT/lib/modules/$KernelVer
> KLIB_BUILD=$RPM_BUILD_ROOT/lib/modules/$KernelVer/build
> KMODDIR="../../../updates" install
>       rm -rf $RPM_BUILD_ROOT/lib/modules/$KernelVer/lib
>       cd ..
>
> %endif
>       mkdir -p $RPM_BUILD_ROOT/lib/modules/$KernelVer/updates
>
>         # And save the headers/makefiles etc for building modules against
>         #
>         # This all looks scary, but the end result is supposed to be:
>         # * all arch relevant include/ files
>         # * all Makefile/Kconfig files
>         # * all script/ files
>
>         rm -f $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
>         rm -f $RPM_BUILD_ROOT/lib/modules/$KernelVer/source
>         mkdir -p $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
>         (cd $RPM_BUILD_ROOT/lib/modules/$KernelVer ; ln -s build source)
>         # dirs for additional modules per module-init-tools,
> kbuild/modules.txt
>         # first copy everything
>         cp --parents `find  -type f -name "Makefile*" -o -name "Kconfig*"`
> $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
>         cp Module.symvers
> $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
>         cp System.map $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
>         if [ -s Module.markers ]; then
>           cp Module.markers
> $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
>         fi
>         # then drop all but the needed Makefiles/Kconfig files
>         rm -rf
> $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/Documentation
>         rm -rf $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/scripts
>         rm -rf $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/include
>         cp .config $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
>         cp -a scripts $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
>         if [ -d arch/%{_arch}/scripts ]; then
>           cp -a arch/%{_arch}/scripts
> $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/arch/%{_arch} || :
>         fi
>         if [ -f arch/%{_arch}/*lds ]; then
>           cp -a arch/%{_arch}/*lds
> $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/arch/%{_arch}/ || :
>         fi
>         rm -f $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/scripts/*.o
>         rm -f
> $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/scripts/*/*.o
>         cp -a --parents arch/$Arch/include
> $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
> %ifarch %{all_arm}
>        cp -a --parents arch/arm/mach-*/include
> $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
>        cp -a --parents arch/arm/plat-*/include
> $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
> %endif
>         mkdir -p $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/include
>         cd include
>         cp -a acpi asm-generic config crypto drm generated keys linux
> math-emu media mtd net pcmcia rdma rxrpc scsi sound video trace
> $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/include
>
>         # Make sure the Makefile and version.h have a matching timestamp
> so that
>         # external modules can be built
>         touch -r $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/Makefile
> $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/include/linux/version.h
>         touch -r $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/.config
> $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/include/linux/autoconf.h
>         # Copy .config to include/config/auto.conf so "make prepare" is
> unnecessary.
>         cp $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/.config
> $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/include/config/auto.conf
>         cd ..
>
>         #
>         # save the vmlinux file for kernel debugging into the kernel-*-devel
> rpm
>         #
>
>         cp vmlinux $RPM_BUILD_ROOT/lib/modules/$KernelVer
>
>         find $RPM_BUILD_ROOT/lib/modules/$KernelVer -name "*.ko" -type
> f >modnames
>
>         # mark modules executable so that strip-to-file can strip them
>         xargs --no-run-if-empty chmod u+x < modnames
>
>         # Generate a list of modules for block and networking.
>
>         fgrep /drivers/ modnames | xargs --no-run-if-empty nm -upA |
>         sed -n 's,^.*/\([^/]*\.ko\):  *U \(.*\)$,\1 \2,p' > drivers.undef
>
>         collect_modules_list()
>         {
>           sed -r -n -e "s/^([^ ]+) \\.?($2)\$/\\1/p" drivers.undef |
>           LC_ALL=C sort -u >
> $RPM_BUILD_ROOT/lib/modules/$KernelVer/modules.$1
>         }
>
>         collect_modules_list networking \
>
> 'register_netdev|ieee80211_register_hw|usbnet_probe'
>         collect_modules_list block \
>
> 'ata_scsi_ioctl|scsi_add_host|blk_init_queue|register_mtd_blktrans'
>
>         # remove files that will be auto generated by depmod at rpm -i time
>         for i in alias ccwmap dep ieee1394map inputmap isapnpmap ofmap
> pcimap seriomap symbols usbmap
>         do
>           rm -f $RPM_BUILD_ROOT/lib/modules/$KernelVer/modules.$i
>         done
>
>         # Move the devel headers out of the root file system
>         mkdir -p $RPM_BUILD_ROOT/usr/src/kernels
>         mv $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
> $RPM_BUILD_ROOT/$DevelDir
>         ln -sf ../../..$DevelDir
> $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
>     fi
> }
>
> ###
> # DO it...
> ###
>
> # prepare directories
> rm -rf $RPM_BUILD_ROOT
> mkdir -p $RPM_BUILD_ROOT/boot
>
> cd linux-%{kversion}
>
>
> BuildKernel %make_target %kernel_image arm n900
>
>
>
>
> ###
> ### install
> ###
>
> %define
> install  %{?_enable_debug_packages:%{?buildsubdir:%{debug_package}}}\
> %%install
>
>
> %install
>
> cd linux-%{kversion}
>
> #
> # the perf utility
> #
>
> rm -rf $RPM_BUILD_ROOT/lib/firmware
>
>
> ###
> ### clean
> ###
>
> %clean
> rm -rf $RPM_BUILD_ROOT
>
> ###
> ### scripts
> ###
>
> #
> # This macro defines a %%post script for a kernel*-devel package.
> #     %%kernel_devel_post <subpackage>
> #
> %define kernel_devel_post() \
> %{expand:%%post -n kernel-%{?1:%{1}-}devel}\
> if [ -x /usr/sbin/hardlink ]\
> then\
>     (cd /usr/src/kernels/%{KVERREL}%{?1:-%{1}} &&\
>      /usr/bin/find . -type f | while read f; do\
>        hardlink -c /usr/src/kernels/*/$f $f\
>      done)\
> fi\
> %{nil}
>
> # This macro defines a %%posttrans script for a kernel package.
> #     %%kernel_variant_posttrans [-v <subpackage>] [-s <s> -r <r>]
> <mkinitrd-args>
> # More text can follow to go at the end of this variant's %%post.
> #
> %define kernel_variant_posttrans(s:r:v:) \
> %{expand:%%posttrans -n kernel-%{?-v*}}\
> /sbin/new-kernel-pkg --package kernel%{?-v:-%{-v*}}
> --rpmposttrans %{KVERREL}%{?-v:-%{-v*}} || exit $?\
> %{nil}
>
> #
> # This macro defines a %%post script for a kernel package and its devel
> package.
> #     %%kernel_variant_post [-v <subpackage>] [-s <s> -r <r>] <mkinitrd-args>
> # More text can follow to go at the end of this variant's %%post.
> #
> %define kernel_variant_post(s:r:v:) \
> %{expand:%%kernel_devel_post %{?-v*}}\
> %{expand:%%kernel_variant_posttrans %{?-v*}}\
> %{expand:%%post -n kernel-%{?-v*}}\
> /sbin/new-kernel-pkg --package kernel%{?-v:-%{-v*}} --mkinitrd --depmod
> --install %{*} %{KVERREL}%{?-v:-%{-v*}} || exit $?\
> %{nil}
>
> #
> # This macro defines a %%preun script for a kernel package.
> #     %%kernel_variant_preun <subpackage>
> #
> %define kernel_variant_preun() \
> %{expand:%%preun -n kernel-%{?1}}\
> /sbin/new-kernel-pkg --rminitrd --rmmoddep --remove %{KVERREL}%{?1:-%{1}}
> || exit $?\
> %{nil}
>
>
> %ifarch %all_x86
>
>
>
>
>
> %endif
>
> %ifarch %{all_arm}
>
> %kernel_variant_preun n900
> %kernel_variant_post -v n900
>
> %endif
>
> ###
> ### file lists
> ###
>
>
>
> #
> # This macro defines the %%files sections for a kernel package
> # and its devel packages.
> #     %%kernel_variant_files [-k vmlinux] [-a <extra-files-glob>] [-e
> <extra-nonbinary>] <condition> <subpackage>
> #
> %define kernel_variant_files(a:e:k:) \
> %ifarch %{1}\
> %{expand:%%files -n kernel%{?2:-%{2}}}\
> %defattr(-,root,root)\
> /%{image_install_path}/%{?-k:%{-k*}}%{!?-k:vmlinuz}-%{KVERREL}%{?2:-%{2}}\
> /boot/System.map-%{KVERREL}%{?2:-%{2}}\
> #/boot/symvers-%{KVERREL}%{?2:-%{2}}.gz\
> /boot/config-%{KVERREL}%{?2:-%{2}}\
> %{?-a:%{-a*}}\
> %dir /lib/modules/%{KVERREL}%{?2:-%{2}}\
> /lib/modules/%{KVERREL}%{?2:-%{2}}/kernel\
> /lib/modules/%{KVERREL}%{?2:-%{2}}/updates\
> /lib/modules/%{KVERREL}%{?2:-%{2}}/build\
> /lib/modules/%{KVERREL}%{?2:-%{2}}/source\
> %ifnarch %{all_arm}\
> /lib/modules/%{KVERREL}%{?2:-%{2}}/vdso\
> %endif\
> /lib/modules/%{KVERREL}%{?2:-%{2}}/modules.block\
> /lib/modules/%{KVERREL}%{?2:-%{2}}/modules.dep.bin\
> /lib/modules/%{KVERREL}%{?2:-%{2}}/modules.alias.bin\
> /lib/modules/%{KVERREL}%{?2:-%{2}}/modules.symbols.bin\
> /lib/modules/%{KVERREL}%{?2:-%{2}}/modules.networking\
> /lib/modules/%{KVERREL}%{?2:-%{2}}/modules.order\
> /lib/modules/%{KVERREL}%{?2:-%{2}}/modules.builtin*\
> %ghost /boot/initrd-%{KVERREL}%{?2:-%{2}}.img\
> %{?-e:%{-e*}}\
> %{expand:%%files -n kernel-%{?2:%{2}-}devel}\
> %defattr(-,root,root)\
> %verify(not mtime) /usr/src/kernels/%{KVERREL}%{?2:-%{2}}\
> /lib/modules/%{KVERREL}%{?2:-%{2}}/vmlinux \
> %endif\
> %{nil}
>
>
>
>
> %kernel_variant_files %{all_arm} n900
>
>
> ================================================================
> ===
>
> _______________________________________________
> MeeGo-commits mailing list
> [email protected]
> http://lists.meego.com/listinfo/meego-commits
_______________________________________________
MeeGo-packaging mailing list
[email protected]
http://lists.meego.com/listinfo/meego-packaging

Reply via email to