test/filesystem.spec
author J. Ali Harlow <ali@juiblex.co.uk>
Wed Apr 29 17:00:01 2009 +0100 (2009-04-29)
changeset 361 2523d03a840e
child 393 d16ac3fb05fa
permissions -rw-r--r--
Add support for preloading lua modules. This is useful both when
providing lua bindings to applications based on librazor and when
producing static binaries using librazor (where otherwise the lua
POSIX library would need to be included as an additional dynamic
object).
ali@352
     1
Name:      filesystem
ali@352
     2
Summary:   Test package
ali@352
     3
Group:     Test
ali@352
     4
License:   GPL
ali@352
     5
Version:   1
ali@352
     6
Release:   1
ali@352
     7
BuildArch: noarch
ali@352
     8
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
ali@352
     9
ali@352
    10
%description
ali@352
    11
Test package
ali@352
    12
ali@352
    13
%prep
ali@352
    14
ali@352
    15
%build
ali@352
    16
ali@352
    17
%install
ali@352
    18
mkdir %{buildroot}
ali@352
    19
mkdir -p %{buildroot}%{_sysconfdir}
ali@352
    20
mkdir -p %{buildroot}/{%{_bindir},%{_libdir},%{_includedir}}
ali@352
    21
mkdir -p %{buildroot}/media
ali@352
    22
ali@352
    23
%clean
ali@352
    24
rm -rf %{buildroot}
ali@352
    25
ali@352
    26
%post -p <lua>
ali@352
    27
function mkdir_missing(dir)
ali@352
    28
    if posix.stat(dir) == nil then
ali@352
    29
        posix.mkdir(dir)
ali@352
    30
    end
ali@352
    31
end
ali@352
    32
mkdir_missing("/media/cdrom")
ali@352
    33
ali@352
    34
%files
ali@352
    35
%defattr(0755,root,root)
ali@352
    36
/etc
ali@352
    37
%{_prefix}
ali@352
    38
%dir /media