Skip to content

Conversation

ericLemanissier
Copy link
Contributor

Specify library name and version: freeglut/3.2.1

this is a port of https://github.com/bincrafters/conan-freeglut


  • I've read the guidelines for contributing.
  • I've followed the PEP8 style guides for Python code in the recipes.
  • I've used the latest Conan client version.
  • I've tried at least one configuration locally with the
    conan-center hook activated.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

Comment on lines 27 to 38
/*
glutInit(&argc,argv);
glutInitDisplayMode(GLUT_DEPTH | GLUT_DOUBLE | GLUT_RGBA);
glutInitWindowPosition(100,100);
glutInitWindowSize(320,320);
glutCreateWindow("Lighthouse3D - GLUT Tutorial");

// register callbacks
glutDisplayFunc(renderScene);

// enter GLUT event processing cycle
glutMainLoop();*/
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe this?

Suggested change
/*
glutInit(&argc,argv);
glutInitDisplayMode(GLUT_DEPTH | GLUT_DOUBLE | GLUT_RGBA);
glutInitWindowPosition(100,100);
glutInitWindowSize(320,320);
glutCreateWindow("Lighthouse3D - GLUT Tutorial");
// register callbacks
glutDisplayFunc(renderScene);
// enter GLUT event processing cycle
glutMainLoop();*/
glutInit(&argc,argv);

Copy link
Contributor Author

@ericLemanissier ericLemanissier Apr 16, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure yet why, but I get a runtime error when calling glutInit on WSL (it passes on windows), with the following output failed to open display ''

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

WSL is missing the support to run graphics ... the API is there but it fails AFAIK

Been a while since I had this problem, but last time I used the usual headless CI flags to trick it to run from my travis CI scripts doing electron

Co-authored-by: Chris Mc <prince.chrismc@gmail.com>
@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

prince-chrismc
prince-chrismc previously approved these changes Apr 16, 2021
def requirements(self):
self.requires("opengl/system")
self.requires('glu/system')
if self.settings.os == "Linux":
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Untested. Since you're the BSD specialist, you have the last word on this.
If accepted, this change should probably be applied to other places in this recipe.

Suggested change
if self.settings.os == "Linux":
if self.settings.os in ("Linux", "FreeBSD"):

if self.settings.os == "Windows":
if not self.options.shared:
self.cpp_info.components['freeglut_'].defines.append("FREEGLUT_STATIC=1")
self.cpp_info.components['freeglut_'].defines.append("FREEGLUT_LIB_PRAGMAS=0")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this macro also required for mingw?
#pragma warning is only used by msvc.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

might be required for Intel/Clang, not sure about MinGW

SSE4
SSE4 previously approved these changes Apr 17, 2021
Co-authored-by: Anonymous Maarten <madebr@users.noreply.github.com>
@ericLemanissier ericLemanissier dismissed stale reviews from SSE4 and prince-chrismc via 6b95548 April 21, 2021 16:52
ericLemanissier and others added 2 commits April 21, 2021 18:55
Co-authored-by: Anonymous Maarten <madebr@users.noreply.github.com>
Co-authored-by: Chris Mc <prince.chrismc@gmail.com>
@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot
Copy link
Contributor

All green in build 16 (00a6463001f13a225d72b0b033f76d2eacdebe5c):

  • freeglut/3.2.1@:
    All packages built successfully! (All logs)

@conan-center-bot conan-center-bot merged commit fc45023 into conan-io:master Apr 29, 2021
@CroydonBot CroydonBot deleted the freeglut branch April 29, 2021 10:33
AlvaroFS pushed a commit to AlvaroFS/conan-center-index that referenced this pull request May 7, 2021
* add freeglut/3.2.1

this is a port of https://github.com/bincrafters/conan-freeglut

* remove useless option

* use standard libdirs

* fix fpic

* disable macos

* test package as C project

* disable gcc 10

* disable clang 11 too

* Apply suggestions from code review

Co-authored-by: Chris Mc <prince.chrismc@gmail.com>

* set cmake and pkg-config names

also, fixup tabs and missing import in test recipe

* increase test coverage

* fix test

* Update recipes/freeglut/all/conanfile.py

Co-authored-by: Anonymous Maarten <madebr@users.noreply.github.com>

* Update recipes/freeglut/all/conanfile.py

Co-authored-by: Anonymous Maarten <madebr@users.noreply.github.com>

* Update recipes/freeglut/all/conanfile.py

Co-authored-by: Chris Mc <prince.chrismc@gmail.com>

* freeglut: change download to SourceForge + reformatting

* cache cmake

Co-authored-by: Chris Mc <prince.chrismc@gmail.com>
Co-authored-by: Anonymous Maarten <madebr@users.noreply.github.com>
Co-authored-by: Croydon <git@cr0ydon.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants