Skip to contentSkip to conversation

libmpathpersist: depend on libmultipath

PATCH In review Christian Hesse 2 participants 7 messages May 6, 2020 – May 7, 2020

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/2 libmpathpersist: depend on libmultipath

From: Christian Hesse <[email protected]>

Without this the build fails with:

/usr/bin/ld: cannot find -lmultipath

---
 Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Makefile +1 -1
index 1dee3680..ba1d73ba 100644
@@ -28,7 +28,7 @@ all:	$(BUILDDIRS)
 $(BUILDDIRS):
 	$(MAKE) -C $@
 
-multipath multipathd mpathpersist: libmultipath
+libmpathpersist multipath multipathd mpathpersist: libmultipath
 mpathpersist:  libmpathpersist
 
 $(BUILDDIRS.clean):
#1 lore raw

PATCH 2/2 libmultipath: create libdir on install

From: Christian Hesse <[email protected]>

Without this installation fails with:

install: target '$DESTDIR/usr/lib/multipath' is not a directory

---
 libmultipath/prioritizers/Makefile | 1 +
 1 file changed, 1 insertion(+)
libmultipath/prioritizers/Makefile +1 -0
index 9d0fe03c..11da5be2 100644
@@ -35,6 +35,7 @@ libprio%.so: %.o
 	$(CC) $(LDFLAGS) $(SHARED_FLAGS) -o $@ $^
 
 install: $(LIBS)
+	$(INSTALL_PROGRAM) -d $(DESTDIR)$(libdir)
 	$(INSTALL_PROGRAM) -m 755 libprio*.so $(DESTDIR)$(libdir)
 
 uninstall:
#2 lore raw

Re: [PATCH 2/2] libmultipath: create libdir on install

Christian Hesse <[email protected]> on Wed, 2020/05/06 09:35:

Quoted 15 lines

From: Christian Hesse <[email protected]>

Without this installation fails with:

install: target '$DESTDIR/usr/lib/multipath' is not a directory

---
 libmultipath/prioritizers/Makefile | 1 +
 1 file changed, 1 insertion(+)
(quoted diff) +0 -0

b/libmultipath/prioritizers/Makefile index 9d0fe03c..11da5be2 100644

libmultipath/prioritizers/Makefile libprio%.so: %.o · line 41

Quoted 7 lines
libmultipath/prioritizers/Makefile +1 -0
@@ -35,6 +35,7 @@ libprio%.so: %.o
 	$(CC) $(LDFLAGS) $(SHARED_FLAGS) -o $@ $^
 
 install: $(LIBS)
+	$(INSTALL_PROGRAM) -d $(DESTDIR)$(libdir)
 	$(INSTALL_PROGRAM) -m 755 libprio*.so $(DESTDIR)$(libdir)
 
 uninstall:

Ignore this one... It does not fix the issue. The build system has to be fixed for simultaneous jobs when installing.

For now installing with just one job (make -j1).

Signature · 3 lines
main(a){char*c=/*    Schoene Gruesse                         */"B?IJj;MEH"
"CX:;",b;for(a/*    Best regards             my address:    */=0;b=c[a++];)
putchar(b-1/(/*    Chris            cc -ox -xc - && ./x    */b/42*2-3)*42);}
#3 lore raw

Re: [PATCH 2/2] libmultipath: create libdir on install

Quoted 23 lines · Christian Hesse

Christian Hesse <[email protected]> on Wed, 2020/05/06 09:35:

Quoted 22 lines

From: Christian Hesse <[email protected]>

Without this installation fails with:

install: target '$DESTDIR/usr/lib/multipath' is not a directory

---
 libmultipath/prioritizers/Makefile | 1 +
 1 file changed, 1 insertion(+)
(quoted diff) +0 -0

b/libmultipath/prioritizers/Makefile index 9d0fe03c..11da5be2 100644

libmultipath/prioritizers/Makefile +1 -0
@@ -35,6 +35,7 @@ libprio%.so: %.o
 	$(CC) $(LDFLAGS) $(SHARED_FLAGS) -o $@ $^
 
 install: $(LIBS)
+	$(INSTALL_PROGRAM) -d $(DESTDIR)$(libdir)
 	$(INSTALL_PROGRAM) -m 755 libprio*.so $(DESTDIR)$(libdir)
 
