Opened 7 years ago

Closed 6 years ago

#52910 closed submission (wontfix)

glbinding 2.1.1 submission

Reported by: ken-cunningham-webuse Owned by: macports-tickets@…
Priority: Normal Milestone:
Component: ports Version:
Keywords: Cc: michaelld (Michael Dickens)
Port: glbinding

Description

this is a port that I needed for debugging widelands. It is supplied by homebrew in an older version, but so far not by macports.

glbinding is an MIT licensed, cross-platform C++ binding for the OpenGL API

It's a rather complex OpenGL developer port, and I will not pretend to have done rigorous testing of functionality. However, it installs without error and the basic functions were tested and work for me.

Some further information is here: <https://www.cginternals.com/>

Attachments (5)

patch-glbinding-cmake-installdirs.diff (429 bytes) - added by ken-cunningham-webuse 7 years ago.
Portfile (2.3 KB) - added by ken-cunningham-webuse 7 years ago.
Portfile.2 (2.5 KB) - added by kencu (Ken) 7 years ago.
Portfile.update.20161220
glbinding_mld_0.tar.bz2 (2.3 KB) - added by michaelld (Michael Dickens) 7 years ago.
glbinding_mld_1.tar.bz2 (2.8 KB) - added by michaelld (Michael Dickens) 7 years ago.

Download all attachments as: .zip

Change History (18)

Changed 7 years ago by ken-cunningham-webuse

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

Keywords: submission removed
Port: @2.1.1 removed
Version: 2.3.5

comment:2 Changed 7 years ago by ryandesign (Ryan Carsten Schmidt)

Please:

  • Don't manually set master_sites and distfiles for projects hosted at GitHub. Instead, properly use the github 1.0 portgroup which does the right thing for you.
  • Use the correct OS name. For the condition "10.9 or later", the correct OS name is "OS X". Also please don't call error; instead, call return -code error and supply a sentence fragment; for this type of error we usually use a message like "incompatible Mac operating system version"
  • Don't add a dependency on cmake; the cmake 1.0 portgroup does so for you, so long as you append to the dependencies rather than overwriting them as you're doing.
  • Don't depend on "py-"anything. Always depend on the appropriate subport of the specific Python version you want to use (e.g. depend on py27-pystache instead) , and ensure that specific Python version (e.g. 2.7) is used by the port.

comment:3 Changed 7 years ago by ken-cunningham-webuse

Thanks, Ryan. I believe this addresses the concerns you raised. Thanks for the review. I'm also adding a new port, cpplocate, required to support the construction of the examples for this one.

Last edited 7 years ago by ken-cunningham-webuse (previous) (diff)

Changed 7 years ago by ken-cunningham-webuse

Attachment: Portfile added

Changed 7 years ago by kencu (Ken)

Attachment: Portfile.2 added

Portfile.update.20161220

comment:4 Changed 7 years ago by kencu (Ken)

I have updated the glbinding portfile with some minor edits to description and whitespace

comment:5 Changed 7 years ago by michaelld (Michael Dickens)

Cc: michaelld added

comment:6 Changed 7 years ago by michaelld (Michael Dickens)

There's a little more work to be done. I think all of this should be pushed back upstream, if nothing else than for their information. I'm going to attach a tarball of the current whole proposed directory structure, with my updates listed below in place. So ... IMHO, you need to address (2) and (5) for full port functionality.

1) I'm not sure what SYSTEM_DIR_INSTALL is supposed to do internally, but checking for just /usr and /usr/local is pretty limiting. There has got to be a better way to do whatever they think they are doing with this variable that is more generic. Your patch is good enough for MacPorts' needs.

2) This project stealth-links against other ports under specific variants. For example, if Qt5 is install then +examples will use the qt5 (>= 5.1) install without requiring is as a dependency. I don't think you want qt5-qtbase as a required dependency for this variant; I think it's best off as a separate variant (e.g., "qt_examples"). But, there needs to be an OPTION to select this on or off that's honored. Stealth-linking isn't a good idea. I don't know what other stealth-linking is going on; haven't had time to check.

