Bug 143509
Summary: | can't build rpm using rpmbuild -bb --target i386 | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux 3 | Reporter: | Alexander Suvorov <say> |
Component: | gcc3 | Assignee: | Jakub Jelinek <jakub> |
Status: | CLOSED NOTABUG | QA Contact: | |
Severity: | medium | Docs Contact: | |
Priority: | medium | ||
Version: | 3.0 | CC: | riel |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2004-12-23 08:33:15 UTC | Type: | --- |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Alexander Suvorov
2004-12-21 19:37:43 UTC
Oh, sorry, I forgot to show my versions of gcc and rpm: gcc-3.3.2-1 rpm-4.2.1-0.30 The correct target to use is i686, as follows: rpmbuild -bp --target i686 kernel-2.4.spec Ok, I tried to build kernel with target i686: rpmbuild -bb --target i686 kernel-2.4.spec And I'v got: i2c-algo-bit.c: In function `sclhi': i2c-algo-bit.c:120: warning: comparison of distinct pointer types lacks a cast i2c-ali1535.c:675:6: missing terminating " character i2c-ali1535.c:676:89: missing terminating " character i2c-ali1535.c:691:1: unterminated argument list invoking macro "MODULE_AUTHOR" i2c-ali1535.c:674: error: syntax error at end of input make[2]: *** [i2c-ali1535.o] Error 1 make[1]: *** [_modsubdir_i2c] Error 2 make: *** [_mod_drivers] Error 2 The problem must be in different version of gcc, but AFAIR multi-line strings without terminating each line by \" is not a standard definition for C. As you see, the mistake in i2c-ali1535.c is the same as in wvlan_cs.c. Reopening and reassigning to "gcc3" component. Multi-line string literals, which have been a GNU extension, were deprecated in GCC 3.0, 3.1 and 3.2 and finally the support for them was removed in GCC 3.3, see http://gcc.gnu.org/gcc-3.3/changes.html Red Hat kernel-2.4.x packages don't have the needed changes to stop using multi-line string literals, only kernel-2.6.xx packages do. So, either use gcc-3.2.3-RH to build kernel-2.4.xx, or build 2.6 kernel, or patch kernel yourself. Try to compile some test i.e. a.c --- printf("test another line"); --- with given parameters: -Wall -W -ansi -pedantic GCC tells --- a.c:1: warning: ANSI C forbids newline in string constant --- What do you think about writing simple script that could fix such kind of errors of syntax in the whole kernel sources? I suspect all these errors have been fixed already in the 2.6 kernel. |