简体   繁体   English

将STL lib添加到mac os x bin

[英]Add STL lib to mac os x bin

I download the STL library to do some test with it, but the folder does not have a "configure, make, make install " files. 我下载了STL库来对它进行一些测试,但该文件夹没有“configure,make,make install”文件。 How can i add it to bin? 我怎样才能将它添加到垃圾箱? So i can use always 所以我总能使用

    #include <vector.h>

instead of 代替

    #include "vector.h"

and add the STL folder in all my project. 并在我的所有项目中添加STL文件夹。 在此输入图像描述

If you install a C++ compiler it will ship with a C++ Standard Library implementation with includes the STL (STLPort?) you're talking about. 如果您安装了C ++编译器,它将附带一个C ++标准库实现,其中包含您正在讨论的STL(STLPort?)。

XCode and also macports gcc include this. XCode和macports gcc包括这个。 You should not be setting this up like you are now. 你不应该像现在这样设置它。

Also note that the Standard library headers do not have a .h suffix. 另请注意,标准库头文件没有.h后缀。 So you need 所以你需要

#include <vector>

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM