Commit Graph

106 Commits (4cc6898f944b6e51df2f61dfb9e3fc22c39d8119)

Author SHA1 Message Date
Luka Perkov 1b9673d79a image: remove spaces from toupper function
The extra prefix space is passed to the caller.

Signed-off-by: Luka Perkov <luka@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@38855 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-11-18 22:23:38 +00:00
Luka Perkov c872fd9a56 image: don't force ubifs journal size
Small journal size can lead to problems if nand flash is too big. By default
ubifs will use ~12% of volume size or a maximum of 8MiB.

Signed-off-by: Luka Perkov <luka@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@38799 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-11-14 01:35:21 +00:00
Luka Perkov eb680c576e build: make MkuImage more generic
Signed-off-by: Luka Perkov <luka@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@38516 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-10-23 22:16:09 +00:00
Luka Perkov f0662fc03c build: set owner root for all files on ubifs creation
When creating an image it makes no sense to have files owned by
the uid and gid on the host (and even creates a bug when for
example dropbear authorized_keys is included via env/files).

Signed-off-by: Joris de Vries <joris@apptrician.nl>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@38442 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-10-18 00:11:20 +00:00
Luka Perkov 4f1464dcef build: move mkits.sh script to more common place
Signed-off-by: Luka Perkov <luka@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@38430 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-10-16 10:29:50 +00:00
Luka Perkov 9eb69ef0dc ubifs: remove breaking commas from ubi calls
The extra commas get output by the shell resulting in errors since
the commands that get called with those extra commas are then
malformed.

Signed-off-by: Joris de Vries <joris@apptrician.nl>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@38419 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-10-15 21:37:31 +00:00
Luka Perkov 5f4047589a ubifs: when creating ubi(fs) images profile originated arguments have priority
Signed-off-by: Luka Perkov <luka@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@38381 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-10-13 03:35:15 +00:00
Luka Perkov 75f47798f9 image: introduce MkuImageARM function
Signed-off-by: Luka Perkov <luka@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@38380 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-10-13 03:35:14 +00:00
Luka Perkov f6ccd395dd ubifs: enable building modular images
Now it is possible to build ubi/ubifs images for only selected boards inside
single target.

Signed-off-by: Luka Perkov <luka@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@38375 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-10-12 21:44:48 +00:00
Luka Perkov 3684777fc7 image: if possible use profile name when building .tar.gz images
Signed-off-by: Luka Perkov <luka@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@38374 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-10-12 21:44:46 +00:00
Luka Perkov 69507e8413 build: extend menu with few ubifs options
Signed-off-by: Luka Perkov <luka@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@38303 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-10-04 10:49:47 +00:00
Gabor Juhos e51a6a6d99 image: generate separate jffs2 images w/o padding
The new root.jffs2-*-raw images can be used for firmware
images with custom padding requirements.

Signed-off-by: Gabor Juhos <juhosg@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@38196 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-09-25 20:03:20 +00:00
Luka Perkov 95fe0abb96 image: add hooks for kernel/DTB installation in root filesystem
Signed-off-by: Michael Heimpold <mhei@heimpold.de>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@37852 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-08-28 00:07:41 +00:00
Gabor Juhos 173c4c7527 image: ensure that /dev/console exist in rootfs images
Linux expects that the /dev/console node is present in
the rootfs image. Create the node in rootfs images, in
order to make std{in,out,err} usable even in early init
process.

Note: tar.gz and cpio.gz images are not handled yet.

Signed-off-by: Gabor Juhos <juhosg@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@37847 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-08-27 12:02:58 +00:00
Gabor Juhos 42e10356e6 image: fix a typo in JFFS2OPTS to fix jffs2 rootfs generation
Due to a typo in the Makefile variable, mkfs.jffs2 is called
without the correct parameters.

Signed-off-by: Gabor Juhos <juhosg@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@37514 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-07-23 10:21:21 +00:00
Gabor Juhos b18e0a3e11 image: fix initramfs image name
Preserve order of components in initramfs image filename
when doing copy from $(KDIR) to $(BIN_DIR).

Patchwork: http://patchwork.openwrt.org/patch/3811/
Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@37452 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-07-19 17:12:45 +00:00
Florian Fainelli 405fb366b1 include/image.mk: do not make initramfs build exclusive
Allow building initramfs along with other types of filesystems.

