diff --git a/.yajl.metadata b/.yajl.metadata new file mode 100644 index 0000000..c7e5ae4 --- /dev/null +++ b/.yajl.metadata @@ -0,0 +1 @@ +7c220588cf67981dfdaa2966ef3c4a375192a8d3 SOURCES/lloyd-yajl-2.0.4-0-gfee1ebe.tar.gz diff --git a/README.md b/README.md deleted file mode 100644 index 0e7897f..0000000 --- a/README.md +++ /dev/null @@ -1,5 +0,0 @@ -The master branch has no content - -Look at the c7 branch if you are working with CentOS-7, or the c4/c5/c6 branch for CentOS-4, 5 or 6 - -If you find this file in a distro specific branch, it means that no content has been checked in yet diff --git a/SOURCES/lloyd-yajl-2.0.4-pkgconfig-includedir.patch b/SOURCES/lloyd-yajl-2.0.4-pkgconfig-includedir.patch new file mode 100644 index 0000000..2593c61 --- /dev/null +++ b/SOURCES/lloyd-yajl-2.0.4-pkgconfig-includedir.patch @@ -0,0 +1,13 @@ +Only in lloyd-yajl-fee1ebe.new/src: CMakeLists.txt~ +diff -rup lloyd-yajl-fee1ebe.orig/src/yajl.pc.cmake lloyd-yajl-fee1ebe.new/src/yajl.pc.cmake +--- lloyd-yajl-fee1ebe.orig/src/yajl.pc.cmake 2011-12-20 00:23:22.000000000 +0000 ++++ lloyd-yajl-fee1ebe.new/src/yajl.pc.cmake 2012-08-06 14:05:49.639854538 +0100 +@@ -1,6 +1,6 @@ + prefix=${CMAKE_INSTALL_PREFIX} + libdir=${dollar}{prefix}/lib${LIB_SUFFIX} +-includedir=${dollar}{prefix}/include/yajl ++includedir=${dollar}{prefix}/include + + Name: Yet Another JSON Library + Description: A Portable JSON parsing and serialization library in ANSI C +Only in lloyd-yajl-fee1ebe.new/src: yajl.pc.cmake~ diff --git a/SOURCES/lloyd-yajl-2.0.4-pkgconfig-location.patch b/SOURCES/lloyd-yajl-2.0.4-pkgconfig-location.patch new file mode 100644 index 0000000..26da5ff --- /dev/null +++ b/SOURCES/lloyd-yajl-2.0.4-pkgconfig-location.patch @@ -0,0 +1,29 @@ +diff -rup lloyd-yajl-fee1ebe.orig/src/CMakeLists.txt lloyd-yajl-fee1ebe.new/src/CMakeLists.txt +--- lloyd-yajl-fee1ebe.orig/src/CMakeLists.txt 2011-12-20 00:23:22.000000000 +0000 ++++ lloyd-yajl-fee1ebe.new/src/CMakeLists.txt 2012-08-06 13:59:02.222065755 +0100 +@@ -30,7 +30,7 @@ ADD_DEFINITIONS(-DYAJL_BUILD) + # set up some paths + SET (libDir ${CMAKE_CURRENT_BINARY_DIR}/../${YAJL_DIST_NAME}/lib) + SET (incDir ${CMAKE_CURRENT_BINARY_DIR}/../${YAJL_DIST_NAME}/include/yajl) +-SET (shareDir ${CMAKE_CURRENT_BINARY_DIR}/../${YAJL_DIST_NAME}/share/pkgconfig) ++SET (pkgconfigDir ${CMAKE_CURRENT_BINARY_DIR}/../${YAJL_DIST_NAME}/lib/pkgconfig) + + # set the output path for libraries + SET(LIBRARY_OUTPUT_PATH ${libDir}) +@@ -61,7 +61,7 @@ FILE(MAKE_DIRECTORY ${incDir}) + # generate build-time source + SET(dollar $) + CONFIGURE_FILE(api/yajl_version.h.cmake ${incDir}/yajl_version.h) +-CONFIGURE_FILE(yajl.pc.cmake ${shareDir}/yajl.pc) ++CONFIGURE_FILE(yajl.pc.cmake ${pkgconfigDir}/yajl.pc) + + # copy public headers to output directory + FOREACH (header ${PUB_HDRS}) +@@ -82,5 +82,5 @@ IF(NOT WIN32) + INSTALL(TARGETS yajl_s ARCHIVE DESTINATION lib${LIB_SUFFIX}) + INSTALL(FILES ${PUB_HDRS} DESTINATION include/yajl) + INSTALL(FILES ${incDir}/yajl_version.h DESTINATION include/yajl) +- INSTALL(FILES ${shareDir}/yajl.pc DESTINATION share/pkgconfig) ++ INSTALL(FILES ${pkgconfigDir}/yajl.pc DESTINATION lib${LIB_SUFFIX}/pkgconfig) + ENDIF() +Only in lloyd-yajl-fee1ebe.new/src: CMakeLists.txt~ diff --git a/SPECS/yajl.spec b/SPECS/yajl.spec new file mode 100644 index 0000000..5fa144f --- /dev/null +++ b/SPECS/yajl.spec @@ -0,0 +1,141 @@ +Name: yajl +Version: 2.0.4 +Release: 2%{?dist} +Summary: Yet Another JSON Library (YAJL) + +Group: Development/Libraries +License: ISC +URL: http://lloyd.github.com/yajl/ + +# +# NB, upstream does not provide pre-built tar.gz downloads. Instead +# they make you use the 'on the fly' generated tar.gz from GITHub's +# web interface +# +# The Source0 for any version is obtained by a URL +# +# http://github.com/lloyd/yajl/tarball/1.0.7 +# +# Which causes a download of a archive named after +# the GIT hash corresponding to the version tag +# +# eg lloyd-yajl-45a1bdb.tar.gz +# +# NB even though the tar.gz is generated on the fly by GITHub it +# will always have identical md5sum +# +# So for new versions, update 'githash' to match the hash of the +# GIT tag associated with updated 'Version:' field just above +%global githash fee1ebe +Source0: lloyd-%{name}-%{version}-0-g%{githash}.tar.gz +Patch1: lloyd-%{name}-%{version}-pkgconfig-location.patch +Patch2: lloyd-%{name}-%{version}-pkgconfig-includedir.patch + +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) +BuildRequires: cmake + +%package devel +Summary: Libraries, includes, etc to develop with YAJL +Requires: %{name} = %{version}-%{release} + +%description +Yet Another JSON Library. YAJL is a small event-driven +(SAX-style) JSON parser written in ANSI C, and a small +validating JSON generator. + +%description devel +Yet Another JSON Library. YAJL is a small event-driven +(SAX-style) JSON parser written in ANSI C, and a small +validating JSON generator. + +This sub-package provides the libraries and includes +necessary for developing against the YAJL library + +%prep +%setup -q -n lloyd-%{name}-%{githash} +%patch1 -p1 +%patch2 -p1 + +%build +# NB, we are not using upstream's 'configure'/'make' +# wrapper, instead we use cmake directly to better +# align with Fedora standards +mkdir build +cd build +%cmake .. +make VERBOSE=1 %{?_smp_mflags} + + +%install +rm -rf $RPM_BUILD_ROOT +cd build +make install DESTDIR=$RPM_BUILD_ROOT + + +# No static libraries +rm -f $RPM_BUILD_ROOT%{_libdir}/libyajl_s.a + + +%check +cd test +./run_tests.sh + +%clean +rm -rf $RPM_BUILD_ROOT + +%post -p /sbin/ldconfig + +%postun -p /sbin/ldconfig + +%files +%defattr(-,root,root,-) +%doc COPYING ChangeLog README TODO +%{_bindir}/json_reformat +%{_bindir}/json_verify +%{_libdir}/libyajl.so.2 +%{_libdir}/libyajl.so.2.* + +%files devel +%defattr(-,root,root,-) +%doc COPYING +%dir %{_includedir}/yajl +%{_includedir}/yajl/yajl_common.h +%{_includedir}/yajl/yajl_gen.h +%{_includedir}/yajl/yajl_parse.h +%{_includedir}/yajl/yajl_tree.h +%{_includedir}/yajl/yajl_version.h +%{_libdir}/libyajl.so +%{_libdir}/pkgconfig/yajl.pc + + +%changelog +* Fri Feb 15 2013 Fedora Release Engineering - 2.0.4-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild + +* Mon Aug 6 2012 Daniel P. Berrange - 2.0.4-1 +- Update to 2.0.4 release (rhbz #845777) +- Fix License tag to reflect change in 2.0.0 series from BSD to ISC + +* Sun Jul 22 2012 Fedora Release Engineering - 2.0.1-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild + +* Sat Jan 14 2012 Fedora Release Engineering - 2.0.1-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild + +* Thu Nov 10 2011 Daniel P. Berrange - 2.0.1-1 +- Update to 2.0.1 release + +* Tue May 3 2011 Daniel P. Berrange - 1.0.12-1 +- Update to 1.0.12 release + +* Fri Dec 17 2010 Daniel P. Berrange - 1.0.11-1 +- Update to 1.0.11 release + +* Mon Jan 11 2010 Daniel P. Berrange - 1.0.7-3 +- Fix ignoring of cflags (rhbz #547500) + +* Tue Dec 8 2009 Daniel P. Berrange - 1.0.7-2 +- Change use of 'define' to 'global' + +* Mon Dec 7 2009 Daniel P. Berrange - 1.0.7-1 +- Initial Fedora package