Skip to Content.
Sympa Menu

sm-commit - [SM-Commit] GIT changes to master grimoire by Eric Sandall (f17afa3407626cc2c8ecd23b53594917368cfa14)

sm-commit AT lists.ibiblio.org

Subject: Source Mage code commit list

List archive

Chronological Thread  
  • From: Eric Sandall <scm AT sourcemage.org>
  • To: sm-commit AT lists.ibiblio.org
  • Subject: [SM-Commit] GIT changes to master grimoire by Eric Sandall (f17afa3407626cc2c8ecd23b53594917368cfa14)
  • Date: Wed, 16 Mar 2016 18:59:15 +0000

GIT changes to master grimoire by Eric Sandall <sandalle AT sourcemage.org>:

disk/lvm/BUILD | 2 +-
disk/lvm/DEPENDS | 2 ++
disk/lvm/HISTORY | 13 +++++++++++++
disk/lvm/PRE_BUILD | 17 ++---------------
disk/lvm/lvm-static-hotfix.patch | 21 +++++++++++++++++++++
5 files changed, 39 insertions(+), 16 deletions(-)

New commits:
commit f17afa3407626cc2c8ecd23b53594917368cfa14
Author: Eric Sandall <sandalle AT sourcemage.org>
Commit: Eric Sandall <sandalle AT sourcemage.org>

lvm: LIBS hack for pthread and uuid is still required

Without this patch:
gcc -march=core2 -fPIC -DPIC -pipe -DPIC -fPIC -O2 -s -Wl,-O1
-Wl,--hash-style=gnu -L./libdm -L./lib -L./libdaemon/client
-L./daemons/dmeventd -L../libdm -L../lib -L../libdaemon/client
-L../daemons/dmeventd -static -L../libdm/ioctl -o lvm.static \ dumpconfig.o
formats.o lvchange.o lvconvert.o lvconvert_poll.o lvcreate.o lvdisplay.o
lvextend.o lvmchange.o lvmcmdline.o lvmdiskscan.o lvreduce.o lvremove.o
lvrename.o lvresize.o lvscan.o polldaemon.o pvchange.o pvck.o pvcreate.o
pvdisplay.o pvmove.o pvmove_poll.o pvremove.o pvresize.o pvscan.o reporter.o
segtypes.o tags.o toollib.o vgcfgbackup.o vgcfgrestore.o vgchange.o vgck.o
vgcreate.o vgconvert.o vgdisplay.o vgexport.o vgextend.o vgimport.o vgmerge.o
vgmknodes.o lvpoll.o vgreduce.o vgremove.o vgrename.o vgscan.o vgsplit.o
lvm-static.o -llvm-internal -ldaemonclient -ldl -lblkid -ldevmapper-event
-ldevmapper -lblkid -lrt
../lib/liblvm-internal.a(sharedlib.o): In function
`load_shared_library': sharedlib.c:(.text+0x130): warning: Using 'dlopen'
in statically linked applications requires at runtime the shared libraries
from the glibc version used for linking

/usr/lib/gcc/x86_64-pc-linux-gnu/5.3.0/../../../../lib/libblkid.a(libblkid_la-probe.o):
In function `blkid_unparse_uuid': probe.c:(.text+0x1e81): undefined
reference to `uuid_unparse'
../daemons/dmeventd/libdevmapper-event.a(libdevmapper-event.o): In
function `dm_event_log':
libdevmapper-event.c:(.text+0x2cf7): undefined reference to
`pthread_mutex_lock'
libdevmapper-event.c:(.text+0x2e29): undefined reference to `pthread_self'
libdevmapper-event.c:(.text+0x2d2f): undefined reference to
`pthread_mutex_unlock'
../libdm/ioctl/libdevmapper.a(pool.o): In function `dm_pool_create':
pool.c:(.text+0x134): undefined reference to `pthread_mutex_lock'
pool.c:(.text+0x14f): undefined reference to `pthread_mutex_unlock'
../libdm/ioctl/libdevmapper.a(pool.o): In function `dm_pool_destroy':
pool.c:(.text+0x209): undefined reference to `pthread_mutex_lock'
pool.c:(.text+0x21d): undefined reference to `pthread_mutex_unlock'
../libdm/ioctl/libdevmapper.a(pool.o): In function `dm_pools_check_leaks':
pool.c:(.text+0x6be): undefined reference to `pthread_mutex_lock'
pool.c:(.text+0x7a9): undefined reference to `pthread_mutex_unlock'
pool.c:(.text+0x82e): undefined reference to `pthread_mutex_unlock'
/usr/lib/gcc/x86_64-pc-linux-gnu/5.3.0/libgcc_eh.a(unwind-dw2-fde-dip.o):
In function `__gthread_mutex_lock':
/usr/src/gcc-5.3.0.bld/x86_64-pc-linux-gnu/libgcc/./gthr-default.h:748:
undefined reference to `pthread_mutex_lock'
/usr/src/gcc-5.3.0.bld/x86_64-pc-linux-gnu/libgcc/./gthr-default.h:748:
undefined reference to `pthread_mutex_lock'
/usr/src/gcc-5.3.0.bld/x86_64-pc-linux-gnu/libgcc/./gthr-default.h:748:
undefined reference to `pthread_mutex_lock'
/usr/src/gcc-5.3.0.bld/x86_64-pc-linux-gnu/libgcc/./gthr-default.h:748:
undefined reference to `pthread_mutex_lock'
/usr/lib/gcc/x86_64-pc-linux-gnu/5.3.0/libgcc_eh.a(unwind-dw2-fde-dip.o):
In function `__gthread_mutex_unlock':
/usr/src/gcc-5.3.0.bld/x86_64-pc-linux-gnu/libgcc/./gthr-default.h:778:
undefined reference to `pthread_mutex_unlock'
/usr/lib/gcc/x86_64-pc-linux-gnu/5.3.0/libgcc_eh.a(unwind-dw2-fde-dip.o):
In function `__gthread_mutex_lock':
/usr/src/gcc-5.3.0.bld/x86_64-pc-linux-gnu/libgcc/./gthr-default.h:748:
undefined reference to `pthread_mutex_lock'
/usr/lib/gcc/x86_64-pc-linux-gnu/5.3.0/libgcc_eh.a(unwind-dw2-fde-dip.o):
In function `__gthread_mutex_unlock':
/usr/src/gcc-5.3.0.bld/x86_64-pc-linux-gnu/libgcc/./gthr-default.h:778:
undefined reference to `pthread_mutex_unlock'
/usr/src/gcc-5.3.0.bld/x86_64-pc-linux-gnu/libgcc/./gthr-default.h:778:
undefined reference to `pthread_mutex_unlock'
/usr/src/gcc-5.3.0.bld/x86_64-pc-linux-gnu/libgcc/./gthr-default.h:778:
undefined reference to `pthread_mutex_unlock'
/usr/src/gcc-5.3.0.bld/x86_64-pc-linux-gnu/libgcc/./gthr-default.h:778:
undefined reference to `pthread_mutex_unlock'
/usr/src/gcc-5.3.0.bld/x86_64-pc-linux-gnu/libgcc/./gthr-default.h:778:
undefined reference to `pthread_mutex_unlock'
collect2: error: ld returned 1 exit status
Makefile:149: recipe for target 'lvm.static' failed

