Skip to content

Building issue under windows. #3140

Closed

Description

@GBillotey

Since PR #3067 I am unable to build from source (under windows).

This PR added a get_extension method to class FreeType in setupext.py.
A easy workaround is to explicitly return the default None under windows platform, but this seems a bit dirty.

def get_extension(self):
    ext = make_extension('freetype2', [])
    self.add_flags(ext)
    if sys.platform == 'win32':
        return None
    else:
        return ext

I would be happy to submit a PR for this but I would like first to take the advice of a setup.py / windows expert...

Activity

  1. pelson commented on Jun 18, 2014

    @pelson
    Member

    Thanks @GBillotey.

    @cgohlke - just wondering if you have any thoughts on this?

  2. cgohlke commented on Jun 18, 2014

    @cgohlke
    Contributor

    I can confirm the build issue and that the fix works with msvc. It looks to me that building a dummy C extension without source files is "undefined" and could also break with other compilers/linkers (?).

    diff --git a/setupext.py b/setupext.py
    index 868516d..7a8f285 100755
    --- a/setupext.py
    +++ b/setupext.py
    @@ -918,6 +918,8 @@ class FreeType(SetupPackage):
                 alt_exec='freetype-config')
    
         def get_extension(self):
    +        if sys.platform == 'win32':
    +            return None
             ext = make_extension('freetype2', [])
             self.add_flags(ext)
             return ext
  3. pelson commented on Jun 25, 2014

    @pelson
    Member

    @GBillotey - over to you if you're happy to submit a PR?

  4. GBillotey commented on Jun 25, 2014

    @GBillotey
    ContributorAuthor

    Unfortunately due to a recent "flooding" issue with my home computer, I
    will be unable to submit it in the next few weeks.
    Please, feel free to go on and merge the proposed patch if you wish.

    2014-06-25 16:48 GMT+02:00 Phil Elson notifications@github.com:

    @GBillotey https://github.com/GBillotey - over to you if you're happy
    to submit a PR?

    —
    Reply to this email directly or view it on GitHub
    #3140 (comment)
    .

  5. added this to the v1.4.0 milestone on Jun 25, 2014
  6. added a commit that references this issue on Jun 27, 2014
    4f08f74
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Release criticalFor bugs that make the library unusable (segfaults, incorrect plots, etc) and major regressions.

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions