Skip to content

Commit

Permalink
lxc: kill libtool
Browse files Browse the repository at this point in the history
This is useless in a Linux only environment. The .so version is
the version of the package.

Signed-off-by: Cedric Le Goater <clg@fr.ibm.com>
Signed-off-by: Daniel Lezcano <dlezcano@fr.ibm.com>
  • Loading branch information
Cedric Le Goater authored and Daniel Lezcano committed Oct 22, 2009
1 parent 881450b commit 5b46e19
Show file tree
Hide file tree
Showing 3 changed files with 54 additions and 23 deletions.
3 changes: 1 addition & 2 deletions autogen.sh
Expand Up @@ -3,8 +3,7 @@
set -x

test -d autom4te.cache && rm -rf autom4te.cache
libtoolize --force --copy
aclocal -I config || exit 1
aclocal -I config || exit 1
autoheader || exit 1
autoconf || exit 1
automake --add-missing --copy || exit 1
1 change: 0 additions & 1 deletion configure.ac
Expand Up @@ -10,7 +10,6 @@ AM_INIT_AUTOMAKE([-Wno-portability])
AC_CANONICAL_HOST
AM_PROG_CC_C_O
AC_GNU_SOURCE
AC_PROG_LIBTOOL
AC_CHECK_PROG(SETCAP, setcap, yes, no, $PATH$PATH_SEPARATOR/sbin)
AC_CHECK_PROG(DOCBOOK, docbook2man, yes, no)
AM_CONDITIONAL(ENABLE_DOCBOOK, test x$DOCBOOK = xyes)
Expand Down
73 changes: 53 additions & 20 deletions src/lxc/Makefile.am
@@ -1,6 +1,5 @@
AM_CFLAGS= -I$(top_srcdir)/src

lib_LTLIBRARIES = liblxc.la
pkginclude_HEADERS = \
start.h \
error.h \
Expand All @@ -15,8 +14,11 @@ pkginclude_HEADERS = \
log.h \
state.h

sodir=$(libdir)
# use PROGRAMS to avoid complains from automake
so_PROGRAMS = liblxc.so

liblxc_la_SOURCES = \
liblxc_so_SOURCES = \
arguments.c arguments.h \
commands.c commands.h \
create.c \
Expand Down Expand Up @@ -51,8 +53,13 @@ liblxc_la_SOURCES = \
\
cr_plugin_columbia.c lxc_plugin.h

liblxc_la_LDFLAGS = -release @PACKAGE_VERSION@
liblxc_la_LIBADD = -lutil
liblxc_so_CFLAGS = -fPIC -DPIC

liblxc_so_LDFLAGS = \
-shared \
-Wl,-soname,liblxc.so.$(firstword $(subst ., ,$(VERSION)))

liblxc_so_LDADD = -lutil

bin_SCRIPTS = \
lxc-ps \
Expand Down Expand Up @@ -83,49 +90,75 @@ libexec_PROGRAMS = \
lxc-init

lxc_unshare_SOURCES = lxc_unshare.c
lxc_unshare_LDADD = liblxc.la
lxc_unshare_LDFLAGS = -Wl,-E -Wl,-rpath -Wl,$(libdir)
lxc_unshare_LDADD = liblxc.so

lxc_init_SOURCES = lxc_init.c
lxc_init_LDADD = liblxc.la
lxc_init_LDFLAGS = -Wl,-E -Wl,-rpath -Wl,$(libdir)
lxc_init_LDADD = liblxc.so

lxc_create_SOURCES = lxc_create.c
lxc_create_LDADD = liblxc.la
lxc_create_LDFLAGS = -Wl,-E -Wl,-rpath -Wl,$(libdir)
lxc_create_LDADD = liblxc.so

lxc_destroy_SOURCES = lxc_destroy.c
lxc_destroy_LDADD = liblxc.la
lxc_destroy_LDFLAGS = -Wl,-E -Wl,-rpath -Wl,$(libdir)
lxc_destroy_LDADD = liblxc.so

