Skip to content

Commit

Permalink
Makefile.am: dynamic vs static
Browse files Browse the repository at this point in the history
start using DYNAMIC in order to be aligned with the
  --enable-all-static
argument.
  • Loading branch information
vjardin committed Nov 14, 2024
1 parent ddafc9f commit 2731a2c
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
6 changes: 6 additions & 0 deletions mlxsign_lib/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,13 @@ AM_CPPFLAGS = \
AM_CXXFLAGS = -Wall -W -g -MP -MD -pipe $(COMPILER_FPIC)
AM_CXXFLAGS += -DTOOLS_CRYPTO_KEY='$(TOOLS_CRYPTO_KEY)' -DTOOLS_CRYPTO_IV='$(TOOLS_CRYPTO_IV)'

if BUILD_DYNAMIC
pkglib_LTLIBRARIES = libmlxsign.la
libmlxsign_la_LDFLAGS = -version-info 0:0:0 -no-undefined
else
noinst_LTLIBRARIES = libmlxsign.la
endif

libmlxsign_la_SOURCES = mlxsign_lib.cpp mlxsign_lib.h mlxsign_com_def.h \
mlxsign_openssl_engine.h mlxsign_openssl_engine.cpp \
mlxsign_signer_interface.h mlxsign_signer_interface.cpp
Expand Down
11 changes: 11 additions & 0 deletions mtcr_ul/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,12 @@

AM_CPPFLAGS = -I$(top_srcdir) -I$(top_srcdir)/include/mtcr_ul -I$(top_srcdir)/common -I$(top_srcdir)/dev_mgt

if BUILD_DYNAMIC
pkglib_LTLIBRARIES = libmtcr_ul.la
libmtcr_ul_la_LDFLAGS = -version-info 0:0:0 -no-undefined
else
noinst_LTLIBRARIES = libmtcr_ul.la
endif

libmtcr_ul_la_SOURCES = mtcr_ul.c mtcr_ib.h mtcr_int_defs.h\
mtcr_ib_res_mgt.h mtcr_ib_res_mgt.c\
Expand All @@ -53,6 +58,12 @@ endif
libraryincludedir=$(includedir)/mstflint
libraryinclude_HEADERS = $(top_srcdir)/include/mtcr_ul/mtcr.h $(top_srcdir)/include/mtcr_ul/mtcr_com_defs.h $(top_srcdir)/include/mtcr_ul/mtcr_mf.h

if BUILD_DYNAMIC
install-exec-hook:
rm -f $(DESTDIR)$(pkglibdir)/libmtcr_ul.so* $(DESTDIR)$(pkglibdir)/libmtcr_ul.la
ln -snf mstflint/libmtcr_ul.a $(DESTDIR)$(libdir)/
else
install-exec-hook:
rm -f $(DESTDIR)$(libdir)/libmtcr_ul.so* $(DESTDIR)$(libdir)/libmtcr_ul.la
ln -snf mstflint/libmtcr_ul.a $(DESTDIR)$(libdir)/
endif

0 comments on commit 2731a2c

Please sign in to comment.