commit c813dd9360264d01dccafe9beb520ea7eead7475
Author: Eric Sandall <sandalle AT sourcemage.org>
Commit: Eric Sandall <sandalle AT sourcemage.org>

lvm: Depends on util-linux for libblkid

Cleanup formatting

diff --git a/disk/lvm/BUILD b/disk/lvm/BUILD
index 0c1b0e5..1447876 100755
--- a/disk/lvm/BUILD
+++ b/disk/lvm/BUILD
@@ -3,7 +3,7 @@
--sbindir=$INSTALL_ROOT/sbin \
--libdir=$INSTALL_ROOT/lib \
--sysconfdir=$INSTALL_ROOT/etc \
- --mandir=$INSTALL_ROOT/usr/share/man \
+ --mandir=$INSTALL_ROOT/usr/share/man \
--enable-static_link \
$LVM_OPTS $OPTS &&
make_single &&
diff --git a/disk/lvm/DEPENDS b/disk/lvm/DEPENDS
index f102b30..4483de6 100755
--- a/disk/lvm/DEPENDS
+++ b/disk/lvm/DEPENDS
@@ -1,3 +1,5 @@
+depends util-linux &&
+
optional_depends pkgconfig \
"--enable-pkgconfig" \
"" \
diff --git a/disk/lvm/HISTORY b/disk/lvm/HISTORY
index 30ea877..670ffd2 100644
--- a/disk/lvm/HISTORY
+++ b/disk/lvm/HISTORY
@@ -1,6 +1,19 @@
+2016-03-16 Eric Sandall <sandalle AT sourcemage.org>
+ * PRE_BUILD: Move patch to lvm-static-hotfix.patch
+ Apply lvm-static-hotfix.patch
+ * lvm-static-hotfix.patch: Fix static linking
+ My machine doesn't use --as-needed and still needs this
+ Also patches dmsetup.static
+ Uses more portable -pthread instead of -lpthread
+
2016-03-16 Thomas Orgis <sobukus AT sourcemage.org>
* PRE_BUILD: added, to fix static linking again

