source: trunk/build_support/Makefile.am @ 3417

Last change on this file since 3417 was 3417, checked in by Peter, 4 years ago

updating copyright statements

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 3.3 KB
Line 
1## $Id: Makefile.am 3417 2015-05-25 01:35:59Z peter $
2
3# Copyright (C) 2008, 2009, 2010, 2011, 2012, 2013, 2014 Peter Johansson
4#
5# This file is part of the yat library, http://dev.thep.lu.se/yat
6#
7# The yat library is free software; you can redistribute it and/or
8# modify it under the terms of the GNU General Public License as
9# published by the Free Software Foundation; either version 3 of the
10# License, or (at your option) any later version.
11#
12# The yat library is distributed in the hope that it will be useful,
13# but WITHOUT ANY WARRANTY; without even the implied warranty of
14# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15# General Public License for more details.
16#
17# You should have received a copy of the GNU General Public License
18# along with yat. If not, see <http://www.gnu.org/licenses/>.
19
20bin_SCRIPTS = build_support/for_installation/yat-config
21
22pkgconfigexecdir = $(libdir)/pkgconfig
23pkgconfigexec_DATA= build_support/yat.pc
24
25CLEANFILES += build_support/yat.pc build_support/yat-config
26CLEANFILES += build_support/for_installation/yat-config
27
28EXTRA_DIST +=  build_support/yat-config.in build_support/yat.pc.in
29
30edit = $(SED) \
31  -e 's|@SHELL[@]|$(SHELL)|g' \
32  -e 's|@prefix[@]|$(prefix)|g' \
33  -e 's|@exec_prefix[@]|$(exec_prefix)|g' \
34  -e 's|@bindir[@]|$(bindir)|g' \
35  -e 's|@libdir[@]|$(libdir)|g' \
36  -e 's|@includedir[@]|$(includedir)|g' \
37  -e 's|@CXX[@]|$(CXX)|g' \
38  -e 's|@CXXCPP[@]|$(CXXCPP)|g' \
39  -e 's|@CPPFLAGS[@]|$(CPPFLAGS)|g' \
40  -e 's|@CXXFLAGS[@]|$(CXXFLAGS)|g' \
41  -e 's|@LDFLAGS[@]|$(LDFLAGS)|g' \
42  -e 's|@LIBS[@]|$(LIBS)|g' \
43  -e 's|@YAT_CBLAS_LIB[@]|$(YAT_CBLAS_LIB)|g' \
44  -e 's|@YAT_CPPFLAGS[@]|$(YAT_CPPFLAGS)|g' \
45  -e 's|@YAT_CXXFLAGS[@]|$(YAT_CXXFLAGS)|g' \
46  -e 's|@YAT_LDFLAGS[@]|$(YAT_LDFLAGS)|g' \
47  -e 's|@YAT_PC_LIBS[@]|$(YAT_PC_LIBS)|g' \
48  -e 's|@YAT_PC_REQUIRES[@]|$(YAT_PC_REQUIRES)|g' \
49  -e 's|@YAT_PRIMARY_LIBS[@]|$(YAT_PRIMARY_LIBS)|g' \
50  -e 's|@YAT_STATIC_LIBS[@]|$(YAT_STATIC_LIBS)|g' \
51  -e 's|@LIBM[@]|$(LIBM)|g' \
52  -e 's|@PACKAGE[@]|$(PACKAGE)|g' \
53  -e 's|@PACKAGE_BUGREPORT[@]|$(PACKAGE_BUGREPORT)|g' \
54  -e 's|@PACKAGE_URL[@]|$(PACKAGE_URL)|g' \
55  -e 's|@VERSION[@]|$(VERSION)|g' \
56  -e 's|@YAT_MAJOR_VERSION[@]|$(YAT_MAJOR_VERSION)|g' \
57  -e 's|@YAT_MINOR_VERSION[@]|$(YAT_MINOR_VERSION)|g' \
58  -e 's|@YAT_PATCH_VERSION[@]|$(YAT_PATCH_VERSION)|g' \
59  -e 's|@YAT_DEV_BUILD[@]|$(YAT_DEV_BUILD)|g' \
60  -e 's|@gsl_version[@]|$(gsl_version)|g' \
61  -e 's|@abs_top_srcdir[@]|$(abs_top_srcdir)|g' \
62  -e 's|@abs_top_builddir[@]|$(abs_top_builddir)|g' \
63  -e 's|@boost_version[@]|$(boost_version)|g'
64
65build_support/yat-config: Makefile $(srcdir)/build_support/yat-config.in
66  @$(AM_V_GEN)rm -f $@ $@.tmp \
67  && echo "#! $(SHELL)" > $@.tmp \
68  && echo "# yat-config generated by make from yat-config.in" >> $@.tmp \
69  && $(edit) '$(srcdir)/$@.in' >>$@.tmp \
70  && chmod +x $@.tmp \
71  && chmod a-w $@.tmp \
72  && mv $@.tmp $@
73
74build_support/for_installation/yat-config: build_support/yat-config
75  $(AM_V_GEN)rm -f $@ $@-t \
76  && $(MKDIR_P) build_support/for_installation \
77  && sed 's|installed=no|installed=yes|g' < build_support/yat-config > $@-t \
78  && mv $@-t $@
79
80build_support/yat.pc: $(srcdir)/build_support/yat.pc.in build_support/gen_yat_pc.sh Makefile
81  $(AM_V_GEN)rm -f $@ $@-t \
82  && cd build_support \
83  && $(SHELL) gen_yat_pc.sh --prefix="$(prefix)" \
84  --exec-prefix="$(exec_prefix)" \
85  --libdir="$(libdir)" --includedir="$(includedir)" \
86  --input="../$(srcdir)/build_support/yat.pc.in" > yat.pc-t \
87  && mv yat.pc-t yat.pc
Note: See TracBrowser for help on using the repository browser.