// test_for_static_lib.cpp : Defines the entry point for the console application.
//#include "stdafx.h"#include <cstdio>#include<iostream>#include<boost/any.hpp>int _tmain(int argc, _TCHAR* argv[]){ boost::any a(5); a=7.67; std::cout<<boost::any_cast<double>(a)<<std::endl; printf("%d",1); getchar(); return 0;}
下载单独静态编译好的lib,
以及window下的boost包,用于include 头文件
在工程的属性上选择头文件所在路径
在c++ general下选择Additonal Include Directories:放置头文件路径
D:\Documents\Downloads\boost_1_52_0\boost_1_52_0
在Linker general下选择Additonal Include Directories:放置静态库路径
C:\mao\lib32