3

I know that I can use this pragma to add a library into a project:

#pragma comment(lib, "opencv_calib3d246d.lib") 

This allow me to create a include file and when it is added to a project, it includes all libraries to that project (in this case, opencv libraries).

Is there any other #pragma that I can use to set the include path or library search path?

I am suing visual studio 2012.

mans
  • 17,104
  • 45
  • 172
  • 321
  • 1
    Even if you could: Why would you want your code to be this inflexible? You force any other coders on the project to have their include and library search paths exactly like you have. – arne Oct 21 '13 at 13:36
  • @arne: I hope I can use environment variable as part of this to solve the problem that you indicate. But mainly I want this for testing, when I am creating a new project to test a sample code, I don't want to go and set it from scratch. – mans Oct 21 '13 at 13:43

1 Answers1

0

This should do it on a file by file basis: include_alias. Other than that, I don't think so.

Chris Olsen
  • 3,243
  • 1
  • 27
  • 41