Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ ifndef SRCDIR
endif

-include $(TOPDIR)/Makedirlist
-include $(TOPDIR)/src/lib/MakeVars

SUBDIRS = src
ALLSUBDIRS = $(SUBDIRS) doc
Expand All @@ -25,12 +26,18 @@ export::
done
(cd export && $(MAKE) $(DODEPENDOPT) export) || exit 1;

install::
install:: install_pkgconfig
for dir in $(SUBDIRS); \
do \
(cd $${dir} && $(MAKE) $(DODEPENDOPT) install) || exit 1; \
done

ifdef pkgconfigdir
install_pkgconfig::
$(INSTALL) $(INSTALLDIROPT) $(pkgconfigdir)
$(INSTALL) $(INSTALLLIBOPT) $(TOPDIR)/libint2.pc $(pkgconfigdir)
endif

install_inc::
for dir in $(SUBDIRS); \
do \
Expand Down
9 changes: 8 additions & 1 deletion configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -900,6 +900,13 @@ SCRATCHDIR=$withval
)
AC_SUBST(SCRATCHDIR)

PKGCONFIGDIR='$(libdir)/pkgconfig'
AC_ARG_WITH(pkgconfigdir,
[ --with-pkgconfigdir Specifies the location to put pkg-config's data file. Default is $(libdir)/pkgconfig.],
PKGCONFIGDIR=$withval
)
AC_SUBST(PKGCONFIGDIR)

dnl --------- Want absolute path for srcdir, not relative. ---------

if test X$ac_srcdir_defaulted = Xyes; then
Expand Down Expand Up @@ -1392,7 +1399,7 @@ AC_CONFIG_FILES([src/bin/test_eri/stdtests.pl],[chmod +x src/bin/test_eri/stdtes
AC_CONFIG_FILES([src/bin/test_eri/run_timing_suite.pl],[chmod +x src/bin/test_eri/run_timing_suite.pl])
AC_CONFIG_FILES(src/bin/MakeVars src/lib/MakeVars src/lib/MakeRules
doc/MakeVars doc/MakeRules doc/progman/macros.tex doc/classdoc/doxygen.cfg
src/bin/libint/cgshell_ordering.h)
src/bin/libint/cgshell_ordering.h libint2.pc)

dnl --------- Done! ---------
AC_OUTPUT
Expand Down
6 changes: 5 additions & 1 deletion export/MakeRules.export
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

default:: $(TOPDIR)/lib/$(TARGET)

install:: install_inc install_target
install:: install_inc install_target install_pkgconfig

install_inc:: $(TOPDIR)/lib/$(TARGET)
$(INSTALL) $(INSTALLDIROPT) $(DESTDIR)$(includedir)/$(NAME)$(VERSION)
Expand All @@ -17,6 +17,10 @@ install_inc:: $(TOPDIR)/lib/$(TARGET)
-$(INSTALL) $(INSTALLLIBOPT) $(TOPDIR)/include/libint2_config.h $(DESTDIR)$(includedir)/$(NAME)$(VERSION)
-$(INSTALL) $(INSTALLLIBOPT) $(SRCTOPDIR)/include/boys.h $(DESTDIR)$(includedir)/$(NAME)$(VERSION)

install_pkgconfig::
$(INSTALL) $(INSTALLDIROPT) $(pkgconfigdir)
$(INSTALL) $(INSTALLLIBOPT) $(TOPDIR)/libint2.pc $(pkgconfigdir)

install_target:: $(TOPDIR)/lib/$(TARGET)
$(INSTALL) $(INSTALLDIROPT) $(DESTDIR)$(libdir)
$(LTINST) $(INSTALL) $(INSTALLLIBOPT) $< $(DESTDIR)$(libdir)
Expand Down
1 change: 1 addition & 0 deletions export/MakeVars.export
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ exec_prefix=@exec_prefix@
bindir=@bindir@
libdir=@libdir@
includedir=@libintincludedir@
pkgconfigdir=@PKGCONFIGDIR@

RANLIB = @RANLIB@
COMPRESS = gzip
Expand Down
1 change: 1 addition & 0 deletions export/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ exportdir::
-$(INSTALL) $(INSTALLLIBOPT) $(SRCTOPDIR)/src/bin/libint/util_types.h $(TOPDIR)/$(EXPORTDIR)/include
-$(INSTALL) $(INSTALLLIBOPT) $(SRCTOPDIR)/src/bin/libint/cgshellinfo.h $(TOPDIR)/$(EXPORTDIR)/include
-$(INSTALL) $(INSTALLLIBOPT) $(SRCTOPDIR)/src/lib/libint/*.h $(TOPDIR)/$(EXPORTDIR)/include
-$(INSTALL) $(INSTALLLIBOPT) $(SRCTOPDIR)/libint2.pc.in $(TOPDIR)/$(EXPORTDIR)
-$(INSTALL) $(INSTALLLIBOPT) $(TOPDIR)/src/bin/libint/cgshell_ordering.h $(TOPDIR)/$(EXPORTDIR)/include
-$(INSTALL) $(INSTALLLIBOPT) $(TOPDIR)/include/libint2_config.h $(TOPDIR)/$(EXPORTDIR)/include/libint2_config.h.in
-$(INSTALL) $(INSTALLLIBOPT) $(SRCDIR)/INSTALL.export $(TOPDIR)/$(EXPORTDIR)/INSTALL
Expand Down
9 changes: 8 additions & 1 deletion export/configure.export
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,13 @@ LDFLAGS=$withval
echo Using extra library directories: $withval
)

PKGCONFIGDIR='$(libdir)/pkgconfig'
AC_ARG_WITH(pkgconfigdir,
[ --with-pkgconfigdir Specifies the location to put pkg-config's data file. Default is $(libdir)/pkgconfig.],
PKGCONFIGDIR=$withval
)
AC_SUBST(PKGCONFIGDIR)

dnl --------- Want absolute path for srcdir, not relative. ---------

if test X$ac_srcdir_defaulted = Xyes; then
Expand Down Expand Up @@ -399,7 +406,7 @@ LIBSUF=la
ENABLESHARED=yes
AC_SUBST(ENABLESHARED)

AC_CONFIG_FILES(MakeVars MakeRules MakeSuffixRules doc/Makefile)
AC_CONFIG_FILES(MakeVars MakeRules MakeSuffixRules doc/Makefile libint2.pc)

dnl --------- Done! ---------
AC_OUTPUT
Expand Down
10 changes: 10 additions & 0 deletions libint2.pc.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
prefix=@prefix@
exec_prefix=@exec_prefix@
libdir=@libdir@
includedir=@includedir@

Name: libint2
Description: a library for the evaluation of molecular integrals of many-body operators over Gaussian functions
Version: @PACKAGE_VERSION@
Libs: -L${libdir} -lint2
Cflags: -I${includedir} -I${includedir}/libint2
1 change: 1 addition & 0 deletions src/lib/MakeVars.in
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ exec_prefix=@exec_prefix@
bindir=@bindir@
libdir=@libdir@
includedir=@libintincludedir@
pkgconfigdir=@PKGCONFIGDIR@

RANLIB = @RANLIB@
COMPRESS = gzip
Expand Down