On 02/18/2010 03:05 PM, Dhaval Giani wrote:
>
> libcgroup was not making an entry into the pkg-config database, which
> makes life easier when using multiple libraries. Add the needed data
> in order to be registered with the pkg-config database on installation.
>
> Signed-off-by: Dhaval Giani<[email protected]>
>
> ---
>
> Jan, Could you please check the spec file changes a bit more carefully,
> and ACK the changes?

Well... the patch below is malformed, but with just removing wrong line 
wraps it works as expected (see below)

Reviewed-by: Jan Safranek <[email protected]>

>
> Thanks!
>
> ---
>   Makefile.am            |    3 +++
>   configure.in           |    3 ++-
>   dist/libcgroup.spec.in |    9 ++++++++-
>   libcgroup.pc.in        |   10 ++++++++++
>   4 files changed, 23 insertions(+), 2 deletions(-)
>
> Index: libcg/Makefile.am
> ===================================================================
> --- libcg.orig/Makefile.am
> +++ libcg/Makefile.am
> @@ -2,3 +2,6 @@ AUTOMAKE_OPTIONS = foreign
>   SUBDIRS = dist doc include samples scripts src tests
>
>   EXTRA_DIST = README_daemon libcgroup.doxyfile
> +
> +pkgconfigdir = $(libdir)/pkgconfig
> +pkgconfig_DATA = libcgroup.pc
> Index: libcg/configure.in
> ===================================================================
> --- libcg.orig/configure.in
> +++ libcg/configure.in
> @@ -158,7 +158,8 @@ AC_CONFIG_FILES([Makefile
>       include/Makefile
>       doc/Makefile
>       doc/man/Makefile
> -     dist/Makefile])
> +     dist/Makefile
> +     libcgroup.pc])
>   AC_CONFIG_FILES([dist/libcgroup.spec:dist/libcgroup.spec.in])
>   CFLAGS="$CFLAGS -Wall"
>   AC_OUTPUT
> Index: libcg/libcgroup.pc.in
> ===================================================================
> --- /dev/null
> +++ libcg/libcgroup.pc.in
> @@ -0,0 +1,10 @@
> +pref...@prefix@
> +exec_pref...@exec_prefix@
> +libd...@libdir@
> +included...@includedir@
> +
> +Name: libcgroup
> +Description: Control Group Configuration Library
> +Version: @PACKAGE_VERSION@
> +Libs: -L${libdir} -lcgroup
> +Cflags: -I${includedir}
> Index: libcg/dist/libcgroup.spec.in
> ===================================================================
> --- libcg.orig/dist/libcgroup.spec.in
> +++ libcg/dist/libcgroup.spec.in
> @@ -4,7 +4,7 @@ Name: libcgroup
>   Summary: Tools and libraries to control and monitor control groups
>   Group: System Environment/Libraries
>   Version: @PACKAGE_VERSION@
> -Release:        1%{?dist}
> +Release:        2%{?dist}
>   License: LGPLv2+
>   URL: http://libcg.sourceforge.net/
>   Source0:
> http://downloads.sourceforge.net/libcg/%{name}-%{version}.tar.bz2
   ^ malformed patch, should be on the line above

> @@ -69,6 +69,10 @@ mv -f $RPM_BUILD_ROOT/%{_lib}/libcgroup.
>   rm -f $RPM_BUILD_ROOT/%{_lib}/libcgroup.so
>   ln -sf ../../%{_lib}/libcgroup.so.%{soversion}
> $RPM_BUILD_ROOT/%{_libdir}/libcgroup.so
   ^ malformed patch, should be on the line above

>
> +# move the package config file to /usr/lib/pkgconfig
> +mkdir -p $RPM_BUILD_ROOT/%{_libdir}/pkgconfig
> +mv -f $RPM_BUILD_ROOT/%{_lib}/pkgconfig/libcgroup.pc
> $RPM_BUILD_ROOT/%{_libdir}/pkgconfig/libcgroup.pc
   ^ malformed patch, should be on the line above


> +
>   %clean
>   rm -rf $RPM_BUILD_ROOT
>
> @@ -121,10 +125,13 @@ fi
>   %defattr(-,root,root,-)
>   %{_includedir}/libcgroup.h
>   %{_libdir}/libcgroup.*
> +/%{_libdir}/pkgconfig/libcgroup.pc
>   %doc COPYING INSTALL
>
>
>   %changelog
> +* Thu Feb 18 2010 Dhaval Giani<[email protected]>  0.35.2
> +- Add pkgconfig file
>   * Tue Jan 19 2010 Balbir Singh<[email protected]>  0.35.1
>   - Integrate Jan's fixes for distributing cgget and initscripts
>   * Thu Oct 22 2009 Jan Safranek<[email protected]>  0.34-1
>
>


------------------------------------------------------------------------------
Download Intel&reg; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs 
proactively, and fine-tune applications for parallel performance. 
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Libcg-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/libcg-devel

Reply via email to