Signed-off-by: Florian Fainelli <florian@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@37050 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-06-27 19:58:35 +00:00
Jonas Gorski 982f0f3386 target: split jffs2 NAND out of jffs2
Make jffs2_nand a separate option so this can be triggered without forcing
jffs2 images for nor targets.

Adds a new NAND_BLOCKSIZE variable that allows setting the generated layout
in <page_size>:<block_size> pairs.

Signed-off-by: Jonas Gorski <jogo@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@36860 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-06-05 20:58:03 +00:00
Luka Perkov a6c3641123 include/image.mk: export ubifs image from mkfs.ubifs
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@35473 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-02-03 21:00:24 +00:00
Florian Fainelli c87db17012 image.mk: use XZ bcj architecture filter if available
xz supports using an architecture specific BCJ filter, use that one to
save us a couple kB while producing squashfs filesystems (mimics the
Linux kernel).

Signed-off-by: Florian Fainelli <florian@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@35097 3c298f89-4303-0410-b956-a3cf2f4a3e73
2013-01-11 16:44:26 +00:00
Florian Fainelli 9a95c59fbe Revert "include/image.mk: call Image/Build/{cpiogz,targz}"
This breaks on platforms building their own targz/cpioz images.

Signed-off-by: Florian Fainelli <florian@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@34498 3c298f89-4303-0410-b956-a3cf2f4a3e73
2012-12-04 22:59:05 +00:00
Florian Fainelli 4a233e175e include/image.mk: call Image/Build/{cpiogz,targz}
All Image/mkfs/... macros call the Image/Build except for
Image/mkfs/targz and Image/mkfs/cpiogz

This patch adds the Image/Build call for Image/mkfs/targz and
Image/mkfs/cpiogz.

Signed-off-by: Maarten Bezemer <m.m.bezemer@utwente.nl>
Signed-off-by: Florian Fainelli <florian@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@34473 3c298f89-4303-0410-b956-a3cf2f4a3e73
2012-12-04 16:19:09 +00:00
Gabor Juhos 2dfb18cc0b build: Add TARGET_ROOTFS_RESERVED_PCT option to reduce wasted space
The genext2fs tool will 'reserve' 5% of the image size by default,
apparently by creating a huge lost+found directory. In fact it seemed to
be much more than 5% in practice — I saw an image with 8MiB used, and
recovered about 2MiB of it by deleting the 'empty' lost+found directory:

/dev/loop0         48377  8482     37438  19% /mnt/spare
 # rmdir lost+found/
/dev/loop0         48377  6014     39906  14% /mnt/spare

This makes it configurable, but leaves it at the genext2fs default
of 5% for now. It should probably be changed to default to zero, but
that can be a separate patch.

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@34408 3c298f89-4303-0410-b956-a3cf2f4a3e73
2012-11-29 17:37:15 +00:00
Florian Fainelli 815dc7a50b [buildroot] image.mk: don't squash file permissions in JFFS2 images
Currently we call mkfs.jffs2 --squash, which will change
both file permissions and owners.

If we have some file with suid bits, it will clear these bits.

Thus it's enough to just squash file owners, by replacing that
argument to --squash-uids.

Signed-off-by: Jonh Wendell <jonh.wendell@oiwifi.com.br>
Signed-off-by: Florian Fainelli <florian@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@34397 3c298f89-4303-0410-b956-a3cf2f4a3e73
2012-11-27 18:42:45 +00:00
Jo-Philipp Wich 3d25196097 include/image.mk: /tmp should have mode 1777
On the off chance that the root filesystem's /tmp is used directly as a
temporary directory instead of having a tmpfs mounted over it, it should have
the sticky bit set.