Quoted 7 lines

libmultipath/prioritizers/Makefile libprio%.so: %.o · line 41

Quoted 1 line
libmultipath/prioritizers/Makefile +0 -0
 uninstall:

Ignore this one... It does not fix the issue. The build system has to be
fixed for simultaneous jobs when installing.

For now installing with just one job (make -j1).

Right. Feel free to send patches for this. I've never felt the urge to run "make install" parallelized; it takes less then 1s on my laptop.

Martin

#4 lore raw

Re: [PATCH 2/2] libmultipath: create libdir on install

Martin Wilck <[email protected]> on Thu, 2020/05/07 23:13:

Quoted 30 lines · Christian Hesse
Quoted 29 lines

Christian Hesse <[email protected]> on Wed, 2020/05/06 09:35:

Quoted 16 lines

From: Christian Hesse <[email protected]>

Without this installation fails with:

install: target '$DESTDIR/usr/lib/multipath' is not a directory

---
 libmultipath/prioritizers/Makefile | 1 +
 1 file changed, 1 insertion(+)
(quoted diff) +0 -0

b/libmultipath/prioritizers/Makefile index 9d0fe03c..11da5be2 100644

libmultipath/prioritizers/Makefile libprio%.so: %.o · line 41

Quoted 7 lines
libmultipath/prioritizers/Makefile +1 -0
@@ -35,6 +35,7 @@ libprio%.so: %.o
 	$(CC) $(LDFLAGS) $(SHARED_FLAGS) -o $@ $^
 
 install: $(LIBS)
+	$(INSTALL_PROGRAM) -d $(DESTDIR)$(libdir)
 	$(INSTALL_PROGRAM) -m 755 libprio*.so $(DESTDIR)$(libdir)
 
 uninstall:  

Ignore this one... It does not fix the issue. The build system has to be
fixed for simultaneous jobs when installing.

Quoted 4 lines
Quoted 1 line

For now installing with just one job (make -j1).

Right. Feel free to send patches for this. I've never felt the urge to run "make install" parallelized; it takes less then 1s on my laptop.

Well, doing things in parallel is the default on our build servers... Via environment variable MAKEFLAGS="-j#". Running just one job is extra work. :-p

If I have some spare time I will have a look again.

Signature · 3 lines
main(a){char*c=/*    Schoene Gruesse                         */"B?IJj;MEH"
"CX:;",b;for(a/*    Best regards             my address:    */=0;b=c[a++];)
putchar(b-1/(/*    Chris            cc -ox -xc - && ./x    */b/42*2-3)*42);}
Reviewed-by on v1 1/2
#5 lore raw
In reply to Christian Hesse
Quoted 5 lines · Christian Hesse

From: Christian Hesse <[email protected]>

Without this the build fails with:

/usr/bin/ld: cannot find -lmultipath

Thank you. Strange, I've built multipath thousands of times and never hit this error.

Quoted 11 lines
---
 Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Makefile +0 -0
index 1dee3680..ba1d73ba 100644

Makefile all: $(BUILDDIRS) · line 32

Quoted 6 lines
Makefile +1 -1
@@ -28,7 +28,7 @@ all:	$(BUILDDIRS)
 $(BUILDDIRS):
 	$(MAKE) -C $@
 
-multipath multipathd mpathpersist: libmultipath
+libmpathpersist multipath multipathd mpathpersist: libmultipath
 mpathpersist:  libmpathpersist
#6 lore raw

Martin Wilck <[email protected]> on Thu, 2020/05/07 23:18:

Quoted 9 lines · Christian Hesse
Quoted 5 lines

From: Christian Hesse <[email protected]>

Without this the build fails with:

/usr/bin/ld: cannot find -lmultipath

Thank you. Strange, I've built multipath thousands of times and never hit this error.

Did you build with lots of parallel jobs? I think my build server does something like make -j48. :-p

Signature · 3 lines
main(a){char*c=/*    Schoene Gruesse                         */"B?IJj;MEH"
"CX:;",b;for(a/*    Best regards             my address:    */=0;b=c[a++];)
putchar(b-1/(/*    Chris            cc -ox -xc - && ./x    */b/42*2-3)*42);}