From 95a92d1f3df1ecffb96456575126caed1b74bb15 Mon Sep 17 00:00:00 2001 From: Chmouel Boudjnah Date: Wed, 30 Jan 2002 13:37:15 +0000 Subject: Add Makefile and .spec --- Makefile | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ bootsplash.spec | 40 ++++++++++++++++++++++++++++++++++++++++ scripts/Makefile | 15 +++++++++++++++ 3 files changed, 103 insertions(+) create mode 100644 Makefile create mode 100644 bootsplash.spec create mode 100644 scripts/Makefile diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..9daf96d --- /dev/null +++ b/Makefile @@ -0,0 +1,48 @@ +NAME=bootsplash +VERSION := $(shell sed -n 's/%define version //p' < $(NAME).spec) +RELEASE := $(shell sed -n 's/%define release //p' < $(NAME).spec) +RELTAG := $(shell echo "V$(VERSION)_$(RELEASE)" | tr -- '-.' '__') + +SUBDIRS=scripts +DATADIRS=images cfg + +prefix=/ +sharedir=/usr/share + +all: check + +check: + @for i in $(SUBDIRS);do make -C $$i check;done + +install: + @mkdir -p $(prefix)$(sharedir)/bootsplash/ + @for i in $(SUBDIRS);do make -C $$i install;done + @for i in $(DATADIRS);do cp -a $$i $(prefix)$(sharedir)/bootsplash/;done + +dis: clean + rm -rf $(NAME)-$(VERSION) ../$(NAME)-$(VERSION).tar* + mkdir -p $(NAME)-$(VERSION) + find . -not -name "$(NAME)-$(VERSION)"|cpio -pd $(NAME)-$(VERSION)/ + find $(NAME)-$(VERSION) -type d -name CVS -o -name .cvsignore -o -name unused |xargs rm -rf + tar cf ../$(NAME)-$(VERSION).tar $(NAME)-$(VERSION) + bzip2 -9f ../$(NAME)-$(VERSION).tar + rm -rf $(NAME)-$(VERSION) + +clean: + @for i in $(SUBDIRS);do make -C $$i clean;done + rm -f *~ \#*\# + +changelog: ../common/username + ( cvs2cl -U ../common/username -I ChangeLog ; \ + rm -f ChangeLog.bak ; \ + cvs commit -m "Generated by cvs2cl the `date '+%c'`" ChangeLog ; \ + ) + +cvstag: + cvs commit + cvs tag $(RELTAG) + +rpm: changelog cvstag dis ../$(NAME)-$(VERSION).tar.bz2 $(RPM) + cp -f ../$(NAME)-$(VERSION).tar.bz2 $(RPM)/SOURCES + -rpm -ba --clean $(NAME).spec + rm -f ../$(NAME)-$(VERSION).tar.bz2 diff --git a/bootsplash.spec b/bootsplash.spec new file mode 100644 index 0000000..68ea90d --- /dev/null +++ b/bootsplash.spec @@ -0,0 +1,40 @@ +%define name bootsplash +%define version 1.0 +%define release 1mdk + +Summary: The Boot Splash Images and scripts. +Name: %{name} +Version: %{version} +Release: %{release} +# From MDK cvs. +Source0: %{name}-%{version}.tar.bz2 +License: GPL +Group: System/Kernel and hardware +BuildRoot: %{_tmppath}/%{name}-buildroot +Prefix: %{_prefix} + +%description +This package contain the scripts and the pictures you see when we +booting a Mandrake kernel. They are automatically called when +generating an initrd by mkinitrd. + +%prep +%setup -q + +%build +make check + +%install +rm -rf $RPM_BUILD_ROOT +make install prefix=$RPM_BUILD_ROOT + +%clean +rm -rf $RPM_BUILD_ROOT + +%files +%defattr(-,root,root) +%_datadir/%{ame}/* + +%changelog + +# end of file diff --git a/scripts/Makefile b/scripts/Makefile new file mode 100644 index 0000000..e27fd95 --- /dev/null +++ b/scripts/Makefile @@ -0,0 +1,15 @@ +PL=detect-resolution +SH=make-boot-splash rewritejpeg + +sharedir=/usr/share + +check: + @for i in $(SH);do /bin/bash -n $$i || exit 1;echo $$i syntax OK;done + @for i in $(PL);do perl -c $$i ||exit 1;done + +install: + @mkdir -p $(prefix)$(sharedir)/bootsplash/scripts/ + @for i in $(SH) $(PL);do install -m755 $$i $(prefix)$(sharedir)/bootsplash/scripts/;done + +clean: + rm -f *~ \#*\# \ No newline at end of file -- cgit v1.2.1