Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: How to hide the sfml .dlls from my solution explorer?  (Read 7258 times)

0 Members and 1 Guest are viewing this topic.

ggggggggggggggg

  • Newbie
  • *
  • Posts: 36
    • View Profile
    • Email
How to hide the sfml .dlls from my solution explorer?
« on: May 30, 2016, 06:53:00 am »
I tried doing it the normal way by adding the .dll are reference but I got this error:

A reference to the "....dll" could not be added. Please make sure that the file is accessible and that it is a valid assembly or COM component.

I also tried NuGet but it also threw all the .dlls in my solution explorer. When I try to put them in a folder they break and the compiler can't find them.

How do I put the .dlls inside a folder or add them them by reference?


Recoil

  • Jr. Member
  • **
  • Posts: 76
    • View Profile
Re: How to hide the sfml .dlls from my solution explorer?
« Reply #1 on: May 30, 2016, 07:51:03 am »
I have come across several threads when I first started using SFML about how to keep the dll's in a separate folder myself.  Unfortunately this is not possible.  The .dll file have to be in the same directory as you exe.

zsbzsb

  • Hero Member
  • *****
  • Posts: 1409
  • Active Maintainer of CSFML/SFML.NET
    • View Profile
    • My little corner...
    • Email
Re: How to hide the sfml .dlls from my solution explorer?
« Reply #2 on: June 04, 2016, 09:22:31 pm »
Speaking of the CSFML dlls here, just put them in any folder you please and then use a post build command to copy them to the output (build) folder. No need to put them in your project as individual files.
Motion / MotionNET - Complete video / audio playback for SFML / SFML.NET

NetEXT - An SFML.NET Extension Library based on Thor

Recoil

  • Jr. Member
  • **
  • Posts: 76
    • View Profile
Re: How to hide the sfml .dlls from my solution explorer?
« Reply #3 on: June 05, 2016, 12:41:11 am »
@zsbzsb - But they will still be required to be in the same folder as the build .exe file, correct?  There is not way to have say a "Libs" folder for all the .dll's, then just have all that put in the build folder?

I just want to be sure I am correct on whether that is the case or not :)

zsbzsb

  • Hero Member
  • *****
  • Posts: 1409
  • Active Maintainer of CSFML/SFML.NET
    • View Profile
    • My little corner...
    • Email
Re: How to hide the sfml .dlls from my solution explorer?
« Reply #4 on: June 09, 2016, 01:34:17 pm »
Yes, that is why your post build command would copy from the libs folder (or w/e you name it) to the build folder.

Something like this would work:
xcopy "$(ProjectDir)/Libs/*" "$(ProjectDir)$(OutDir)" /sy
Motion / MotionNET - Complete video / audio playback for SFML / SFML.NET

NetEXT - An SFML.NET Extension Library based on Thor

 

anything