lxc_start_SOURCES = lxc_start.c
lxc_start_LDADD = liblxc.la
lxc_start_LDFLAGS = -Wl,-E -Wl,-rpath -Wl,$(libdir)
lxc_start_LDADD = liblxc.so

lxc_stop_SOURCES = lxc_stop.c
lxc_stop_LDADD = liblxc.la
lxc_stop_LDFLAGS = -Wl,-E -Wl,-rpath -Wl,$(libdir)
lxc_stop_LDADD = liblxc.so

lxc_execute_SOURCES = lxc_execute.c
lxc_execute_LDADD = liblxc.la
lxc_execute_LDFLAGS = -Wl,-E -Wl,-rpath -Wl,$(libdir)
lxc_execute_LDADD = liblxc.so

lxc_monitor_SOURCES = lxc_monitor.c
lxc_monitor_LDADD = liblxc.la
lxc_monitor_LDFLAGS = -Wl,-E -Wl,-rpath -Wl,$(libdir)
lxc_monitor_LDADD = liblxc.so

lxc_wait_SOURCES = lxc_wait.c
lxc_wait_LDADD = liblxc.la
lxc_wait_LDFLAGS = -Wl,-E -Wl,-rpath -Wl,$(libdir)
lxc_wait_LDADD = liblxc.so

lxc_console_SOURCES = lxc_console.c
lxc_console_LDADD = liblxc.la
lxc_console_LDFLAGS = -Wl,-E -Wl,-rpath -Wl,$(libdir)
lxc_console_LDADD = liblxc.so

lxc_info_SOURCES = lxc_info.c
lxc_info_LDADD = liblxc.la
lxc_info_LDFLAGS = -Wl,-E -Wl,-rpath -Wl,$(libdir)
lxc_info_LDADD = liblxc.so

lxc_freeze_SOURCES = lxc_freeze.c
lxc_freeze_LDADD = liblxc.la
lxc_freeze_SLDFLAGS = -Wl,-E -Wl,-rpath -Wl,$(libdir)
lxc_freeze_LDADD = liblxc.so

lxc_unfreeze_SOURCES = lxc_unfreeze.c
lxc_unfreeze_LDADD = liblxc.la
lxc_unfreeze_LDFLAGS = -Wl,-E -Wl,-rpath -Wl,$(libdir)
lxc_unfreeze_LDADD = liblxc.so

lxc_cgroup_SOURCES = lxc_cgroup.c
lxc_cgroup_LDADD = liblxc.la
lxc_cgroup_LDFLAGS = -Wl,-E -Wl,-rpath -Wl,$(libdir)
lxc_cgroup_LDADD = liblxc.so

lxc_checkpoint_SOURCES = lxc_checkpoint.c
lxc_checkpoint_LDADD = liblxc.la
lxc_checkpoint_LDFLAGS = -Wl,-E -Wl,-rpath -Wl,$(libdir)
lxc_checkpoint_LDADD = liblxc.so

lxc_restart_SOURCES = lxc_restart.c
lxc_restart_LDADD = liblxc.la
lxc_restart_LDFLAGS = -Wl,-E -Wl,-rpath -Wl,$(libdir)
lxc_restart_LDADD = liblxc.so


install-exec-local: install-soPROGRAMS
mv $(DESTDIR)$(libdir)/liblxc.so $(DESTDIR)$(libdir)/liblxc.so.$(VERSION)
/sbin/ldconfig -l $(DESTDIR)$(libdir)/liblxc.so.$(VERSION)
cd $(DESTDIR)$(libdir); \
ln -sf liblxc.so.$(firstword $(subst ., ,$(VERSION))) liblxc.so

uninstall-local:
$(RM) $(DESTDIR)$(libdir)/liblxc.so*

0 comments on commit 5b46e19

Please sign in to comment.