Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

i can not build this project #10

Closed
wzyjobs opened this issue Sep 19, 2020 · 7 comments
Closed

i can not build this project #10

wzyjobs opened this issue Sep 19, 2020 · 7 comments

Comments

@wzyjobs
Copy link

wzyjobs commented Sep 19, 2020

sorry,i can not build this project , am i wrong to use the lib that version in the image? 3q
image
image

@amhndu
Copy link
Owner

amhndu commented Sep 19, 2020

The download option looks about right, but have you installed it properly? I'm not familiar with Max OS X to comment on it. After downloading, did you install it in a system folder? Do you have cmake? Does CLion/cmake know where to find it?

@csanycall
Copy link

macOS, the same problem~
comment the line, compile ok, I'll test it with rom

@amhndu
Copy link
Owner

amhndu commented Nov 2, 2020

Can you post the error that you actually get on that line?

@ape-casear
Copy link

ape-casear commented Nov 11, 2020

macOS, the same problem~

/Users/a123/Dpan/learn/SimpleNES/src/PPU.cpp:181:45: error: no matching
conversion for functional-style cast from 'const std::uint32_t' (aka
'const unsigned int') to 'sf::Color'
...= sf::Color(colors[m_bus.readPalette(paletteAddr)]);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

@amhndu
Copy link
Owner

amhndu commented Nov 11, 2020

Can you pull and try again? I don't have a Mac so I can't test directly but I think it should be fixed now.

@ape-casear
Copy link

Author: Amish Naidu <[email protected]>
Date:   Wed Nov 11 16:53:07 2020 +0530

    Use sf::Uint32 instead of std::uint32_t

Already up to date.

and results

/Users/a123/Dpan/learn/SimpleNES/src/PPU.cpp:181:45: error: no matching
      conversion for functional-style cast from 'const sf::Uint32' (aka
      'const unsigned int') to 'sf::Color'
  ...= sf::Color(colors[m_bus.readPalette(paletteAddr)]);
       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Library/Frameworks/SFML.framework/Headers/Graphics/Color.hpp:40:25: note: 
      candidate constructor (the implicit copy constructor) not viable: no known
      conversion from 'const sf::Uint32' (aka 'const unsigned int') to
      'const sf::Color' for 1st argument
class SFML_GRAPHICS_API Color
                        ^
/Library/Frameworks/SFML.framework/Headers/Graphics/Color.hpp:40:25: note: 
      candidate constructor (the implicit move constructor) not viable: no known
      conversion from 'const sf::Uint32' (aka 'const unsigned int') to
      'sf::Color' for 1st argument
/Library/Frameworks/SFML.framework/Headers/Graphics/Color.hpp:51:5: note: 
      candidate constructor not viable: requires 0 arguments, but 1 was provided
    Color();
    ^
/Library/Frameworks/SFML.framework/Headers/Graphics/Color.hpp:62:5: note: 
      candidate constructor not viable: requires at least 3 arguments, but 1 was
      provided
    Color(Uint8 red, Uint8 green, Uint8 blue, Uint8 alpha = 255);
    ^

@amhndu
Copy link
Owner

amhndu commented Nov 29, 2020

I do not have a mac, so I can not reproduce the steps you've taken here. The best I could do was run it as a Github Action #13 which uses brew to install sfml and that seems to compile fine.
I highly recommend using package managers over installing things manually.
For mac, brew is good!
All you need to do is run brew install sfml

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

No branches or pull requests

4 participants