]> git.pld-linux.org Git - packages/OSPToolkit.git/commitdiff
- up to 3.5.3; make shared lib auto/th/OSPToolkit-3_5_3-1 auto/ti/OSPToolkit-3_5_3-1
authorElan Ruusamäe <glen@pld-linux.org>
Fri, 1 Jan 2010 22:50:29 +0000 (22:50 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    OSPToolkit.spec -> 1.4
    sharedlib.patch -> 1.1

OSPToolkit.spec
sharedlib.patch [new file with mode: 0644]

index 81e210444a80cfd484473559e407b52e5a30ae9b..43548e429cb2db860d6f9e971345b24d06306ee6 100644 (file)
@@ -1,14 +1,16 @@
 Summary:       Implementation of the ETSI OSP VoIP Peering protocol
 Summary(pl.UTF-8):     Implementacja protokołu ETSI OSP VoIP Peering
 Name:          OSPToolkit
-Version:       3.4.1
+Version:       3.5.3
 Release:       1
 License:       BSD
 Group:         Libraries
 Source0:       http://dl.sourceforge.net/osp-toolkit/%{name}-%{version}.tar.gz
-# Source0-md5: e9943630934c65d012fb49a820d8b179
+# Source0-md5: af6d83298596d8952d785e8dcb30c561
+Patch0:                sharedlib.patch
 URL:           http://www.transnexus.com/OSP%20Toolkit/OSP%20Toolkit.htm
 BuildRequires: openssl-devel
+BuildRequires: sed >= 4.0
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
@@ -27,27 +29,71 @@ VoIP. OSP Toolkit zawiera kod źródłowy w ANSI C, narzędzia testowe
 oraz szczegółową dokumentację jak zaimplementować standard OSP
 Peering.
 
+%package devel
+Summary:       Header files for OSP Toolkit library
+Summary(pl.UTF-8):     Pliki nagłówkowe biblioteki OSP Toolkit
+Group:         Development/Libraries
+Requires:      %{name} = %{version}-%{release}
+
+%description devel
+Header files for OSP Toolkit library.
+
+%description devel -l pl.UTF-8
+Pliki nagłówkowe biblioteki OSP Toolkit.
+
+%package static
+Summary:       Static OSP Toolkit library
+Summary(pl.UTF-8):     Statyczna biblioteka OSP Toolkit
+Group:         Development/Libraries
+Requires:      %{name}-devel = %{version}-%{release}
+
+%description static
+Static OSP Toolkit library.
+
+%description static -l pl.UTF-8
+Statyczna biblioteka OSP Toolkit.
+
 %prep
-%setup -q -n TK-3_4_1-20070917
+%setup -q -n TK-%(echo %{version} | tr . _)-20091006
+%patch0 -p1
+%{__sed} -i -e 's,\$(INSTALL_PATH)/lib,$(INSTALL_PATH)/%{_lib},' src/Makefile
 
 %build
 %{__make} -C src build \
        CC="%{__cc}" \
-       GCCFLAGS="-Wall -D_GNU_SOURCE -fPIC %{rpmcflags}"
+       LDFLAGS="%{rpmldflags}" \
+       DFLAGS="%{rpmcflags}"
+
+%{__make} -C enroll linux \
+       CC="%{__cc}" \
+       DFLAGS="%{rpmcflags}"
 
 %install
 rm -rf $RPM_BUILD_ROOT
-
 install -d $RPM_BUILD_ROOT{%{_includedir},%{_libdir}}
 
-cp -a include/osp $RPM_BUILD_ROOT%{_includedir}
-install lib/*.a $RPM_BUILD_ROOT%{_libdir}
+%{__make} -C src install \
+       INSTALL_PATH=$RPM_BUILD_ROOT%{_prefix}
+
+chmod a+x $RPM_BUILD_ROOT%{_libdir}/lib*so*
 
 %clean
 rm -rf $RPM_BUILD_ROOT
 
+%post  -p /sbin/ldconfig
+%postun        -p /sbin/ldconfig
+
 %files
 %defattr(644,root,root,755)
 %doc *.txt
-%{_libdir}/lib*.a
+%attr(755,root,root) %{_libdir}/libosptk.so.*.*
+%attr(755,root,root) %ghost %{_libdir}/libosptk.so.0
+
+%files devel
+%defattr(644,root,root,755)
+%{_libdir}/libosptk.so
 %{_includedir}/osp
+
+%files static
+%defattr(644,root,root,755)
+%{_libdir}/libosptk.a
diff --git a/sharedlib.patch b/sharedlib.patch
new file mode 100644 (file)
index 0000000..018ec36
--- /dev/null
@@ -0,0 +1,32 @@
+--- TK-3_5_3-20091006/src/Makefile     2010-01-02 00:35:45.127259952 +0200
++++ TK-3_5_3-20091006/src/Makefile     2010-01-02 00:37:28.447659057 +0200
+@@ -56,6 +56,7 @@
+           ospciscoext.o ospcapind.o ospcapcnf.o $(SSLOBJ)
+           
+ OSPLIB = $(LIBDIR)/libosptk.a
++OSPLIBSO = $(LIBDIR)/libosptk.so.0.0.0
+ .SUFFIXES: .o .c 
+@@ -72,14 +73,20 @@
+ build: $(OSPLIB)
+-$(OSPLIB): $(OSPOBJS)
++$(OSPLIB): $(OSPOBJS) $(OSPLIBSO)
+       $(AR) -r $(OSPLIB) $(OSPOBJS)
++$(OSPLIBSO): $(OSPOBJS)
++      $(CC) -o $(OSPLIBSO) $(LDFLAGS) -Wl,-soname -Wl,libosptk.so.0 $(OSPOBJS) -lssl -lm -shared -lcrypto -lpthread
++
+ install: build
+       install -d $(INSTALL_PATH)/include/osp
+       cp $(INCDIR)/osp/*.h $(INSTALL_PATH)/include/osp/
+       install -d $(INSTALL_PATH)/lib
+       cp $(OSPLIB) $(INSTALL_PATH)/lib/
++      cp $(OSPLIBSO) $(INSTALL_PATH)/lib/
++      ln -s libosptk.so.0.0.0 $(INSTALL_PATH)/lib/libosptk.so.0
++      ln -s libosptk.so.0.0.0 $(INSTALL_PATH)/lib/libosptk.so
+ clean:
+       rm -f $(OSPLIB) $(OSPOBJS)
This page took 0.09607 seconds and 4 git commands to generate.