$ port installed "glbi*"
glbinding-devel @20161219_0+docs+examples (active)
$ port contents glbinding-devel | grep -i qt
  /opt/local/share/glbinding/cubescape-qt.app/Contents/Info.plist
  /opt/local/share/glbinding/cubescape-qt.app/Contents/MacOS/cubescape-qt
$ otool -L $(port contents glbinding-devel | grep MacOS) | grep -i qt
  /opt/local/share/glbinding/cubescape-qt.app/Contents/MacOS/cubescape-qt:
  /opt/local/libexec/qt5/lib/QtWidgets.framework/Versions/5/QtWidgets (compatibility version 5.6.0, current version 5.6.2)
  /opt/local/libexec/qt5/lib/QtGui.framework/Versions/5/QtGui (compatibility version 5.6.0, current version 5.6.2)
  /opt/local/libexec/qt5/lib/QtCore.framework/Versions/5/QtCore (compatibility version 5.6.0, current version 5.6.2)
$ port rdeps glbinding-devel +docs +examples | grep -i qt
$

3) When building documentation with doxygen, also include path:bin/dot:graphviz for dot (graph) files; I added this in already.

4) For many actively-developed ports, having a release and devel version makes sense. I do this for many of mine & other MPdevs also do. I added in the code to the Portfile to do this properly.

5) cmake files are usually placed into ${prefix}/share/cmake . No so for this port by default:

$ port contents glbinding-devel | grep cmake
  /opt/local/share/glbinding/cmake/glbinding/glbinding-export-release.cmake
  /opt/local/share/glbinding/cmake/glbinding/glbinding-export.cmake
  /opt/local/share/glbinding/glbinding-config.cmake

I haven't looked into how to change this install directory, but these devs seem to make such changes pretty simple. I'd much prefer to see the cmake files in their correct directory rather than a project-specific one; just easier to find. Ideally this would be set via configure.args as a way to override the default provided. See, e.g., gr-ais and the variable CMAKE_MODULES_DIR in the patch and top-level CMakeLists.txt for one way to do this.

Changed 7 years ago by michaelld (Michael Dickens)

Attachment: glbinding_mld_0.tar.bz2 added

comment:7 Changed 7 years ago by kencu (Ken)

greatly appreciate the time you spent. Thanks!.

comment:8 Changed 7 years ago by kencu (Ken)

the qt5 thing took 2 minutes a month ago -- since then, pondering what to do about the cmake file locations you suggested.

comment:9 Changed 7 years ago by kencu (Ken)

It looks like the glbinding devs have discovered this nascent portfile, and they seem interested in updating glbinding to minimize portfile tricks and patches. So I guess we'll see what they integrate, and how much they'd like to incorporate.

<https://github.com/cginternals/glbinding/issues/221>

Last edited 7 years ago by kencu (Ken) (previous) (diff)

comment:10 Changed 7 years ago by kencu (Ken)

When I changed the cmake files location for cpplocate (related to this ) this port couldn't find the files properly. So for now I thought I'd leave the cmake files location as they specify.

I've updated the portfile to the current version (2.1.3) and added the devel version. I made the qt5 examples a separate variant.I can make a PR for it, if you like. Current version is here:

<https://github.com/kencu/macports-staging/tree/master/devel/glbinding>

Works very well with the examples, and for the big port I needed to use it in (widelands).

comment:11 Changed 7 years ago by michaelld (Michael Dickens)

OK. Just like cpplocate, the next tarball works for me. I didn't test it with out-of-tree configuration, but it's the same basicv setup as for cpplocate & thus should work. Please test & verify (this & cpplocate).

Changed 7 years ago by michaelld (Michael Dickens)

Attachment: glbinding_mld_1.tar.bz2 added

comment:12 Changed 7 years ago by michaelld (Michael Dickens)

NIce! about the upstream taking interest in this work. These installs do work for me ... which is pretty cool.

comment:13 Changed 6 years ago by kencu (Ken)

Resolution: wontfix
Status: newclosed

I'll handle this another way, if it seems time for it to be in MacPorts.

Note: See TracTickets for help on using tickets.