0
\$\begingroup\$

I'm trying to copy over a VS2017 solution/project which uses SFML to a different machine. On the original machine, everything compiles and runs fine however when copied over to the second machine (which has a freshly downloaded version of VS2017 with most of the useful add-ons), I'm getting "Cannot open include file: 'SFML\Graphics.hpp'", etc.

I've checked the project properties and everything appears to be the same as its working counterpart.

\$\endgroup\$
6
  • \$\begingroup\$ Are the library files located at the same place on both machines? When you check the properties, are you sure you check for the right build (release/debug)? \$\endgroup\$
    – Vaillancourt
    Mar 25 '18 at 17:17
  • \$\begingroup\$ Everything is contained in the solution folder. \$\endgroup\$
    – M-R
    Mar 25 '18 at 17:25
  • \$\begingroup\$ @AlexandreVaillancourt, although I've noticed that the External Dependencies folder is completely empty... \$\endgroup\$
    – M-R
    Mar 25 '18 at 17:26
  • 1
    \$\begingroup\$ A thing to check: in VS properties of the project, Configuration Properties > C/C++ > Command Line, inspect that long string. If you don't see the root where the folder of SFML is located, then you know you missed something. I would simply add it to the C/C++ > General > Additional Include Directories property. \$\endgroup\$
    – Vaillancourt
    Mar 25 '18 at 17:38
  • \$\begingroup\$ It's a bit hard to debug that kind of issue on sites such as this one. \$\endgroup\$
    – Vaillancourt
    Mar 25 '18 at 17:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.