lkml.org 
[lkml]   [2002]   [Apr]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subject[PATCH] cramfs 5/6 - metafiles.txt
5. linux/Documentation/filesystems/metafiles.txt added that describes the
metafile format used in mkcramfs.

The file is simply attached, not a real patch, hope that is ok.
It's intended to go into linux/Documentation/filesystems/ , but
since mkcramfs no longer is in the kernel, perhaps
that isn't the correct place for it anymore.
Perhaps simply add it to the cramfs tools (or both..)?

/Johan

Metafiles
=========

Metafiles are used to let a filesystem builder, such as mkcramfs and
mkfs.jffs2, ignore files and change attributes of files while building
the filesystem.

This document briefly describes how Axis Communications are using metafiles
with mkcramfs amd mkfs.jffs2 and is also a proposal of a metafile standard
for filesystem builders.



Metafile Format
===============

An instruction is a line in a metafile telling the filesystem builder if
anything special should be done with a file or directory before writing it to
the filesystem. The following instructions should be recognized by the
filesystem builder:


Ignore
------
Syntax: "Ignore: FILE"

Ignores a file or directory. I.e. FILE is not included in the filesystem.
The metafiles themselves are always ignored and do not have to be mentioned
in any metafiles.


IgnoreContents
--------------
Syntax: "IgnoreContents: DIRECTORY"

Ignores the contents of a directory. I.e. DIRECTORY is included in the
filesystem but all files and directories in DIRECTORY are ignored.


Include
-------
Syntax: "Include: FILE"

Includes a file or directory. If an Include instruction is found in a
metafile, all files or directories (in the same directory as the metafile)
that are not included will be ignored (NOTE!).


Device
------
Syntax: "Device: FILE TYPE MAJOR MINOR"

Convert a regular file to a device special file. If FILE exists it will be
written to the filesystem as a character or block special file with
MAJOR and MINOR numbers. TYPE is 'b' for block and 'c' for character device.

Example: To create the character special file /dev/ttyS0 using metafiles,
add the following line to the metafile in the /dev directory:

Device: ttyS0 c 4 64


UserId
------
Syntax: "UserId: FILE UID"

Change file owner. The owner of FILE will be UID.


DefaultUserId
-------------
Syntax: "DefaultUserId: UID"

Change file owner recursively. All files and directories in this directory
will be owned by UID unless overridden with the UserId instruction.


GroupId
-------
Syntax: "GroupId: FILE GID"

Change group ownership on a file or directory. The group membership of FILE
will be GID.


DefaultGroupId
--------------
Syntax: "DefaultGroupId: UID"

Change gruop ownership recursively. The group membership of all files and
directories in this directory will be GID unless overridden with the GroupId
instruction.
\
 
 \ /
  Last update: 2005-03-22 13:25    [W:0.038 / U:5.560 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site