public inbox for ecos-patches@sourceware.org
 help / color / mirror / Atom feed
* [Bug 1001083] New: Fix warnings on creating target.ld for i386 targets
@ 2010-11-27 18:33 bugzilla-daemon
  2011-01-01 11:43 ` [Bug 1001083] " bugzilla-daemon
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: bugzilla-daemon @ 2010-11-27 18:33 UTC (permalink / raw)
  To: ecos-patches

Please do not reply to this email. Use the web interface provided at:
http://bugs.ecos.sourceware.org/show_bug.cgi?id=1001083

           Summary: Fix warnings on creating target.ld for i386 targets
           Product: eCos
           Version: CVS
          Platform: pc (i386 PC target)
        OS/Version: IA32
            Status: NEW
          Severity: minor
          Priority: low
         Component: Patches and contributions
        AssignedTo: unassigned@bugs.ecos.sourceware.org
        ReportedBy: sergei.gavrikov@gmail.com
                CC: ecos-patches@ecos.sourceware.org
             Class: Advice Request


Created an attachment (id=1030)
 --> (http://bugs.ecos.sourceware.org/attachment.cgi?id=1030)
hal_i386.cdl patch

As a make rule for 'target.ld' (hal_i386.cdl) makes compiler to compile *C*
sources ('-xc' is used in the rule), we get the 2 warnings on creating
target.ld:

% ecosconfig new pc
% ecosconfig tree
% make -s
cc1: warning: command line option "-Woverloaded-virtual" is valid for
C++/ObjC++ but not for C
cc1: warning: command line option "-fno-rtti" is valid for C++/ObjC++ but not
for C

For example, CFLAGS for i386 pc target are

-finline-limit=7000 -Wall -Wpointer-arith -Wstrict-prototypes -Wundef
-Woverloaded-virtual -Wno-write-strings -g -O2 -ffunction-sections
-fdata-sections -fno-rtti -fno-exceptions

It's more reasonable to use $(ACTUAL_CFLAGS) in the rule, which are

-finline-limit=7000 -Wall -Wpointer-arith -Wstrict-prototypes -Wundef
-Wno-write-strings -g -O2 -ffunction-sections -fdata-sections -fno-exceptions

A patch is attached.

Note: Perhaps the same cleanups are needed for other hal/*/arch CDLs.

-- 
Configure bugmail: http://bugs.ecos.sourceware.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug 1001083] Fix warnings on creating target.ld for i386 targets
  2010-11-27 18:33 [Bug 1001083] New: Fix warnings on creating target.ld for i386 targets bugzilla-daemon
@ 2011-01-01 11:43 ` bugzilla-daemon
  2011-01-01 12:38 ` bugzilla-daemon
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: bugzilla-daemon @ 2011-01-01 11:43 UTC (permalink / raw)
  To: ecos-patches

Please do not reply to this email. Use the web interface provided at:
http://bugs.ecos.sourceware.org/show_bug.cgi?id=1001083

John Dallaway <john@dallaway.org.uk> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |john@dallaway.org.uk

--- Comment #1 from John Dallaway <john@dallaway.org.uk> 2011-01-01 11:43:12 GMT ---
Sergei, your proposed change looks good to me. It matches the use of
ACTUAL_CFLAGS in some other architectural HALs (arm, m68k, etc).

-- 
Configure bugmail: http://bugs.ecos.sourceware.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug 1001083] Fix warnings on creating target.ld for i386 targets
  2010-11-27 18:33 [Bug 1001083] New: Fix warnings on creating target.ld for i386 targets bugzilla-daemon
  2011-01-01 11:43 ` [Bug 1001083] " bugzilla-daemon
@ 2011-01-01 12:38 ` bugzilla-daemon
  2011-01-01 19:18 ` bugzilla-daemon
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: bugzilla-daemon @ 2011-01-01 12:38 UTC (permalink / raw)
  To: ecos-patches

Please do not reply to this email. Use the web interface provided at:
http://bugs.ecos.sourceware.org/show_bug.cgi?id=1001083

Ilija Kocho <ilijak@siva.com.mk> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ilijak@siva.com.mk

