Opened 13 years ago

Closed 13 years ago

#29334 closed update (duplicate)

fizmo 0.6.9 update

Reported by: Christoph.Ender@… Owned by: macports-tickets@…
Priority: Normal Milestone:
Component: ports Version: 1.9.2
Keywords: haspatch Cc: ryandesign (Ryan Carsten Schmidt), nerdling (Jeremy Lavergne)
Port: fizmo

Description

The attached Portfile will make fizmo 0.6.9 compile using MacPorts.

Attachments (3)

Portfile (1.7 KB) - added by Christoph.Ender@… 13 years ago.
Portfile for fizmo 0.6.9
Portfile-0.6.8-to-0.6.9.txt (1.4 KB) - added by Christoph.Ender@… 13 years ago.
Diff from 0.6.8 to 0.6.9 portfile
ncurses-macosx-errno.c (678 bytes) - added by Christoph.Ender@… 13 years ago.
echo_wchar errno example

Download all attachments as: .zip

Change History (10)

Changed 13 years ago by Christoph.Ender@…

Attachment: Portfile added

Portfile for fizmo 0.6.9

comment:1 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)

Cc: ryandesign@… added
Keywords: haspatch added

Please supply a unified diff, not a complete portfile. This makes it easier to review your proposal. For one thing, your new port omits the $Id$ line, which we don't want omitted.

Your new port lists only an md5 checksum; we're trying to remove md5 from MacPorts and would rather list sha1 and rmd160 checksums.

Your new port removes the ncursesw and libxml2 dependencies that were there. Are these no longer needed? I tried installing the port and it seems to link with Mac OS X's ncurses and libxml; it would be better to bring back the dependencies, and fix the build scripts so that MacPorts versions of these are used.

Changed 13 years ago by Christoph.Ender@…

Attachment: Portfile-0.6.8-to-0.6.9.txt added

Diff from 0.6.8 to 0.6.9 portfile

comment:2 in reply to:  1 ; Changed 13 years ago by Christoph.Ender@…

Replying to ryandesign@…:

Please supply a unified diff, not a complete portfile. This makes it easier to review your proposal. For one thing, your new port omits the $Id$ line, which we don't want omitted.

Submitted attachment "Portfile-0.6.8-to-0.6.9.txt" which should hold the required diff.

Your new port lists only an md5 checksum; we're trying to remove md5 from MacPorts and would rather list sha1 and rmd160 checksums.

This should be addressed in the diff file.

Your new port removes the ncursesw and libxml2 dependencies that were there. Are these no longer needed? I tried installing the port and it seems to link with Mac OS X's ncurses and libxml; it would be better to bring back the dependencies, and fix the build scripts so that MacPorts versions of these are used.

This is an intentional change. It turned out that using a self-compiled- or MacPorts-supplied version of ncurses will result in ncurses (or some other system component) setting errno != 0 when non-ASCII chars are written to the screen. For some reason, the ncurses version supplied by Apple does not show this behavior. Since Mac OS X is not a supported platform for ncurses, I decided to use the Mac OS X-packaged version of ncurses. For simplicity, I decided to also use the Apple-supplied libxml2, if for any reason the MacPorts version would be preferred, I'll put the dependency back into the portfile.

comment:3 in reply to:  2 ; Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)

Thanks for the new diff.

Replying to Christoph.Ender@…:

Your new port removes the ncursesw and libxml2 dependencies that were there.

This is an intentional change. It turned out that using a self-compiled- or MacPorts-supplied version of ncurses will result in ncurses (or some other system component) setting errno != 0 when non-ASCII chars are written to the screen. For some reason, the ncurses version supplied by Apple does not show this behavior. Since Mac OS X is not a supported platform for ncurses, I decided to use the Mac OS X-packaged version of ncurses. For simplicity, I decided to also use the Apple-supplied libxml2, if for any reason the MacPorts version would be preferred, I'll put the dependency back into the portfile.

I'm not sure what you mean by "Mac OS X is not a supported platform for ncurses". Obviously ncurses works on Mac OS X, since both Mac OS X and MacPorts include it, and tons of other ports use MacPorts ncurses without issue. Yes it is preferred to use MacPorts versions of libraries; it's one of the fundamental principles of MacPorts; see FAQ and FAQ. Of course if the MacPorts version of ncurses doesn't work for fizmo then that's an exception, but I'd spend some time figuring out why MacPorts ncurses isn't working. There may be Apple-specific patches in Mac OS X's ncurses to account for the difference, but there's also the version to consider: MacPorts ncurses is a couple versions newer than Mac OS X's, so fizmo may simply need to make some changes to take newer ncurses versions into account.

comment:4 in reply to:  3 Changed 13 years ago by Christoph.Ender@…

Replying to ryandesign@…:

Thanks for the new diff.

Replying to Christoph.Ender@…:

Your new port removes the ncursesw and libxml2 dependencies that were there.

This is an intentional change […]

I'm not sure what you mean by "Mac OS X is not a supported platform for ncurses".

Sorry, that wasn't very precise. Before asking for support on the ncurses bug list, I found out that http://invisible-island.net/ncurses/ncurses.faq.html states “And a few other platforms such as Mac OS X have been reported to work”, Mac OS X is neither listed in the “known to work”, nor in the “8-bit-charachters are known to work” section. So, this should have been that Mac OS X probably hasn't been tested officially.

Obviously ncurses works on Mac OS X, since both Mac OS X and MacPorts include it, and tons of other ports use MacPorts ncurses without issue.

I did not say it does not work. I just found out that displaying a non-ASCII char using the “echo_wchar” function will cause errno != 0 to be set. I've attached a tiny code snippet that should illustrate the problem. I've tested this on Mac OS X and Linux (the only other unix platform that's currently available to me), and for ncurses 5.9, errno is != 0 on Mac OS X, 0 on linux. Replies on the ncurses-bug mailing list have been inconclusive, leaving me to the choice whether to set errno=0 after every echo_wchar() or refresh() function call, or alternatively to include the Mac OS X version for the time being. I'm aware that this isn't a good solution, I'm open to suggestions how to resolve this in some other way.

Changed 13 years ago by Christoph.Ender@…

Attachment: ncurses-macosx-errno.c added

echo_wchar errno example

comment:5 Changed 13 years ago by nerdling (Jeremy Lavergne)

Cc: snc@… added

Cc Me!

comment:6 Changed 13 years ago by Christoph.Ender@…

Please close ticket: Should be resolved by update to 0.6.10, see ticket #30740.

comment:7 Changed 13 years ago by mf2k (Frank Schima)

Resolution: duplicate
Status: newclosed
Note: See TracTickets for help on using tickets.