0d108116bd80b757fb01a84a9f1946ef870b57b8 is the first bad commit commit 0d108116bd80b757fb01a84a9f1946ef870b57b8 Author: Matt Turner <mattst88@gmail.com> Date: Thu Jan 17 23:51:04 2013 -0800 glsl/build: Build libglcpp and libglslcore in builtin_compiler And reuse them if not cross compiling. Tested-by: Andreas Boll <andreas.boll.dev@gmail.com> The error is as follow: Making all in osmesa make[5]: Entering directory `/home/dema1701/projects/display/mesa/src/mesa/drivers/osmesa' CXXLD libOSMesa.la /usr/bin/ld: i386:x86-64 architecture of input file `../../../../src/mesa/.libs/libmesa.a(ast_expr.o)' is incompatible with i386 output /usr/bin/ld: i386:x86-64 architecture of input file `../../../../src/mesa/.libs/libmesa.a(ast_function.o)' is incompatible with i386 output /usr/bin/ld: i386:x86-64 architecture of input file `../../../../src/mesa/.libs/libmesa.a(ast_to_hir.o)' is incompatible with i386 output /usr/bin/ld: i386:x86-64 architecture of input file `../../../../src/mesa/.libs/libmesa.a(ast_type.o)' is incompatible with i386 output I'm crosscompiling, building 32bit mesa on 64bit.
Now that all of the build system is converted to automake, we can do real cross compile builds: CFLAGS="-m32" CXXFLAGS="-m32" ./configure --build=x86_64-pc-linux-gnu --host=i686-pc-linux-gnu This works for me and builds a 32-bit OSMesa. Let me know if it does for you.
(In reply to comment #1) > Now that all of the build system is converted to automake, we can do real > cross compile builds: > > CFLAGS="-m32" CXXFLAGS="-m32" ./configure --build=x86_64-pc-linux-gnu > --host=i686-pc-linux-gnu > > This works for me and builds a 32-bit OSMesa. Let me know if it does for you. I'll try with the --build and --host options, however it was not needed before. Also, I'm wondering why they should be set if we have --enable-32-bit and --enable-64-bit options we can push at autogen.sh. These two options should take care of it. Otherwise, they are useless and they should be removed.
(In reply to comment #2) > I'll try with the --build and --host options, however it was not needed > before. Also, I'm wondering why they should be set if we have > --enable-32-bit and --enable-64-bit options we can push at autogen.sh. --build and --host is how autotools cross compiles. > These > two options should take care of it. Otherwise, they are useless and they > should be removed. They haven't worked in years, so.. :)
(In reply to comment #3) > (In reply to comment #2) > > I'll try with the --build and --host options, however it was not needed > > before. Also, I'm wondering why they should be set if we have > > --enable-32-bit and --enable-64-bit options we can push at autogen.sh. > > --build and --host is how autotools cross compiles. > > > These > > two options should take care of it. Otherwise, they are useless and they > > should be removed. > > They haven't worked in years, so.. :) Good news, it works with the options. I've been able to remove other variables I had to set to make it work before. I still need to set LLVM_CONFIG though. In the past, I was able to use --enable-XX-bit without any magic until about a year ago. Then, I added CFLAGS and CXXFLAGS with some paths for libraries. But if you tell me the options are broken and won't be fixed, I'm in favor of getting --enable-XX-bit out and documenting how to use the --build and --host options. I think this bug can be closed, but devs should take position about getting rid of the --enable-XX-bit options.
Patch sent.
(In reply to comment #5) > Patch sent. ... Anyone able to test the patch?
(In reply to comment #6) > (In reply to comment #5) > > Patch sent. > > ... Anyone able to test the patch? Yes I can. What should be tested exactly?
(In reply to comment #7) > (In reply to comment #6) > > (In reply to comment #5) > > > Patch sent. > > > > ... Anyone able to test the patch? > > Yes I can. What should be tested exactly? Testing that 32-bit builds work on 64-bit systems.
(In reply to comment #8) > (In reply to comment #7) > > (In reply to comment #6) > > > (In reply to comment #5) > > > > Patch sent. > > > > > > ... Anyone able to test the patch? > > > > Yes I can. What should be tested exactly? > > Testing that 32-bit builds work on 64-bit systems. I should have been more precise: Do you mean I should test it without any CFLAGS="-m32", CXXFLAGS="-m32", --build=x86_64-pc-linux-gnu and --host=i686-pc-linux-gnu flags?
(In reply to comment #9) > (In reply to comment #8) > > (In reply to comment #7) > > > (In reply to comment #6) > > > > (In reply to comment #5) > > > > > Patch sent. > > > > > > > > ... Anyone able to test the patch? > > > > > > Yes I can. What should be tested exactly? > > > > Testing that 32-bit builds work on 64-bit systems. > > I should have been more precise: Do you mean I should test it without any > CFLAGS="-m32", CXXFLAGS="-m32", --build=x86_64-pc-linux-gnu and > --host=i686-pc-linux-gnu flags? Oh, I see, sorry. Try to build the way that you were when you encountered this problem, CFLAGS="-m32" CXXFLAGS="-m32" ./configure --enable-32-bit
(In reply to comment #10) > (In reply to comment #9) > > (In reply to comment #8) > > > (In reply to comment #7) > > > > (In reply to comment #6) > > > > > (In reply to comment #5) > > > > > > Patch sent. > > > > > > > > > > ... Anyone able to test the patch? > > > > > > > > Yes I can. What should be tested exactly? > > > > > > Testing that 32-bit builds work on 64-bit systems. > > > > I should have been more precise: Do you mean I should test it without any > > CFLAGS="-m32", CXXFLAGS="-m32", --build=x86_64-pc-linux-gnu and > > --host=i686-pc-linux-gnu flags? > > Oh, I see, sorry. > > Try to build the way that you were when you encountered this problem, > > CFLAGS="-m32" CXXFLAGS="-m32" ./configure --enable-32-bit When going back to my previous command (the used when I reported this bug), it now works with your patch.
Committed.
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.