[drupal6-imageapi] Spec cleanup

Shawn Iwinski siwinski at fedoraproject.org
Sun Jan 26 18:38:53 UTC 2014


commit 2206b614b8b629dd2de9415b69c5275e0568db94
Author: Shawn Iwinski <shawn.iwinski at gmail.com>
Date:   Sun Jan 26 13:38:52 2014 -0500

    Spec cleanup

 LICENSE.txt                        |  280 ------------------------------------
 drupal6-imageapi-RPM-README.txt    |    5 +
 drupal6-imageapi-fedora-README.txt |    6 -
 drupal6-imageapi.spec              |   89 +++++++-----
 4 files changed, 56 insertions(+), 324 deletions(-)
---
diff --git a/drupal6-imageapi-RPM-README.txt b/drupal6-imageapi-RPM-README.txt
new file mode 100644
index 0000000..a098b41
--- /dev/null
+++ b/drupal6-imageapi-RPM-README.txt
@@ -0,0 +1,5 @@
+After installation, you must enable this module from the Drupal administration
+page.
+
+If upgrading this module separately from the core Drupal package, be sure to
+run the http://hostname/drupal6/upgrade.php script after this RPM is upgraded.
diff --git a/drupal6-imageapi.spec b/drupal6-imageapi.spec
index ff9c234..e13eb61 100644
--- a/drupal6-imageapi.spec
+++ b/drupal6-imageapi.spec
@@ -1,61 +1,74 @@
-%global drupalver 6
-%{?rhel: %{expand: %%global drupal drupal%%{drupalver}}}
-%if 0%{?fedora} >= 15
-%global drupal drupal%{drupalver}
-%endif
-%{!?drupal: %{expand: %%global drupal drupal}}
-# e.g. "/usr/share/drupal6"
-%global drupalbase           %{_datadir}/%{drupal}
-%global drupal_sites_all    %{drupalbase}/sites/all        
-%global drupal_modules      %{drupal_sites_all}/modules
-# Use upstream name as expressed in URL and tarball
-%global modname             imageapi
-
-Name:    drupal%{drupalver}-%{modname}
-Version: 1.10
-Release: 3%{?dist}
-Summary: Image API Module for Drupal6 
-Group:   Applications/Publishing
-License: GPLv2
-URL:     http://drupal.org/project/%{modname}
-Source0: http://ftp.drupal.org/files/projects/%{modname}-%{drupalver}.x-%{version}.tar.gz
-Source1: %{name}-fedora-README.txt
-Source2: LICENSE.txt
+%{!?drupal6: %global drupal6 %{_datadir}/drupal6}
+%{!?drupal6_modules: %global drupal6_modules %{drupal6}/sites/all/modules}
+
+%global module imageapi
+
+Name:      drupal6-%{module}
+Version:   1.10
+Release:   4%{?dist}
+Summary:   ImageAPI supporting multiple toolkits
+
+Group:     Applications/Publishing
+License:   GPLv2
+URL:       http://drupal.org/project/%{module}
+Source0:   http://ftp.drupal.org/files/projects/%{module}-6.x-%{version}.tar.gz
+Source1:   %{name}-RPM-README.txt
+
 BuildArch: noarch
 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
-Requires:  drupal6, php-gd
+
+Requires:  drupal6
+# phpcompatinfo (computed from version 1.10)
+Requires:  php-gd
+Requires:  php-pcre
+
+Provides:  drupal6(%{module})             = %{version}
+Provides:  drupal6(%{module}_gd)          = %{version}
+Provides:  drupal6(%{module}_imagemagick) = %{version}
 
 %description
-This module allows users with proper permissions to upload images into Drupal.
-Thumbnails and additional sizes are created automatically.
+This API is meant to be used in place of the API provided by image.inc. You
+probably do not need to install this module unless another module are you
+using requires it. It provides no new features to your Drupal site. It only
+provides an API other modules can leverage. Currently GD2 and ImageMagick
+support are distributed with ImageAPI.
+
+This package provides the following Drupal modules:
+* %{module}
+* %{module}_gd
+* %{module}_imagemagick
+
 
 %prep
-%setup -qn %{modname}
+%setup -qn %{module}
+cp -p %{SOURCE1} .
+
 
 %build
-cp %{SOURCE1} .
-cp %{SOURCE2} .
+# Empty build section, nothing required
 
 
 %install
 rm -rf %{buildroot}
-install -d %{buildroot}%{drupal_modules}/%{modname}
-find . -type f -exec install -m 0644 -D '{}' %{buildroot}%{drupal_modules}/%{modname}/'{}' \;
+mkdir -pm 0755 %{buildroot}%{drupal6_modules}/%{module}
+cp -pr * %{buildroot}%{drupal6_modules}/%{module}/
+
 
 %clean
 rm -rf %{buildroot}
 
+
 %files
 %defattr(-,root,root,-)
-# Remember to include other documentation text here as well
-%doc  %{name}-fedora-README.txt
-%doc  LICENSE.txt
-# Remember to exclude all documentation texts from above
-%exclude %{drupal_modules}/%{modname}/LICENSE.txt
-%exclude %{drupal_modules}/%{modname}/%{name}-fedora-README.txt
-%{drupal_modules}/%{modname}
+%doc *.txt
+%{drupal6_modules}/%{module}
+%exclude %{drupal6_modules}/%{module}/*.txt
+
 
 %changelog
+* Sun Jan 26 2014 Shawn Iwinski <shawn.iwinski at gmail.com> - 1.10-4
+- Spec cleanup
+
 * Tue Jun 5 2012 Anderson Silva <ansilva at redhat.com> - 1.10-3
 - Update LICENSE.txt FSF mailing address
 - Update description


More information about the scm-commits mailing list