Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Apache: Bugs

[Bug 51257] Build failed when cross-compiling: ./gen_test_char: cannot execute binary file

 

 

Apache bugs RSS feed   Index | Next | Previous | View Threaded


bugzilla at apache

Apr 18, 2012, 12:45 AM

Post #1 of 8 (366 views)
Permalink
[Bug 51257] Build failed when cross-compiling: ./gen_test_char: cannot execute binary file

https://issues.apache.org/bugzilla/show_bug.cgi?id=51257

--- Comment #2 from Henrik Strand <henrik.strand [at] axis> 2012-04-18 07:45:54 UTC ---
Created attachment 28632
--> https://issues.apache.org/bugzilla/attachment.cgi?id=28632
Simple patch for defining the C compiler command to be used for compilation of
programs that run on BUILD during cross-compiling, e.g. gen_test_char.

Verified on httpd_2.4.1

--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe [at] httpd
For additional commands, e-mail: bugs-help [at] httpd


bugzilla at apache

Apr 18, 2012, 12:48 AM

Post #2 of 8 (359 views)
Permalink
[Bug 51257] Build failed when cross-compiling: ./gen_test_char: cannot execute binary file [In reply to]

https://issues.apache.org/bugzilla/show_bug.cgi?id=51257

--- Comment #3 from Henrik Strand <henrik.strand [at] axis> 2012-04-18 07:48:55 UTC ---
Created attachment 28633
--> https://issues.apache.org/bugzilla/attachment.cgi?id=28633
Same patch as previous file but for httpd_trunk.

--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe [at] httpd
For additional commands, e-mail: bugs-help [at] httpd


bugzilla at apache

Apr 19, 2012, 5:03 AM

Post #3 of 8 (357 views)
Permalink
[Bug 51257] Build failed when cross-compiling: ./gen_test_char: cannot execute binary file [In reply to]

https://issues.apache.org/bugzilla/show_bug.cgi?id=51257

--- Comment #4 from Guenter Knauf <eflash [at] gmx> 2012-04-19 12:03:01 UTC ---
Hi Henrik,
(In reply to comment #3)
> Created attachment 28633 [details]
> Same patch as previous file but for httpd_trunk.
I've just commited a slightly modified patch to trunk:
http://svn.apache.org/viewvc?rev=1327907&view=rev
this should work same way as with your patch provided that you export
CC_FOR_BUILD=gcc. I hope that we can finally figure out how we can configure
teach to set CC_FOR_BUILD automatically in case of detecting cross-compilation
so that the export is then not needed. The CC_FOR_BUILD should appear in
build/config_vars.mk because then server/Makefile can access it.
For 2.2.x you will then need in addition:
--- srclib/pcre/Makefile.in.orig 2005-02-11 13:00:41.000000000 +0100
+++ srclib/pcre/Makefile.in 2012-04-19 13:29:06.000000000 +0200
@@ -11,8 +11,13 @@

$(LTLIBRARY_OBJECTS) dftables.lo: config.h

+ifdef CC_FOR_BUILD
+dftables: dftables.c
+ $(CC_FOR_BUILD) -o $@ $<
+else
dftables: dftables.lo
$(LINK) $(EXTRA_LDFLAGS) dftables.lo $(EXTRA_LIBS)
+endif

$(srcdir)/chartables.c: dftables
./dftables $@

--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe [at] httpd
For additional commands, e-mail: bugs-help [at] httpd


bugzilla at apache

Apr 20, 2012, 8:17 AM

Post #4 of 8 (352 views)
Permalink
[Bug 51257] Build failed when cross-compiling: ./gen_test_char: cannot execute binary file [In reply to]

https://issues.apache.org/bugzilla/show_bug.cgi?id=51257

--- Comment #5 from Guenter Knauf <eflash [at] gmx> 2012-04-20 15:17:06 UTC ---
I've just committed a follow-up patch:
http://svn.apache.org/viewvc?view=revision&revision=1328390
it is *required* that you re-run buildconf so that configure gets re-created!
After you've run configure with f.e.:
CC_FOR_BUILD=gcc ./configure --host=...
you can check ./build/config_vars.mk where CC_FOR_BUILD should appear now and
./server/Makefile should now see the var ...

--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe [at] httpd
For additional commands, e-mail: bugs-help [at] httpd


bugzilla at apache

Apr 21, 2012, 11:23 AM

Post #5 of 8 (383 views)
Permalink
[Bug 51257] Build failed when cross-compiling: ./gen_test_char: cannot execute binary file [In reply to]

https://issues.apache.org/bugzilla/show_bug.cgi?id=51257

--- Comment #6 from Guenter Knauf <eflash [at] gmx> 2012-04-21 18:23:14 UTC ---
Here's the summarize of all patches:
* cross-compile: allow to provide CC_FOR_BUILD so that gen_test_char will be
compiled by the build compiler instead of the host compiler.
Also set CC_FOR_BUILD to 'cc' when cross-compilation is detected.
Trunk patches: http://svn.apache.org/viewvc?view=revision&revision=1327907
http://svn.apache.org/viewvc?view=revision&revision=1328390
http://svn.apache.org/viewvc?view=revision&revision=1328714

Backport proposal added for 2.4.x patch:
http://people.apache.org/~fuankg/diffs/httpd-2.4.x-cross_compile.diff
Backport proposal added for 2.2.x patch:
http://people.apache.org/~fuankg/diffs/httpd-2.2.x-cross_compile.diff
Since PCRE is included with 2.2.x this patch also takes care for dftables.

please test both with and without providing CC_FOR_BUILD - if not set and
cross-compilation is detected then CC_FOR_BUILD defaults to 'cc'.

--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe [at] httpd
For additional commands, e-mail: bugs-help [at] httpd


bugzilla at apache

Apr 25, 2012, 5:07 AM

Post #6 of 8 (345 views)
Permalink
[Bug 51257] Build failed when cross-compiling: ./gen_test_char: cannot execute binary file [In reply to]

https://issues.apache.org/bugzilla/show_bug.cgi?id=51257

--- Comment #7 from Henrik Strand <henrik.strand [at] axis> 2012-04-25 12:07:35 UTC ---
Created attachment 28680
--> https://issues.apache.org/bugzilla/attachment.cgi?id=28680
Updated document patch.

--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe [at] httpd
For additional commands, e-mail: bugs-help [at] httpd


bugzilla at apache

Apr 25, 2012, 5:19 AM

Post #7 of 8 (344 views)
Permalink
[Bug 51257] Build failed when cross-compiling: ./gen_test_char: cannot execute binary file [In reply to]

https://issues.apache.org/bugzilla/show_bug.cgi?id=51257

--- Comment #8 from Henrik Strand <henrik.strand [at] axis> 2012-04-25 12:19:24 UTC ---
Created attachment 28681
--> https://issues.apache.org/bugzilla/attachment.cgi?id=28681
Updated document patch.

--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe [at] httpd
For additional commands, e-mail: bugs-help [at] httpd


bugzilla at apache

Apr 25, 2012, 5:20 AM

Post #8 of 8 (345 views)
Permalink
[Bug 51257] Build failed when cross-compiling: ./gen_test_char: cannot execute binary file [In reply to]

https://issues.apache.org/bugzilla/show_bug.cgi?id=51257

--- Comment #9 from Henrik Strand <henrik.strand [at] axis> 2012-04-25 12:20:26 UTC ---
Created attachment 28682
--> https://issues.apache.org/bugzilla/attachment.cgi?id=28682
Updated document patch.

--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe [at] httpd
For additional commands, e-mail: bugs-help [at] httpd

Apache bugs RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.