diff options
author | Dominik Riebeling <Dominik.Riebeling@gmail.com> | 2010-03-11 19:14:33 +0000 |
---|---|---|
committer | Dominik Riebeling <Dominik.Riebeling@gmail.com> | 2010-03-11 19:14:33 +0000 |
commit | c8752b428dc11db98f2ccd16d2e4239dd731f992 (patch) | |
tree | 03df32689d9bbadf60c377bf8fbc7b1238e82e74 /rbutil/rbutilqt/rbutilqt.pro | |
parent | 405f6e6dbcfdd3f2b6923822106833b6270cdb52 (diff) | |
download | rockbox-c8752b428dc11db98f2ccd16d2e4239dd731f992.tar.gz rockbox-c8752b428dc11db98f2ccd16d2e4239dd731f992.zip |
Rearrange libraries linking order to work with --as-needed linker option.
If the linker uses the --as-needed option linking failed due to the order of
the libraries on the command line. Arch Linux seems to default to this option,
and the Gentoo documentation mentiones it as experimental feature. Changing
the library order fixes the link issue.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25124 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'rbutil/rbutilqt/rbutilqt.pro')
-rw-r--r-- | rbutil/rbutilqt/rbutilqt.pro | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/rbutil/rbutilqt/rbutilqt.pro b/rbutil/rbutilqt/rbutilqt.pro index fc62e77241..0b03907a94 100644 --- a/rbutil/rbutilqt/rbutilqt.pro +++ b/rbutil/rbutilqt/rbutilqt.pro | |||
@@ -29,14 +29,6 @@ RBBASE_DIR = $$replace(RBBASE_DIR,/rbutil/rbutilqt,) | |||
29 | 29 | ||
30 | message("Rockbox Base dir: "$$RBBASE_DIR) | 30 | message("Rockbox Base dir: "$$RBBASE_DIR) |
31 | 31 | ||
32 | # check for system speex. Add a custom rule for pre-building librbspeex if not | ||
33 | # found. Newer versions of speex are split up into libspeex and libspeexdsp, | ||
34 | # and some distributions package them separately. Check for both and fall back | ||
35 | # to librbspeex if not found. | ||
36 | LIBSPEEX = $$system(pkg-config --silence-errors --libs speex speexdsp) | ||
37 | !static:!isEmpty(LIBSPEEX) { | ||
38 | LIBS += $$LIBSPEEX | ||
39 | } | ||
40 | # custom rules for rockbox-specific libs | 32 | # custom rules for rockbox-specific libs |
41 | !mac { | 33 | !mac { |
42 | RBLIBPOSTFIX = .a | 34 | RBLIBPOSTFIX = .a |
@@ -187,6 +179,17 @@ DEPENDPATH = $$INCLUDEPATH | |||
187 | 179 | ||
188 | LIBS += -L$$OUT_PWD -L$$MYBUILDDIR -lrbspeex -lmkamsboot -lmktccboot -lucl | 180 | LIBS += -L$$OUT_PWD -L$$MYBUILDDIR -lrbspeex -lmkamsboot -lmktccboot -lucl |
189 | 181 | ||
182 | # check for system speex. Add a custom rule for pre-building librbspeex if not | ||
183 | # found. Newer versions of speex are split up into libspeex and libspeexdsp, | ||
184 | # and some distributions package them separately. Check for both and fall back | ||
185 | # to librbspeex if not found. | ||
186 | # NOTE: keep this after -lrbspeex, otherwise linker errors occur if the linker | ||
187 | # defaults to --as-needed (see http://www.gentoo.org/proj/en/qa/asneeded.xml) | ||
188 | LIBSPEEX = $$system(pkg-config --silence-errors --libs speex speexdsp) | ||
189 | !static:!isEmpty(LIBSPEEX) { | ||
190 | LIBS += $$LIBSPEEX | ||
191 | } | ||
192 | |||
190 | TEMPLATE = app | 193 | TEMPLATE = app |
191 | dbg { | 194 | dbg { |
192 | CONFIG += debug thread qt warn_on | 195 | CONFIG += debug thread qt warn_on |