+2016-03-16 Eric Sandall <sandalle AT sourcemage.org>
+ * DEPENDS: Depends on util-linux for libblkid
+ * PRE_BUILD: Apply lvm-static-hotfix.patch
+ * lvm-static-hotfix.patch: Still required
+
2016-03-08 Treeve Jelbert <treeve AT sourcemage.org>
* DETAILS: version 2.02.145
* lvm-static-hotfix.patch PRE_BUILD: deleted
diff --git a/disk/lvm/PRE_BUILD b/disk/lvm/PRE_BUILD
index 79fa080..6c9a890 100755
--- a/disk/lvm/PRE_BUILD
+++ b/disk/lvm/PRE_BUILD
@@ -1,18 +1,5 @@
default_pre_build &&
cd "$SOURCE_DIRECTORY" &&
# Please only remove that patch if it _really_ is not needed anymore.
-message "${MESSAGE_COLOR}Patching for breakage of static build \
-(presumably with --as-needed).$DEFAULT_COLOR" &&
-patch -p0 <<'EOT'
---- tools/Makefile.in.orig 2016-03-16 17:32:09.859648238 +0100
-+++ tools/Makefile.in 2016-03-16 17:35:31.807152952 +0100
-@@ -147,7 +147,7 @@
-
- lvm.static: $(OBJECTS) lvm-static.o $(top_builddir)/lib/liblvm-internal.a
$(interfacebuilddir)/libdevmapper.a
- $(CC) $(CFLAGS) $(LDFLAGS) -static -L$(interfacebuilddir) -o $@ \
-- $(OBJECTS) lvm-static.o $(LVMLIBS) $(STATIC_LIBS) $(LIBS)
-+ $(OBJECTS) lvm-static.o $(LVMLIBS) $(STATIC_LIBS) $(LIBS)
$(PTHREAD_LIBS) -luuid
-
- liblvm2cmd.a: $(top_builddir)/lib/liblvm-internal.a $(OBJECTS) lvmcmdlib.o
lvm2cmd.o
- cat $(top_builddir)/lib/liblvm-internal.a > $@
-EOT
+message "${MESSAGE_COLOR}Patching for breakage of static
build${DEFAULT_COLOR}" &&
+patch -p1 < "${SCRIPT_DIRECTORY}"/lvm-static-hotfix.patch
diff --git a/disk/lvm/lvm-static-hotfix.patch
b/disk/lvm/lvm-static-hotfix.patch
new file mode 100644
index 0000000..dc0d350
--- /dev/null
+++ b/disk/lvm/lvm-static-hotfix.patch
@@ -0,0 +1,21 @@
+diff -Naur LVM2.2.02.145.orig/tools/Makefile.in
LVM2.2.02.145/tools/Makefile.in
+--- LVM2.2.02.145.orig/tools/Makefile.in 2016-03-04 10:03:29.000000000
-0800
++++ LVM2.2.02.145/tools/Makefile.in 2016-03-16 11:48:31.705347528 -0700
+@@ -130,7 +130,7 @@
+
+ dmsetup.static: dmsetup.o $(interfacebuilddir)/libdevmapper.a
+ $(CC) $(CFLAGS) $(LDFLAGS) -static -L$(interfacebuilddir) \
+- -o $@ dmsetup.o -ldevmapper $(M_LIBS) $(PTHREAD_LIBS)
$(STATIC_LIBS) $(LIBS)
++ -o $@ dmsetup.o -ldevmapper $(M_LIBS) $(PTHREAD_LIBS)
$(STATIC_LIBS) $(LIBS) -pthread
+
+ all: device-mapper
+
+@@ -147,7 +147,7 @@
+
+ lvm.static: $(OBJECTS) lvm-static.o $(top_builddir)/lib/liblvm-internal.a
$(interfacebuilddir)/libdevmapper.a
+ $(CC) $(CFLAGS) $(LDFLAGS) -static -L$(interfacebuilddir) -o $@ \
+- $(OBJECTS) lvm-static.o $(LVMLIBS) $(STATIC_LIBS) $(LIBS)
++ $(OBJECTS) lvm-static.o $(LVMLIBS) $(STATIC_LIBS) $(LIBS)
-luuid -pthread
+
+ liblvm2cmd.a: $(top_builddir)/lib/liblvm-internal.a $(OBJECTS) lvmcmdlib.o
lvm2cmd.o
+ cat $(top_builddir)/lib/liblvm-internal.a > $@



  • [SM-Commit] GIT changes to master grimoire by Eric Sandall (f17afa3407626cc2c8ecd23b53594917368cfa14), Eric Sandall, 03/16/2016

Archive powered by MHonArc 2.6.24.

Top of Page