Skip to contentSkip to conversation

makedumpfile: fix Makefile for eppic_makedumpfile.so build

PATCH In review WANG Chao 2 participants 2 messages Jun 9, 2014 – Jun 10, 2014

Subsystems (3)
lore
Share & tools
lore

WANG Chao

author
#0 lore raw

PATCH 1/1 makedumpfile: fix Makefile for eppic_makedumpfile.so build

When libeppic isn't installed on a standard location, building eppic_makedumpfile.so with -leppic directly doesn't work.

Add LDFLAGS to build arguments, so that one can pass LDFLAGS="-Ldir -Idir" to tell where to search for libeppic library and its header files.

For example, if eppic source is installed on the same directory level with makedumpfile as the following:

makedumpfile

├── arch
└── eppic_scripts
eppic
├── applications
└── libeppic

After compiling libeppic, one can use the following command to build eppic_makedumpfile.so:

make LDFLAGS="-I../eppic/libeppic -L../eppic/libeppic" eppic_makedumpfile.so

---
 Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Makefile +1 -1
index d87638b..0cc07ef 100644
@@ -87,7 +87,7 @@ makedumpfile: $(SRC_BASE) $(OBJ_PART) $(OBJ_ARCH)
 	gzip -c ./makedumpfile.conf.5 > ./makedumpfile.conf.5.gz
 
 eppic_makedumpfile.so: extension_eppic.c
-	$(CC) $(CFLAGS) -shared -rdynamic -o $@ extension_eppic.c -fPIC -leppic -ltinfo
+	$(CC) $(CFLAGS) $(LDFLAGS) -shared -rdynamic -o $@ extension_eppic.c -fPIC -leppic -ltinfo
 
 clean:
 	rm -f $(OBJ) $(OBJ_PART) $(OBJ_ARCH) makedumpfile makedumpfile.8.gz makedumpfile.conf.5.gz
Signature · 7 lines
1.9.3


_______________________________________________
kexec mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/kexec
#1 lore raw

Hello WANG,

Thanks for your work, I'll merge this into v1.5.7, but...

Quoted 10 lines

When libeppic isn't installed on a standard location, building eppic_makedumpfile.so with -leppic directly doesn't work.

Add LDFLAGS to build arguments, so that one can pass LDFLAGS="-Ldir -Idir" to tell where to search for libeppic library and its header files.

For example, if eppic source is installed on the same directory level with makedumpfile as the following:

Quoted 6 lines

makedumpfile

├── arch
└── eppic_scripts
eppic
├── applications
└── libeppic

I'll replace these multibyte characters :-(

Thanks
Atsushi Kumagai

Quoted 23 lines

After compiling libeppic, one can use the following command to build eppic_makedumpfile.so:

make LDFLAGS="-I../eppic/libeppic -L../eppic/libeppic" eppic_makedumpfile.so

---
Makefile | 2 +-

1 file changed, 1 insertion(+), 1 deletion(-)
Makefile +0 -0
index d87638b..0cc07ef 100644
@@ -87,7 +87,7 @@ makedumpfile: $(SRC_BASE) $(OBJ_PART) $(OBJ_ARCH)
 	gzip -c ./makedumpfile.conf.5 > ./makedumpfile.conf.5.gz
 

eppic_makedumpfile.so: extension_eppic.c

Makefile +1 -1
-	$(CC) $(CFLAGS) -shared -rdynamic -o $@ extension_eppic.c -fPIC -leppic -ltinfo
+	$(CC) $(CFLAGS) $(LDFLAGS) -shared -rdynamic -o $@ extension_eppic.c -fPIC -leppic -ltinfo

clean:

	rm -f $(OBJ) $(OBJ_PART) $(OBJ_ARCH) makedumpfile makedumpfile.8.gz makedumpfile.conf.5.gz
Quoted 8 lines

--
1.9.3

_______________________________________________
kexec mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/kexec

_______________________________________________
kexec mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/kexec