The webmail editor mangled the patch. Here it is again as a MIME attachment. :-)
Swee Heng
Changed Makefile to use tools/ directory instead of creator/.
Changed both Makefile and livecd-tools.spec to handle imgcreate.
Signed-off-by: Tan Swee Heng <[EMAIL PROTECTED]>
---
Makefile | 14 ++++++++++++--
livecd-tools.spec | 8 ++++++++
2 files changed, 20 insertions(+), 2 deletions(-)
diff --git a/Makefile b/Makefile
index 3d86b29..393d6db 100644
--- a/Makefile
+++ b/Makefile
@@ -6,11 +6,18 @@ INSTALL_PROGRAM = ${INSTALL}
INSTALL_DATA = ${INSTALL} -m 644
INSTALL_SCRIPT = ${INSTALL_PROGRAM}
+INSTALL_PYTHON = ${INSTALL} -m 644
+define COMPILE_PYTHON
+ python -c "import compileall as c; c.compile_dir('$(1)', force=1)"
+ python -O -c "import compileall as c; c.compile_dir('$(1)', force=1)"
+endef
+PYTHONDIR := $(shell python -c "import distutils.sysconfig as d; print d.get_python_lib()")
+
all:
install:
- $(INSTALL_PROGRAM) -D creator/livecd-creator $(DESTDIR)/usr/bin/livecd-creator
- $(INSTALL_PROGRAM) -D creator/image-creator $(DESTDIR)/usr/bin/image-creator
+ $(INSTALL_PROGRAM) -D tools/livecd-creator $(DESTDIR)/usr/bin/livecd-creator
+ $(INSTALL_PROGRAM) -D tools/image-creator $(DESTDIR)/usr/bin/image-creator
$(INSTALL_PROGRAM) -D tools/livecd-iso-to-disk.sh $(DESTDIR)/usr/bin/livecd-iso-to-disk
$(INSTALL_PROGRAM) -D tools/mayflower $(DESTDIR)/usr/lib/livecd-creator/mayflower
$(INSTALL_DATA) -D AUTHORS $(DESTDIR)/usr/share/doc/livecd-tools-$(VERSION)/AUTHORS
@@ -19,6 +26,9 @@ install:
$(INSTALL_DATA) -D HACKING $(DESTDIR)/usr/share/doc/livecd-tools-$(VERSION)/HACKING
mkdir -p $(DESTDIR)/usr/share/livecd-tools/
$(INSTALL_DATA) -D config/*.ks $(DESTDIR)/usr/share/livecd-tools/
+ mkdir -p $(DESTDIR)/$(PYTHONDIR)/imgcreate
+ $(INSTALL_PYTHON) -D imgcreate/*.py $(DESTDIR)/$(PYTHONDIR)/imgcreate/
+ $(call COMPILE_PYTHON,$(DESTDIR)/$(PYTHONDIR)/imgcreate)
uninstall:
rm -f $(DESTDIR)/usr/bin/livecd-creator
diff --git a/livecd-tools.spec b/livecd-tools.spec
index 542283d..9b9d4f5 100644
--- a/livecd-tools.spec
+++ b/livecd-tools.spec
@@ -1,3 +1,5 @@
+%{!?python_sitelib: %define python_sitelib %(%{__python} -c "import distutils.sysconfig as d; print d.get_python_lib()")}
+
%define debug_package %{nil}
Summary: Tools for building live CD's
@@ -24,6 +26,7 @@ Requires: syslinux
%ifarch ppc ppc64
Requires: yaboot
%endif
+BuildRequires: python
%description
@@ -53,6 +56,11 @@ rm -rf $RPM_BUILD_ROOT
/usr/lib/livecd-creator/mayflower
%dir %{_datadir}/livecd-tools
%{_datadir}/livecd-tools/*
+%{_bindir}/image-creator
+%dir %{python_sitelib}/imgcreate
+%{python_sitelib}/imgcreate/*.py
+%{python_sitelib}/imgcreate/*.pyo
+%{python_sitelib}/imgcreate/*.pyc
%changelog
* Mon Oct 29 2007 Jeremy Katz <[EMAIL PROTECTED]> - 013-1
--
1.5.3.3
--
Fedora-livecd-list mailing list
[email protected]
https://www.redhat.com/mailman/listinfo/fedora-livecd-list