[MacPorts] #54948: optipng 0.7.6: error: no member named 'st_atim' in 'struct stat'

MacPorts noreply at macports.org
Sat Dec 9 15:39:59 UTC 2017


#54948: optipng 0.7.6:  error: no member named 'st_atim' in 'struct stat'
----------------------+------------------------
  Reporter:  fracai   |      Owner:  ryandesign
      Type:  defect   |     Status:  assigned
  Priority:  Normal   |  Milestone:
 Component:  ports    |    Version:
Resolution:           |   Keywords:  highsierra
      Port:  optipng  |
----------------------+------------------------

Comment (by phriedrich):

 Is there an option in MacPorts to patch the source for a certain version
 of macOS?

 Replacing lines 515 and 516 in `src/optipng/osys.c` with

 {{{
         #if defined OSYS_DARWIN
              times[0] = sbuf.st_atimespec;
              times[1] = sbuf.st_mtimespec;
          #else
              times[0] = sbuf.st_atim;
              times[1] = sbuf.st_mtim;
          #endif
 }}}

 works for me, but I haven't tested this on older versions of OS X/macOS.

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


More information about the macports-tickets mailing list