]>
Commit | Line | Data |
---|---|---|
11ca4f20 MT |
1 | ############################################################################### |
2 | # IPFire.org - An Open Source Firewall Solution # | |
3 | # Copyright (C) - IPFire Development Team <info@ipfire.org> # | |
4 | ############################################################################### | |
5 | ||
6 | name = u-boot | |
7 | version = 2011.09 | |
8 | release = 1 | |
9 | sup_arches = armv5tel armv7hl | |
10 | ||
11 | groups = Development/Tools | |
12 | url = http://www.denx.de/wiki/U-Boot | |
13 | license = GPLv2+ | |
14 | summary = U-Boot utilities. | |
15 | ||
16 | description | |
17 | U-Boot is a Boot Loader, i.e. its primary purpose in the shipping | |
18 | system is to load some operating system. | |
19 | end | |
20 | ||
21 | source_dl = ftp://ftp.denx.de/pub/u-boot/ | |
22 | sources = %{thisapp}.tar.bz2 | |
23 | ||
24 | build | |
25 | build | |
26 | while read arch platform target; do | |
27 | # Skip all other architectures. | |
28 | [ "${arch}" = "%{DISTRO_ARCH}" ] || continue | |
29 | ||
30 | builddir="$(pwd)/build-${platform}" | |
31 | mkdir -p ${builddir} | |
32 | ||
33 | make O=${builddir} ${platform}_config | |
34 | make O=${builddir} ${builddir}/${target} | |
35 | done < %{DIR_SOURCE}/targets | |
36 | ||
37 | # Build tools. | |
38 | # Need to create a config because the tools won't build without. | |
39 | make sheevaplug_config | |
40 | ||
41 | make tools HOSTCC="gcc %{CFLAGS}" HOSTSTRIP="/bin/true" CROSS_COMPILE="" | |
42 | make env HOSTCC="gcc %{CFLAGS}" HOSTSTRIP="/bin/true" | |
43 | end | |
44 | ||
45 | install | |
46 | while read arch platform target; do | |
47 | # Skip all other architectures. | |
48 | [ "${arch}" = "%{DISTRO_ARCH}" ] || continue | |
49 | ||
50 | builddir="build-${platform}" | |
51 | installdir="%{BUILDROOT}/usr/lib/%{name}/${platform}" | |
52 | mkdir -pv ${installdir} | |
53 | ||
54 | install -D -m 644 ${builddir}/${target} ${installdir} | |
55 | install -D -m 644 ${builddir}/u-boot ${installdir}/uboot.elf | |
56 | done < %{DIR_SOURCE}/targets | |
57 | ||
58 | # Install tools. | |
59 | mkdir -pv %{BUILDROOT}/usr/bin %{BUILDROOT}/usr/share/man/man1 | |
60 | install -p -m 0755 tools/mkimage %{BUILDROOT}/usr/bin | |
61 | install -p -m 0644 doc/mkimage.1 %{BUILDROOT}/usr/share/man/man1 | |
62 | install -p -m 0755 tools/env/fw_printenv %{BUILDROOT}/usr/bin | |
63 | ln -svf fw_printenv %{BUILDROOT}/usr/bin/fw_setenv | |
64 | end | |
65 | end | |
66 | ||
67 | packages | |
68 | package %{name} | |
69 | ||
70 | package %{name}-tools | |
71 | summary = U-Boot utilities. | |
72 | description | |
73 | This package contains a few U-Boot utilities - mkimage | |
74 | for creating boot images and fw_printenv/fw_setenv for | |
75 | manipulating the boot environment variables. | |
76 | end | |
77 | ||
78 | files | |
79 | /usr/bin | |
80 | /usr/share/man/man1 | |
81 | end | |
82 | end | |
42945a97 MT |
83 | |
84 | package %{name}-debuginfo | |
85 | template DEBUGINFO | |
86 | end | |
11ca4f20 | 87 | end |