Browse Source

Generate pkg-config file

nbd-vmsplice
Vitaliy Filippov 1 year ago
parent
commit
75b47a6298
  1. 1
      debian/vitastor-client-dev.install
  2. 1
      rpm/vitastor-el7.spec
  3. 1
      rpm/vitastor-el8.spec
  4. 2
      src/CMakeLists.txt
  5. 12
      src/vitastor.pc.in

1
debian/vitastor-client-dev.install

@ -1 +1,2 @@
usr/include
usr/lib/*/pkgconfig

1
rpm/vitastor-el7.spec

@ -141,6 +141,7 @@ cp -r mon %buildroot/usr/lib/vitastor
%files -n vitastor-client-devel
%_includedir/vitastor_c.h
%_libdir/pkgconfig
%files -n vitastor-fio

1
rpm/vitastor-el8.spec

@ -138,6 +138,7 @@ cp -r mon %buildroot/usr/lib/vitastor
%files -n vitastor-client-devel
%_includedir/vitastor_c.h
%_libdir/pkgconfig
%files -n vitastor-fio

2
src/CMakeLists.txt

@ -158,6 +158,7 @@ add_executable(vitastor-cli
target_link_libraries(vitastor-cli
vitastor_client
)
configure_file(vitastor.pc.in vitastor.pc @ONLY)
# vitastor-dump-journal
add_executable(vitastor-dump-journal
@ -248,6 +249,7 @@ install(
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}
)
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/vitastor.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig)
if (${WITH_FIO})
install(TARGETS fio_vitastor fio_vitastor_blk fio_vitastor_sec LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR})
endif (${WITH_FIO})

12
src/vitastor.pc.in

@ -0,0 +1,12 @@
prefix=@CMAKE_INSTALL_PREFIX@
exec_prefix=${prefix}
libdir=${prefix}/@CMAKE_INSTALL_LIBDIR@
includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@
Name: Vitastor
Description: Vitastor client library
Version: 0.6.8
Libs: -L${libdir} -lvitastor_client
Cflags: -I${includedir}
Loading…
Cancel
Save