--- Comment #2 from Ilija Kocho <ilijak@siva.com.mk> 2011-01-01 12:38:34 GMT ---
(In reply to comment #0)
> 
> Note: Perhaps the same cleanups are needed for other hal/*/arch CDLs.

Cortex-M has the same problem.

BTW, comparing CDLs of Cortex-M (as well as i386) with arch HALs pointed by
John I noticed that same difference for the flags exists in make command for
vectors.S (although i see no warning). Should this be fixed too?

-- 
Configure bugmail: http://bugs.ecos.sourceware.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug 1001083] Fix warnings on creating target.ld for i386 targets
  2010-11-27 18:33 [Bug 1001083] New: Fix warnings on creating target.ld for i386 targets bugzilla-daemon
  2011-01-01 11:43 ` [Bug 1001083] " bugzilla-daemon
  2011-01-01 12:38 ` bugzilla-daemon
@ 2011-01-01 19:18 ` bugzilla-daemon
  2011-01-01 19:35 ` bugzilla-daemon
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: bugzilla-daemon @ 2011-01-01 19:18 UTC (permalink / raw)
  To: ecos-patches

Please do not reply to this email. Use the web interface provided at:
http://bugs.ecos.sourceware.org/show_bug.cgi?id=1001083

--- Comment #3 from Sergei Gavrikov <sergei.gavrikov@gmail.com> 2011-01-01 19:18:10 GMT ---
(In reply to comment #1)
> Sergei, your proposed change looks good to me. It matches the use of
> ACTUAL_CFLAGS in some other architectural HALs (arm, m68k, etc).

John, my check:

Have no issue:
$ grep target.ld -A3 hal/*/arch/current/cdl/hal_*cdl| grep
'$(ACTUAL_CFLAGS)'|cut -d- -f1
hal/arm/arch/current/cdl/hal_arm.cdl
hal/coldfire/arch/current/cdl/hal_coldfire.cdl
hal/m68k/arch/current/cdl/hal_m68k.cdl
hal/synth/arch/current/cdl/hal_synth.cdl

Expectant:
$ grep target.ld -A3 hal/*/arch/current/cdl/hal_*cdl| grep '$(CFLAGS)'|cut -d-
-f1
hal/cortexm/arch/current/cdl/hal_cortexm.cdl
hal/frv/arch/current/cdl/hal_frv.cdl
hal/i386/arch/current/cdl/hal_i386.cdl
hal/openrisc/arch/current/cdl/hal_openrisc.cdl
hal/powerpc/arch/current/cdl/hal_powerpc.cdl
hal/sh/arch/current/cdl/hal_sh.cdl
hal/sparc/arch/current/cdl/hal_sparc.cdl
hal/sparclite/arch/current/cdl/hal_sparclite.cdl

I was able to verify builds for next architectures: 'cortexm', 'powerpc' and
'sh' (I have no other toolchains).

Unfortunately, the compilers need substitution s/CFLAGS/ACTUAL_CFLAGS/ and in
other places for those archs, i.e. on preprocessing stages (where compilers
generate dependencies). There are more such places for 'powerpc' and 'sh'
(sh2, sh3, ...) archs. My workaround just decrements the compiler's claims
and does not calm builds there. Can I take risks and make all corrections
without the ability to test all?

It is safe for me is to apply the fix only for 'i386' and 'cortexm' archs.

-- 
Configure bugmail: http://bugs.ecos.sourceware.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug 1001083] Fix warnings on creating target.ld for i386 targets
  2010-11-27 18:33 [Bug 1001083] New: Fix warnings on creating target.ld for i386 targets bugzilla-daemon
                   ` (2 preceding siblings ...)
  2011-01-01 19:18 ` bugzilla-daemon
@ 2011-01-01 19:35 ` bugzilla-daemon
  2011-01-02  1:09 ` bugzilla-daemon
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: bugzilla-daemon @ 2011-01-01 19:35 UTC (permalink / raw)
  To: ecos-patches

Please do not reply to this email. Use the web interface provided at:
http://bugs.ecos.sourceware.org/show_bug.cgi?id=1001083

--- Comment #4 from Sergei Gavrikov <sergei.gavrikov@gmail.com> 2011-01-01 19:35:13 GMT ---
(In reply to comment #2)
> (In reply to comment #0)
> > 
> > Note: Perhaps the same cleanups are needed for other hal/*/arch CDLs.
> 
> Cortex-M has the same problem.
> 
> BTW, comparing CDLs of Cortex-M (as well as i386) with arch HALs pointed by
> John I noticed that same difference for the flags exists in make command for
> vectors.S (although i see no warning). Should this be fixed too?

Grep shows that some architecture config files use either CFLAGS or
ACTUAL_CFLAGS there, but that does not raise warnings in both cases.

-- 
Configure bugmail: http://bugs.ecos.sourceware.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug 1001083] Fix warnings on creating target.ld for i386 targets
  2010-11-27 18:33 [Bug 1001083] New: Fix warnings on creating target.ld for i386 targets bugzilla-daemon
                   ` (3 preceding siblings ...)
  2011-01-01 19:35 ` bugzilla-daemon
@ 2011-01-02  1:09 ` bugzilla-daemon
  2011-01-02 14:00 ` bugzilla-daemon
  2011-01-04 18:55 ` bugzilla-daemon
  6 siblings, 0 replies; 8+ messages in thread
From: bugzilla-daemon @ 2011-01-02  1:09 UTC (permalink / raw)
  To: ecos-patches

Please do not reply to this email. Use the web interface provided at:
http://bugs.ecos.sourceware.org/show_bug.cgi?id=1001083

Jonathan Larmour <jifl@ecoscentric.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jifl@ecoscentric.com

--- Comment #5 from Jonathan Larmour <jifl@ecoscentric.com> 2011-01-02 01:09:11 GMT ---
(In reply to comment #3)
> Unfortunately, the compilers need substitution s/CFLAGS/ACTUAL_CFLAGS/ and in
> other places for those archs, i.e. on preprocessing stages (where compilers
> generate dependencies). There are more such places for 'powerpc' and 'sh'
> (sh2, sh3, ...) archs. My workaround just decrements the compiler's claims
> and does not calm builds there. Can I take risks and make all corrections
> without the ability to test all?

It seems safe. The difference between CFLAGS and ACTUAL_CFLAGS does not vary
between architectures. So if it is possible, it would be nice, thanks.

Jifl

-- 
Configure bugmail: http://bugs.ecos.sourceware.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug 1001083] Fix warnings on creating target.ld for i386 targets
  2010-11-27 18:33 [Bug 1001083] New: Fix warnings on creating target.ld for i386 targets bugzilla-daemon
                   ` (4 preceding siblings ...)
  2011-01-02  1:09 ` bugzilla-daemon
@ 2011-01-02 14:00 ` bugzilla-daemon
  2011-01-04 18:55 ` bugzilla-daemon
  6 siblings, 0 replies; 8+ messages in thread
From: bugzilla-daemon @ 2011-01-02 14:00 UTC (permalink / raw)
  To: ecos-patches

Please do not reply to this email. Use the web interface provided at:
http://bugs.ecos.sourceware.org/show_bug.cgi?id=1001083

--- Comment #6 from Sergei Gavrikov <sergei.gavrikov@gmail.com> 2011-01-02 14:00:01 GMT ---
Made the same clean-ups for next architectures: corterxm, fvr, i386, openrisc,
powerpc, sh, sparc, and sparclite. Checked-in.

John, Jonathan: thanks for review.

-- 
Configure bugmail: http://bugs.ecos.sourceware.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug 1001083] Fix warnings on creating target.ld for i386 targets
  2010-11-27 18:33 [Bug 1001083] New: Fix warnings on creating target.ld for i386 targets bugzilla-daemon
                   ` (5 preceding siblings ...)
  2011-01-02 14:00 ` bugzilla-daemon
@ 2011-01-04 18:55 ` bugzilla-daemon
  6 siblings, 0 replies; 8+ messages in thread
From: bugzilla-daemon @ 2011-01-04 18:55 UTC (permalink / raw)
  To: ecos-patches

Please do not reply to this email. Use the web interface provided at:
http://bugs.ecos.sourceware.org/show_bug.cgi?id=1001083

Sergei Gavrikov <sergei.gavrikov@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |CURRENTRELEASE

--- Comment #7 from Sergei Gavrikov <sergei.gavrikov@gmail.com> 2011-01-04 18:55:00 GMT ---
Finalized.

-- 
Configure bugmail: http://bugs.ecos.sourceware.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2011-01-04 18:55 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-11-27 18:33 [Bug 1001083] New: Fix warnings on creating target.ld for i386 targets bugzilla-daemon
2011-01-01 11:43 ` [Bug 1001083] " bugzilla-daemon
2011-01-01 12:38 ` bugzilla-daemon
2011-01-01 19:18 ` bugzilla-daemon
2011-01-01 19:35 ` bugzilla-daemon
2011-01-02  1:09 ` bugzilla-daemon
2011-01-02 14:00 ` bugzilla-daemon
2011-01-04 18:55 ` bugzilla-daemon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).