* [PATCH] btrfs-progs: remove hard-coding of "gcc" and "make" from Makefile
@ 2009-09-21 16:18 Joe Peterson
2009-09-21 18:25 ` Premysl Hruby
0 siblings, 1 reply; 2+ messages in thread
From: Joe Peterson @ 2009-09-21 16:18 UTC (permalink / raw)
To: Btrfs Development List
[-- Attachment #1: Type: text/plain, Size: 222 bytes --]
Here's a simple patch to replace "gcc" with "$(CC)" and "make" with
"$(MAKE)". This is required, for example, for Gentoo Linux ebuilds, and
it also eliminates a "jobserver unavailable" warning (make-related).
-Joe
[-- Attachment #2: btrfs-progs_use_env_gcc_make.patch --]
[-- Type: text/plain, Size: 2524 bytes --]
diff -Nurp a/Makefile b/Makefile
--- a/Makefile 2009-09-21 09:43:46.672275731 -0600
+++ b/Makefile 2009-09-21 09:44:33.221156240 -0600
@@ -36,47 +36,47 @@ version:
bash version.sh
btrfsctl: $(objects) btrfsctl.o
- gcc $(CFLAGS) -o btrfsctl btrfsctl.o $(objects) $(LDFLAGS) $(LIBS)
+ $(CC) $(CFLAGS) -o btrfsctl btrfsctl.o $(objects) $(LDFLAGS) $(LIBS)
btrfs-vol: $(objects) btrfs-vol.o
- gcc $(CFLAGS) -o btrfs-vol btrfs-vol.o $(objects) $(LDFLAGS) $(LIBS)
+ $(CC) $(CFLAGS) -o btrfs-vol btrfs-vol.o $(objects) $(LDFLAGS) $(LIBS)
btrfs-show: $(objects) btrfs-show.o
- gcc $(CFLAGS) -o btrfs-show btrfs-show.o $(objects) $(LDFLAGS) $(LIBS)
+ $(CC) $(CFLAGS) -o btrfs-show btrfs-show.o $(objects) $(LDFLAGS) $(LIBS)
btrfsck: $(objects) btrfsck.o
- gcc $(CFLAGS) -o btrfsck btrfsck.o $(objects) $(LDFLAGS) $(LIBS)
+ $(CC) $(CFLAGS) -o btrfsck btrfsck.o $(objects) $(LDFLAGS) $(LIBS)
mkfs.btrfs: $(objects) mkfs.o
- gcc $(CFLAGS) -o mkfs.btrfs $(objects) mkfs.o $(LDFLAGS) $(LIBS)
+ $(CC) $(CFLAGS) -o mkfs.btrfs $(objects) mkfs.o $(LDFLAGS) $(LIBS)
btrfs-debug-tree: $(objects) debug-tree.o
- gcc $(CFLAGS) -o btrfs-debug-tree $(objects) debug-tree.o $(LDFLAGS) $(LIBS)
+ $(CC) $(CFLAGS) -o btrfs-debug-tree $(objects) debug-tree.o $(LDFLAGS) $(LIBS)
btrfstune: $(objects) btrfstune.o
- gcc $(CFLAGS) -o btrfstune $(objects) btrfstune.o $(LDFLAGS) $(LIBS)
+ $(CC) $(CFLAGS) -o btrfstune $(objects) btrfstune.o $(LDFLAGS) $(LIBS)
btrfs-image: $(objects) btrfs-image.o
- gcc $(CFLAGS) -o btrfs-image $(objects) btrfs-image.o -lpthread -lz $(LDFLAGS) $(LIBS)
+ $(CC) $(CFLAGS) -o btrfs-image $(objects) btrfs-image.o -lpthread -lz $(LDFLAGS) $(LIBS)
dir-test: $(objects) dir-test.o
- gcc $(CFLAGS) -o dir-test $(objects) dir-test.o $(LDFLAGS) $(LIBS)
+ $(CC) $(CFLAGS) -o dir-test $(objects) dir-test.o $(LDFLAGS) $(LIBS)
quick-test: $(objects) quick-test.o
- gcc $(CFLAGS) -o quick-test $(objects) quick-test.o $(LDFLAGS) $(LIBS)
+ $(CC) $(CFLAGS) -o quick-test $(objects) quick-test.o $(LDFLAGS) $(LIBS)
convert: $(objects) convert.o
- gcc $(CFLAGS) -o btrfs-convert $(objects) convert.o -lext2fs $(LDFLAGS) $(LIBS)
+ $(CC) $(CFLAGS) -o btrfs-convert $(objects) convert.o -lext2fs $(LDFLAGS) $(LIBS)
manpages:
- cd man; make
+ cd man; $(MAKE)
install-man:
- cd man; make install
+ cd man; $(MAKE) install
clean :
rm -f $(progs) cscope.out *.o .*.d btrfs-convert
- cd man; make clean
+ cd man; $(MAKE) clean
install: $(progs) install-man
$(INSTALL) -m755 -d $(DESTDIR)$(bindir)
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] btrfs-progs: remove hard-coding of "gcc" and "make" from Makefile
2009-09-21 16:18 [PATCH] btrfs-progs: remove hard-coding of "gcc" and "make" from Makefile Joe Peterson
@ 2009-09-21 18:25 ` Premysl Hruby
0 siblings, 0 replies; 2+ messages in thread
From: Premysl Hruby @ 2009-09-21 18:25 UTC (permalink / raw)
To: linux-btrfs
Hi
On (21/09/09 10:18), Joe Peterson wrote:
> Date: Mon, 21 Sep 2009 10:18:53 -0600
> From: Joe Peterson <joe@skyrush.com>
> To: Btrfs Development List <linux-btrfs@vger.kernel.org>
> Subject: [PATCH] btrfs-progs: remove hard-coding of "gcc" and "make" from
> Makefile
> User-Agent: Thunderbird 2.0.0.23 (X11/20090920)
> List-ID: <linux-btrfs.vger.kernel.org>
BTW:
>
> manpages:
> - cd man; make
> + cd man; $(MAKE)
=> $(MAKE) -C man
>
> install-man:
> - cd man; make install
> + cd man; $(MAKE) install
=> $(MAKE) -C man install
>
> clean :
> rm -f $(progs) cscope.out *.o .*.d btrfs-convert
> - cd man; make clean
> + cd man; $(MAKE) clean
=> $(MAKE) clean
--
Premysl "Anydot" Hruby, http://www.redrum.cz/
-
I'm a signature virus. Please add me to your signature and help me spread!
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-09-21 18:25 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-09-21 16:18 [PATCH] btrfs-progs: remove hard-coding of "gcc" and "make" from Makefile Joe Peterson
2009-09-21 18:25 ` Premysl Hruby
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.