Alexandre Lision | ddd731e | 2014-01-31 11:50:08 -0500 | [diff] [blame] | 1 | # Copyright (c) 2008, 2009 David Sugar, Tycho Softworks. |
| 2 | # This file is free software; as a special exception the author gives |
| 3 | # unlimited permission to copy and/or distribute it, with or without |
| 4 | # modifications, as long as this notice is preserved. |
| 5 | # |
| 6 | # This program is distributed in the hope that it will be useful, |
| 7 | # but WITHOUT ANY WARRANTY, to the extent permitted by law; without |
| 8 | # even the implied warranty of MERCHANTABILITY or FITNESS FOR A |
| 9 | # PARTICULAR PURPOSE. |
| 10 | |
| 11 | Name: ucommon |
| 12 | Summary: Portable C++ runtime for threads and sockets |
| 13 | Version: @VERSION@ |
| 14 | Release: 0%{?dist} |
| 15 | License: LGPLv3+ |
| 16 | URL: http://www.gnu.org/software/commoncpp |
| 17 | Source0: http://www.gnutelephony.org/dist/tarballs/ucommon-%{version}.tar.bz2 |
| 18 | BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root |
| 19 | BuildRequires: doxygen graphviz-gd openssl-devel |
| 20 | Group: System Environment/Libraries |
| 21 | Summary: Runtime library for portable C++ threading and sockets |
| 22 | |
| 23 | %description |
| 24 | GNU uCommon C++ is a lightweight library to facilitate using C++ design |
| 25 | patterns even for very deeply embedded applications, such as for systems using |
| 26 | uClibc along with POSIX threading support. For this reason, uCommon disables |
| 27 | language features that consume memory or introduce runtime overhead. uCommon |
| 28 | introduces some design patterns from Objective-C, such as reference counted |
| 29 | objects, memory pools, and smart pointers. uCommon introduces some new |
| 30 | concepts for handling of thread locking and synchronization. |
| 31 | |
| 32 | %package bin |
| 33 | Requires: %{name} = %{version}-%{release} |
| 34 | Group: Applications/System |
| 35 | Summary: ucommon system and support applications. |
| 36 | |
| 37 | %package devel |
| 38 | Requires: %{name} = %{version}-%{release} |
| 39 | Requires: %{name}-bin = %{version}-%{release} |
| 40 | Requires: openssl-devel |
| 41 | Requires: pkgconfig |
| 42 | Group: Development/Libraries |
| 43 | Summary: Headers for building ucommon applications |
| 44 | |
| 45 | %package doc |
| 46 | Group: Documentation |
| 47 | Summary: Generated class documentation for ucommon |
| 48 | |
| 49 | %description bin |
| 50 | This is a collection of command line tools that use various aspects of the |
| 51 | ucommon library. Some may be needed to prepare files or for development of |
| 52 | applications. |
| 53 | |
| 54 | %description devel |
| 55 | This package provides header and support files needed for building |
| 56 | applications that use the uCommon library and frameworks. |
| 57 | |
| 58 | %description doc |
| 59 | Generated class documentation for GNU uCommon library from header files, |
| 60 | html browsable. |
| 61 | |
| 62 | %prep |
| 63 | %setup -q |
| 64 | |
| 65 | %build |
| 66 | %{__rm} -rf build |
| 67 | %{__mkdir} build |
| 68 | cd build |
| 69 | cmake -DCMAKE_INSTALL_PREFIX=%{_prefix} \ |
| 70 | -DSYSCONFDIR=%{_sysconfdir} \ |
| 71 | -DMANDIR=%{_mandir} \ |
| 72 | -DCMAKE_VERBOSE_MAKEFILE=TRUE \ |
| 73 | -DCMAKE_C_FLAGS_RELEASE:STRING="$RPM_OPT_FLAGS" \ |
| 74 | -DCMAKE_CXX_FLAGS_RELEASE:STRING="$RPM_OPT_FLAGS" \ |
| 75 | .. |
| 76 | %{__make} %{?_smp_mflags} |
| 77 | |
| 78 | %install |
| 79 | cd build |
| 80 | %{__rm} -rf %{buildroot} |
| 81 | make install DESTDIR=%{buildroot} |
| 82 | %{__chmod} 0755 %{buildroot}%{_bindir}/ucommon-config |
| 83 | %{__chmod} 0755 %{buildroot}%{_bindir}/commoncpp-config |
| 84 | %{__rm} -rf %{buildroot}%{_libdir}/*.la |
| 85 | |
| 86 | %clean |
| 87 | %{__rm} -rf %{buildroot} |
| 88 | |
| 89 | %files |
| 90 | %defattr(-,root,root,-) |
| 91 | %doc AUTHORS README COPYING COPYING.LESSER COPYRIGHT NEWS SUPPORT ChangeLog |
| 92 | %{_libdir}/libucommon.so.* |
| 93 | %{_libdir}/libusecure.so.* |
| 94 | %{_libdir}/libcommoncpp.so.* |
| 95 | |
| 96 | %files bin |
| 97 | %defattr(-,root,root,-) |
| 98 | %{_bindir}/args |
| 99 | %{_bindir}/car |
| 100 | %{_bindir}/scrub-files |
| 101 | %{_bindir}/mdsum |
| 102 | %{_bindir}/sockaddr |
| 103 | %{_bindir}/zerofill |
| 104 | %{_mandir}/man1/args.* |
| 105 | %{_mandir}/man1/car.* |
| 106 | %{_mandir}/man1/scrub-files.* |
| 107 | %{_mandir}/man1/mdsum.* |
| 108 | %{_mandir}/man1/sockaddr.* |
| 109 | %{_mandir}/man1/zerofill.* |
| 110 | |
| 111 | %files devel |
| 112 | %defattr(-,root,root,-) |
| 113 | %{_libdir}/*.so |
| 114 | %{_includedir}/ucommon/ |
| 115 | %{_includedir}/commoncpp/ |
| 116 | %{_libdir}/pkgconfig/*.pc |
| 117 | %{_bindir}/ucommon-config |
| 118 | %{_bindir}/commoncpp-config |
| 119 | # %{_mandir}/man1/ucommon-config.* |
| 120 | |
| 121 | %files doc |
| 122 | %defattr(-,root,root,-) |
| 123 | # %doc doc/html/* |
| 124 | |
| 125 | %post -p /sbin/ldconfig |
| 126 | |
| 127 | %postun -p /sbin/ldconfig |
| 128 | |
| 129 | %changelog |
| 130 | * Sat Sep 18 2010 - David Sugar <dyfet@gnutelephony.org> - 3.4.0-0 |
| 131 | - simplified packaging and better runtime focus. |
| 132 | - ccscript moved to bayonne, ccaudio detached. |
| 133 | |
| 134 | * Sun Aug 01 2010 - David Sugar <dyfet@gnutelephony.org> - 3.3.0-0 |
| 135 | - internationalization bindings with gnu gettext support. |
| 136 | - reorganized utils into ucommon-bin subpackage. |
| 137 | |
| 138 | * Fri Jun 04 2010 - David Sugar <dyfet@gnutelephony.org> - 3.0.0-0 |
| 139 | - merged ccscript and ccaudio with ucommon to create single framework. |
| 140 | |
| 141 | * Sun Jul 19 2009 - David Sugar <dyfet@gnutelephony.org> - 2.0.6-1 |
| 142 | - fixed ucommon-config upstream. |
| 143 | |
| 144 | * Tue May 05 2009 - David Sugar <dyfet@gnutelephony.org> - 2.0.5-4 |
| 145 | - removed static libraries, fixed other build issues (#498736) |
| 146 | |
| 147 | * Sun May 03 2009 - David Sugar <dyfet@gnutelephony.org> - 2.0.5-3 |
| 148 | - spec file prepared for redhat/fedora (#498736) |
| 149 | |