summaryrefslogtreecommitdiffstats
path: root/jq.spec
diff options
context:
space:
mode:
authorLee Thompson <thompson@dtosolutions.com>2012-12-03 17:27:40 -0600
committerLee Thompson <thompson@dtosolutions.com>2012-12-03 17:27:40 -0600
commit00e4feba811034b374512c001d01a3e6f6991be8 (patch)
tree765ea591f43037c12ddbaef06e19302b0c4faeda /jq.spec
parent26bbed29f72742ddfb39b0684e78bc4d2780de51 (diff)
get rpm building from tarball with autoconf
Diffstat (limited to 'jq.spec')
-rw-r--r--jq.spec37
1 files changed, 25 insertions, 12 deletions
diff --git a/jq.spec b/jq.spec
index 71b3e792..ca63aa93 100644
--- a/jq.spec
+++ b/jq.spec
@@ -1,11 +1,15 @@
+# This is spec file maintained by developers of JQ, not by a OS distro.
+# Your OS of choice will likely ignore this RPM spec file.
Summary: Command-line JSON processor
Name: jq
Version: %{version}
Release: %{release}
-Source0: jq-%{version}.tgz
+Source0: jq-%{version}.tar.gz
URL: https://github.com/stedolan/jq
-
-License: Copyright (C) 2012 Stephen Dolan
+License: BSD
+AutoReqProv: no
+BuildPrereq: autoconf, libtool, automake, flex, bison, python
+
Group: Applications/System
# Requires:
@@ -13,28 +17,37 @@ Group: Applications/System
%global _enable_debug_package 0
%global debug_package %{nil}
%global __os_install_post %{nil}
-
+
%description
jq is a command-line JSON processor
-
+
%prep
%setup
%build
-
+echo "Building in: \"$(pwd)\""
+./configure --prefix=%{_prefix}
+make
+
%install
-echo "Building in: \"%{buildroot}\""
-rm -rf %{buildroot}
-install -d -m 755 %{buildroot}/usr/bin
-mv %{_builddir}/jq-%{version}/bin/jq %{buildroot}/usr/bin
+echo "Installing to: \"${RPM_BUILD_ROOT}\""
+make install DESTDIR=${RPM_BUILD_ROOT}
%clean
+rm -rf ${RPM_BUILD_ROOT}
%files
%defattr(-,root,root)
-/usr/bin/jq
-
+%{_bindir}/jq
+%{_bindir}/jq_test
+%{_datadir}/doc/jq/AUTHORS
+%{_datadir}/doc/jq/COPYING
+%{_datadir}/doc/jq/INSTALL
+%{_datadir}/doc/jq/NEWS
+%{_datadir}/doc/jq/README
+%{_datadir}/doc/jq/README.md
+
%changelog
%pre