Annotation of parser3/src/lib/ltdl/Makefile.am, revision 1.10
1.8 moko 1: ## ltdl.mk -- includable Makefile snippet
1.4 moko 2: ##
1.8 moko 3: ## Copyright (C) 2003-2005, 2007, 2011-2019, 2021-2024 Free Software
4: ## Foundation, Inc.
1.4 moko 5: ## Written by Gary V. Vaughan, 2003
6: ##
7: ## NOTE: The canonical source of this file is maintained with the
8: ## GNU Libtool package. Report bugs to bug-libtool@gnu.org.
9: ##
10: ## GNU Libltdl is free software; you can redistribute it and/or
11: ## modify it under the terms of the GNU Lesser General Public
12: ## License as published by the Free Software Foundation; either
13: ## version 2 of the License, or (at your option) any later version.
14: ##
15: ## As a special exception to the GNU Lesser General Public License,
16: ## if you distribute this file as part of a program or library that
17: ## is built using GNU libtool, you may include this file under the
18: ## same distribution terms that you use for the rest of that program.
19: ##
20: ## GNU Libltdl is distributed in the hope that it will be useful,
21: ## but WITHOUT ANY WARRANTY; without even the implied warranty of
22: ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23: ## GNU Lesser General Public License for more details.
24: ##
25: ## You should have received a copy of the GNU LesserGeneral Public
1.8 moko 26: ## License along with GNU Libltdl. If not, see <https://www.gnu.org/licenses/>.
1.4 moko 27: #####
1.1 paf 28:
1.4 moko 29: ACLOCAL_AMFLAGS = -I m4
30: AUTOMAKE_OPTIONS = foreign
31: AM_CPPFLAGS =
32: AM_LDFLAGS =
33: BUILT_SOURCES =
34: include_HEADERS =
35: noinst_LTLIBRARIES =
36: lib_LTLIBRARIES =
37: EXTRA_LTLIBRARIES =
1.8 moko 38: EXTRA_DIST =
1.4 moko 39: CLEANFILES =
40: MOSTLYCLEANFILES =
1.1 paf 41:
1.4 moko 42: # -I$(srcdir) is needed for user that built libltdl with a sub-Automake
43: # (not as a sub-package!) using 'nostdinc':
44: AM_CPPFLAGS += -DLT_CONFIG_H='<$(LT_CONFIG_H)>' \
45: -DLTDL -I. -I$(srcdir) -Ilibltdl \
1.8 moko 46: -I$(srcdir)/libltdl
1.4 moko 47: AM_LDFLAGS += -no-undefined
1.8 moko 48: LTDL_VERSION_INFO = -version-info 10:3:3
1.1 paf 49:
1.4 moko 50: noinst_LTLIBRARIES += $(LT_DLLOADERS)
1.2 paf 51:
1.4 moko 52: if INSTALL_LTDL
53: ltdlincludedir = $(includedir)/libltdl
54: ltdlinclude_HEADERS = libltdl/lt_system.h \
55: libltdl/lt_error.h \
56: libltdl/lt_dlloader.h
57: include_HEADERS += ltdl.h
58: lib_LTLIBRARIES += libltdl.la
59: endif
60:
61: if CONVENIENCE_LTDL
62: noinst_LTLIBRARIES += libltdlc.la
63: endif
64:
65: libltdl_la_SOURCES = libltdl/lt__alloc.h \
66: libltdl/lt__dirent.h \
67: libltdl/lt__glibc.h \
68: libltdl/lt__private.h \
69: libltdl/lt__strl.h \
70: libltdl/lt_dlloader.h \
71: libltdl/lt_error.h \
1.8 moko 72: libltdl/lt_system.h \
1.4 moko 73: libltdl/slist.h \
74: loaders/preopen.c \
75: lt__alloc.c \
76: lt_dlloader.c \
77: lt_error.c \
78: ltdl.c \
79: ltdl.h \
80: slist.c
81:
82: EXTRA_DIST += lt__dirent.c \
83: lt__strl.c
84:
85: libltdl_la_CPPFLAGS = -DLTDLOPEN=$(LTDLOPEN) $(AM_CPPFLAGS)
86: libltdl_la_LDFLAGS = $(AM_LDFLAGS) $(LTDL_VERSION_INFO) $(LT_DLPREOPEN)
87: libltdl_la_LIBADD = $(LTLIBOBJS)
88: libltdl_la_DEPENDENCIES = $(LT_DLLOADERS) $(LTLIBOBJS)
89:
90: libltdlc_la_SOURCES = $(libltdl_la_SOURCES)
91: libltdlc_la_CPPFLAGS = -DLTDLOPEN=$(LTDLOPEN)c $(AM_CPPFLAGS)
92: libltdlc_la_LDFLAGS = $(AM_LDFLAGS) $(LT_DLPREOPEN)
93: libltdlc_la_LIBADD = $(libltdl_la_LIBADD)
94: libltdlc_la_DEPENDENCIES= $(libltdl_la_DEPENDENCIES)
95:
96: ## The loaders are preopened by libltdl, itself always built from
97: ## pic-objects (either as a shared library, or a convenience library),
98: ## so the loaders themselves must be made from pic-objects too. We
99: ## use convenience libraries for that purpose:
100: EXTRA_LTLIBRARIES += dlopen.la \
101: dld_link.la \
102: dyld.la \
103: load_add_on.la \
104: loadlibrary.la \
105: shl_load.la
106:
107: dlopen_la_SOURCES = loaders/dlopen.c
108: dlopen_la_LDFLAGS = -module -avoid-version
1.8 moko 109: dlopen_la_LIBADD = $(LIBADD_DLOPEN)
1.4 moko 110:
111: dld_link_la_SOURCES = loaders/dld_link.c
112: dld_link_la_LDFLAGS = -module -avoid-version
113: dld_link_la_LIBADD = -ldld
114:
115: dyld_la_SOURCES = loaders/dyld.c
116: dyld_la_LDFLAGS = -module -avoid-version
117:
118: load_add_on_la_SOURCES = loaders/load_add_on.c
119: load_add_on_la_LDFLAGS = -module -avoid-version
120:
121: loadlibrary_la_SOURCES = loaders/loadlibrary.c
122: loadlibrary_la_LDFLAGS = -module -avoid-version
123:
124: shl_load_la_SOURCES = loaders/shl_load.c
125: shl_load_la_LDFLAGS = -module -avoid-version
126: shl_load_la_LIBADD = $(LIBADD_SHL_LOAD)
127:
128: ## Make sure these will be cleaned even when they're not built by default:
129: CLEANFILES += libltdl.la \
130: libltdlc.la \
131: libdlloader.la
132:
133: ## Automake-1.9.6 doesn't clean subdir AC_LIBOBJ compiled objects
134: ## automatically:
135: CLEANFILES += $(LIBOBJS) $(LTLIBOBJS)
136:
137: EXTRA_DIST += COPYING.LIB \
138: README
139:
140: ## --------------------------- ##
141: ## Gnulib Makefile.am snippets ##
142: ## --------------------------- ##
143:
1.8 moko 144: if LTARGZH_EXISTS
145: BUILT_SOURCES += libltdl/$(LT_ARGZ_H)
146: endif
147: EXTRA_DIST += libltdl/lt__argz_.h \
148: lt__argz.c
1.4 moko 149:
150: # We need the following in order to create an <argz.h> when the system
151: # doesn't have one that works with the given compiler.
1.8 moko 152: all-local $(lib_OBJECTS): $(LT_ARGZ_H)
153: libltdl/lt__argz.h: libltdl/lt__argz_.h
154: $(AM_V_at)$(mkinstalldirs) . libltdl
155: $(AM_V_GEN)cp $(srcdir)/libltdl/lt__argz_.h $@-t
156: $(AM_V_at)mv $@-t $@
157: MOSTLYCLEANFILES += libltdl/lt__argz.h \
158: libltdl/lt__argz.h-t
E-mail: