[MacPorts] #60819: sfml fails to build due to missing method backingScaleFactor

MacPorts noreply at macports.org
Sat Jul 11 23:12:52 UTC 2020


#60819: sfml fails to build due to missing method backingScaleFactor
------------------------------+--------------------
  Reporter:  programmingkidx  |      Owner:  (none)
      Type:  defect           |     Status:  new
  Priority:  Normal           |  Milestone:
 Component:  ports            |    Version:
Resolution:                   |   Keywords:
      Port:  sfml             |
------------------------------+--------------------

Comment (by kencu):

 Now you're running into some slightly harder stuff.

 This is caused by advancements to the Apple SDKs over time. You have to
 either:

 1. build against a newer SDK (like the 10.7 SDK) and see if it works. It
 does sometimes. Sometimes, it does not, if the software wasn't written
 with that possibility in mind. See the libsdl2 Portfile for an example of
 this that works, and how it was done.
 2. rewrite the software to the SDK you are trying to build against, in
 this case the 10.6 SDK. Sometimes is pretty easy, a few {{{#ifdefs}}} or
 some {{{#if __MAC_OS_X_VERSION_MAX_ALLOWED__}}} guards can get you there.

 This particular error is pretty easy to fix, as the change from the 10.6
 SDK is pretty minor and simple to implement. If you go into the macports
 portfile tree and do a search for that, something like :
 {{{
 cd `port dir sfml`../../
 }}}

 and then use your favourite searcher, I like {{{the_silver_searcher}}}
 {{{
 ag backingScaleFactor .
 }}}
 you might get lucky and find another port that has already patched this,
 and see what they did.

 Or you can type "backingScaleFactor" into the "Search" box at the top
 right of this screen we're on here, and that will search for other tickets
 where this was handled.

 Or "Google is your Friend" and sometimes there is a hit or two on the web
 for this.

 Sometimes I download the last version of the software that did build on
 10.6, and compare the source code to see what changed between the version
 that built on 10.6 and the version that did not build. That can give you
 some clues (I got wine working on 10.6.8 that way recently).

 But -- never a trivial fix, nobody is likely to help you other than a very
 few of us, and it will not be fixed particularly quickly.

 There is a user trying to automate some of these SDK evolution things, and
 that might (or might not) work -- we'll see.

-- 
Ticket URL: <https://trac.macports.org/ticket/60819#comment:2>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list