spec.template 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. %define name sqlite
  2. %define version SQLITE_VERSION
  3. %define release 1
  4. Name: %{name}
  5. Summary: SQLite is a C library that implements an embeddable SQL database engine
  6. Version: %{version}
  7. Release: %{release}
  8. Source: %{name}-%{version}.tar.gz
  9. Group: System/Libraries
  10. URL: http://www.sqlite.org/
  11. License: Public Domain
  12. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  13. %description
  14. SQLite is a software library that implements a self-contained, serverless,
  15. zero-configuration, transactional SQL database engine.
  16. Programs that link with the SQLite library can have SQL database access
  17. without running a separate RDBMS process. The distribution comes with a
  18. standalone command-line access program (sqlite) that can be used to
  19. administer an SQLite database and which serves as an example of how to
  20. use the SQLite library.
  21. %package -n %{name}-devel
  22. Summary: Header files and libraries for developing apps which will use sqlite
  23. Group: Development/C
  24. Requires: %{name} = %{version}-%{release}
  25. %description -n %{name}-devel
  26. The sqlite-devel package contains the header files and libraries needed
  27. to develop programs that use the SQLite database library.
  28. %prep
  29. %setup -q -n %{name}
  30. %build
  31. CFLAGS="%optflags -DNDEBUG=1" CXXFLAGS="%optflags -DNDEBUG=1" ./configure --prefix=%{_prefix}
  32. make
  33. make doc
  34. %install
  35. install -d $RPM_BUILD_ROOT/%{_prefix}
  36. install -d $RPM_BUILD_ROOT/%{_prefix}/bin
  37. install -d $RPM_BUILD_ROOT/%{_prefix}/include
  38. install -d $RPM_BUILD_ROOT/%{_prefix}/lib
  39. make install prefix=$RPM_BUILD_ROOT/%{_prefix}
  40. %post -p /sbin/ldconfig
  41. %postun -p /sbin/ldconfig
  42. %clean
  43. rm -fr $RPM_BUILD_ROOT
  44. %files
  45. %defattr(-, root, root)
  46. %{_libdir}/*.so*
  47. %{_bindir}/*
  48. %files -n %{name}-devel
  49. %defattr(-, root, root)
  50. %{_libdir}/pkgconfig/sqlite3.pc
  51. %{_libdir}/*.a
  52. %{_libdir}/*.la
  53. %{_includedir}/*
  54. %doc doc/*