Signed-off-by: Mark Mentovai <mark@moxienet.com>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@32572 3c298f89-4303-0410-b956-a3cf2f4a3e73
2012-07-01 11:48:54 +00:00
Jo-Philipp Wich 15c52a84fb [package] base-files: add permission exceptions, do not clobber shadow permissions - based on patch by Mark Mentovai <mark@moxienet.com>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@32073 3c298f89-4303-0410-b956-a3cf2f4a3e73
2012-06-05 18:02:00 +00:00
Felix Fietkau 1529c7d824 image: increase squashfs block size - visibly reduces image size in many cases
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@29519 3c298f89-4303-0410-b956-a3cf2f4a3e73
2011-12-13 15:34:08 +00:00
Jo-Philipp Wich 32b5ea459c [include] image.mk: pass through $(CONFIG_PKG_BUILD_JOBS) to the mksquashfs -processors option
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@28305 3c298f89-4303-0410-b956-a3cf2f4a3e73
2011-09-26 02:02:35 +00:00
Felix Fietkau 12e992638e default to using gzip with mksquashfs if lzma and xz are unavailable
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@27748 3c298f89-4303-0410-b956-a3cf2f4a3e73
2011-07-24 09:16:55 +00:00
John Crispin a0eecf1178 extend squashfs padding for 256k flash sectors
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@27404 3c298f89-4303-0410-b956-a3cf2f4a3e73
2011-07-03 17:37:46 +00:00
Gabor Juhos c1359b5705 generic: use padjffs2 in prepare_generic_squashfs
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@27356 3c298f89-4303-0410-b956-a3cf2f4a3e73
2011-07-02 08:37:58 +00:00
Felix Fietkau 4613220875 tools/squashfs4: update to version 4.2 (adds support for xz compression)
Based on a patch by Jonas Gorski

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@26422 3c298f89-4303-0410-b956-a3cf2f4a3e73
2011-04-03 01:02:00 +00:00
Jo-Philipp Wich e29c4698e9 [include] image.mk: only upgrade permissions instead of overwriting, utilize tar -p flag for targz image targets (#7667)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@26259 3c298f89-4303-0410-b956-a3cf2f4a3e73
2011-03-21 17:38:15 +00:00
Imre Kaloz 06e8850d41 cleanup
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@24090 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-11-22 13:46:09 +00:00
Imre Kaloz 00da58c6ae remove 2.6.25 support
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@24089 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-11-22 13:43:32 +00:00
Imre Kaloz c1725149e1 switch from ext2 to ext4 (w/o) journaling
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@24084 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-11-22 12:12:39 +00:00
Felix Fietkau 67fbcc7bd4 remove linux 2.4 specific build system code
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@21951 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-06-26 20:42:38 +00:00
Nicolas Thill f1d6454a21 image/ext2: fix rootfs partition size after [21362]
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@21369 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-05-05 06:14:32 +00:00
Nicolas Thill ba1debe042 include: rearrange image.mk, indent, reorder, change some ifeq/ifneq tests
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@21244 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-04-29 00:44:26 +00:00
Nicolas Thill 8b1974bdad buildsystem: rename tgz/TGZ "feature" and matching options to targz/TARGZ
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@21238 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-04-28 14:47:43 +00:00
Nicolas Thill f696b88feb images: allow generating .cpio.gz and/or .tar.gz archives whether ramdisk is selected or not
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@21237 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-04-28 14:27:03 +00:00
Alexandros C. Couloumbis e11f6c9349 don't use lzma/jffs2 on <2.6.33, set lzma/jffs2 as default for >=2.6.33. switch verbose mode on compresor statistics.
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@20844 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-04-13 21:36:58 +00:00
Alexandros C. Couloumbis 8a70f533b7 finalize lzma/jffs2 support (currently not enebled by default, for kernels >=2.6.33) based on Edgar Soldin patches:
https://lists.openwrt.org/pipermail/openwrt-devel/2010-March/006550.html


git-svn-id: svn://svn.openwrt.org/openwrt/trunk@20837 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-04-13 14:07:22 +00:00
Nicolas Thill 9d42bb1a21 define a shared IMG_PREFIX variable used as a basename for image files, it contains board & subtarget infos (if appropriate) allowing subtargets to share the same bin directory without overwriting each other's files
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@20834 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-04-12 23:15:56 +00:00
Florian Fainelli 6e84b166c4 change from /jffs to /overlay, patch from Daniel Dickinson
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@20356 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-03-21 17:16:50 +00:00
Nicolas Thill c930e873c4 sort entries in images md5sums files
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@20116 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-03-10 04:03:37 +00:00
Lars-Peter Clausen 221422bfac image.mk: Adjust ubifs build behaviour to that of others image types
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@19985 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-03-05 04:14:03 +00:00
Imre Kaloz 98d6f0382b with no users left, remove support for 2.6.21
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@19578 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-02-11 08:37:57 +00:00
Felix Fietkau fa404080cc fix rootfs preparation with rootfs containing files with whitespaces in the filename (based on patch from #6551)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@19282 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-01-22 23:10:57 +00:00
Lars-Peter Clausen 2710572b04 Add support for building ubifs images.
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@19097 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-01-11 01:10:45 +00:00