diff options
author | Dominik Riebeling <Dominik.Riebeling@gmail.com> | 2013-05-09 17:23:42 +0200 |
---|---|---|
committer | Dominik Riebeling <Dominik.Riebeling@gmail.com> | 2013-05-09 17:23:42 +0200 |
commit | f7d8b2db9393004df796b4b7d9a8f66f547c6bef (patch) | |
tree | 9240705c4548cc4f582c332cdf423c6da826f6f9 | |
parent | 9e9f692678b5aefa68923a5b3301a4bd2ab5d03f (diff) | |
download | rockbox-f7d8b2db9393004df796b4b7d9a8f66f547c6bef.tar.gz rockbox-f7d8b2db9393004df796b4b7d9a8f66f547c6bef.zip |
Only pass AR to extralibs Makefile if the compiler is gcc.
We need this only for cross compiling. Trying to figure the compiler prefix
fails if the compiler isn't gcc (i.e. clang), and we only support gcc when
cross compiling.
Change-Id: I822e1b47ec7e9d7e9fdeae8ccf3b8d417a472ef9
-rw-r--r-- | rbutil/rbutilqt/rbutilqt.pro | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/rbutil/rbutilqt/rbutilqt.pro b/rbutil/rbutilqt/rbutilqt.pro index 4c16ac44cd..9eaf4568c2 100644 --- a/rbutil/rbutilqt/rbutilqt.pro +++ b/rbutil/rbutilqt/rbutilqt.pro | |||
@@ -70,7 +70,9 @@ message("Rockbox Base dir: "$$RBBASE_DIR) | |||
70 | # the ar that matches the current gcc. Since qmake doesn't provide a variable | 70 | # the ar that matches the current gcc. Since qmake doesn't provide a variable |
71 | # holding the correct ar without any additions we need to figure it ourselves | 71 | # holding the correct ar without any additions we need to figure it ourselves |
72 | # here. This assumes that QMAKE_CC will always be "gcc", maybe with a postfix. | 72 | # here. This assumes that QMAKE_CC will always be "gcc", maybe with a postfix. |
73 | MYAR = $$replace(QMAKE_CC,gcc.*,ar) | 73 | contains(QMAKE_CC, gcc) { |
74 | EXTRALIBS_MYAR = "EXTRALIBS_AR="$$replace(QMAKE_CC,gcc.*,ar) | ||
75 | } | ||
74 | 76 | ||
75 | extralibs.commands = $$SILENT \ | 77 | extralibs.commands = $$SILENT \ |
76 | $(MAKE) -f $$RBBASE_DIR/rbutil/rbutilqt/Makefile.libs \ | 78 | $(MAKE) -f $$RBBASE_DIR/rbutil/rbutilqt/Makefile.libs \ |
@@ -81,7 +83,7 @@ extralibs.commands = $$SILENT \ | |||
81 | RBBASE_DIR=$$RBBASE_DIR \ | 83 | RBBASE_DIR=$$RBBASE_DIR \ |
82 | EXTRALIBS_CC=\"$$QMAKE_CC\" \ | 84 | EXTRALIBS_CC=\"$$QMAKE_CC\" \ |
83 | EXTRALIB_CFLAGS=\"$$MACHINEFLAGS\" \ | 85 | EXTRALIB_CFLAGS=\"$$MACHINEFLAGS\" \ |
84 | EXTRALIBS_AR=\"$$MYAR\" \ | 86 | $$EXTRALIBS_MYAR \ |
85 | libs | 87 | libs |
86 | # Note: order is important for RBLIBS! The libs are appended to the linker | 88 | # Note: order is important for RBLIBS! The libs are appended to the linker |
87 | # flags in this order, put libucl at the end. | 89 | # flags in this order, put libucl at the end. |