Changes between Initial Version and Version 2 of Ticket #19899


Ignore:
Timestamp:
01/15/16 18:50:23 (7 years ago)
Author:
jdemeyer
Comment:

New commits:

0375847Use -Wno-unused flag for Python

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #19899

    • Property Status changed from new to needs_review
    • Property Commit changed from to 0375847bf1688af6f59e83a0dcb8992a82413c80
    • Property Branch changed from to u/jdemeyer/ticket/19899
  • Ticket #19899 – Description

    initial v2  
    1 Currently, the Sage is compiled with `-w` which suppresses all warnings. I don't think that is a good idea because there might be useful warnings.
     1One kind of warning which appears a lot in Cython-generated code is unused functions or variables. Such warnings also appear in external Cython packages which use Sage. Therefore, this ticket proposes to compile Python with `-Wno-unused` which is then passes down to all Python packages.
    22
    3 One kind of warning which appears a lot is unused functions or variables because of the way that Cython generates code. Such warnings also appear in external Cython packages which use Sage. Therefore, we simply compile Python with `-Wno-unused` which is then passes down to all Python packages.
     3Currently, the Sage library is compiled with `-w` which suppresses all warnings. I don't think that is a good idea because we might miss useful warnings. This ticket doesn't change that, but it will help to cut down the number of harmless "unused" warnings if we do change that.
    44
    55I noticed something else strange: Python puts `CFLAGS` ''before'' its own flags like `-O3`. But there is also a variable `EXTRA_CFLAGS` which is put after Python's flags. Since we usually want user flags to override the package flags, we put the user's `CFLAGS` into `EXTRA_CFLAGS`.