add pkg-config config file

This commit is contained in:
Vlasta Vesely 2023-02-16 10:22:58 +01:00
parent f63901f0cc
commit caf12045fa
4 changed files with 28 additions and 10 deletions

1
.gitignore vendored
View file

@ -3,6 +3,7 @@
*.d
*.so
*.so.*
*.pc
/iast
/tests/test
/tests/coverage

View file

@ -19,13 +19,14 @@ INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
MKDIR_P = @MKDIR_P@
prefix = @prefix@
exec_prefix = @exec_prefix@
bindir = @bindir@
libdir = @libdir@
datarootdir = @datarootdir@
includedir = @includedir@
mandir = @mandir@
prefix = @prefix@
exec_prefix = @exec_prefix@
bindir = @bindir@
libdir = @libdir@
datarootdir = @datarootdir@
includedir = @includedir@
pkgconfigdir = @pkgconfigdir@
mandir = @mandir@
USE_GCOV = @USE_GCOV@
@ -92,9 +93,10 @@ install-lib:
cp -P $(REALNAME) $(SONAME) $(libdir)
install-dev:
$(MKDIR_P) $(includedir)/iast $(libdir)
$(MKDIR_P) $(includedir)/iast $(libdir) $(pkgconfigdir)
$(INSTALL_DATA) $(INCLUDES) $(includedir)/iast
$(INSTALL_DATA) iast.h $(includedir)
$(INSTALL_DATA) $(PROGNAME).pc $(pkgconfigdir)
cp -P $(ANAME) $(LINKNAME) $(libdir)
uninstall: uninstall-prog uninstall-lib uninstall-dev
@ -108,10 +110,11 @@ uninstall-lib:
uninstall-dev:
$(RM) -r $(includedir)/iast $(includedir)/iast.h
$(RM) $(pkgconfigdir)/$(PROGNAME).pc
clean:
$(RM) $(PROGNAME) tests/test $(PROGNAME).1.gz
$(RM) -r $(LIBFILES) *.o */*.o */*.d *.d
$(RM) -r $(LIBFILES) *.o */*.o */*.d *.d $(PROGNAME).pc
$(RM) *.gcda *.gcno tests/coverage */*.test
clean-aux:

View file

@ -17,6 +17,9 @@ AC_PROG_INSTALL
AC_PROG_LN_S
AC_CHECK_TOOL([AR], [ar])
PKG_PROG_PKG_CONFIG
PKG_INSTALLDIR
# Checks for libraries.
PKG_CHECK_MODULES(CHECK, check)
@ -56,5 +59,5 @@ AC_SUBST(COVERAGE_CFLAGS)
AC_SUBST(COVERAGE_LFLAGS)
AC_SUBST(USE_GCOV)
AC_CONFIG_FILES([Makefile])
AC_CONFIG_FILES([Makefile iast.pc])
AC_OUTPUT

11
iast.pc.in Normal file
View file

@ -0,0 +1,11 @@
prefix=@prefix@
exec_prefix=@exec_prefix@
libdir=@libdir@
includedir=@includedir@
Name: libiast
URL: https://github.com/vlastavesely/sanskrit-iast
Description: Library for romanisation of texts written in Devanagari
Version: @PACKAGE_VERSION@
Libs: -L${libdir} -liast
Cflags: