ref: https://stackoverflow.com/questions/29987716/cannot-use-gsl-library-on-macos-ld-symbols-not-found-for-architecture-x86-6

Indeed, as @trojanfoe and @bergercookie said you have to compile your file and then link it to the library. As explained in compile and link, for that particular example:
First compile the file:
gcc -Wall -I/usr/local/include -c example.c -o example.o
second, link it to the library:
gcc -L/usr/local/lib example.o -lgsl -o example
where of course, /usr/local/lib should be replaced for the path where you have gsl installed.
The example file is excutable.
EDIT: in macOS, from Yosemite the default location for the installation is /opt/local/lib (and /opt/local/include)

最新文章

  1. SVN的部署及分支等方法
  2. 实践最简单的项目:WC
  3. js基础到精通全面教程--JS教程
  4. uglifyjs2压缩混淆js文件
  5. adapter.notifyDataSetChanged(); 没有反应
  6. varnish 的一个配置
  7. java之BASE64加解密
  8. 数据分析(4):Scipy
  9. lightoj 1397 - Sudoku Solver
  10. UserControl和CustomControl基础【PluraSight】
  11. CodeForces 706B Interesting drink (二分查找)
  12. c++设计模式之状态模式
  13. Android基础总结(精华完整版)
  14. 帆软的报表系统与泛微OA结合起来,这两个软件麦枫提供了经典的服务。
  15. 浅谈spring为什么推荐使用构造器注入
  16. undefined reference to symbol '_ZNK11GenICam_3_016GenericException17GetSourceFileNameEv'
  17. win10 下JDK10的下载安装与环境变量配置
  18. SQL SERVER TRANSACTION 事物
  19. Redis集群的操作
  20. Word 2010 制作文档结构之页码从正文开始设置

热门文章

  1. ES6标准入门 第五章:正则的扩展
  2. FiddlerCore修改http返回结果
  3. python每日一练:0005题
  4. dotnet sdk 的镜像tag 相关
  5. fidder抓包工具使用方法,完整流程
  6. ajax实现异步请求模态登陆
  7. 区块链开源实现hyperledger fabric架构详解
  8. Java——自定义外部字体文件
  9. 计算机系统结构总结_Cache Optimization
  10. 深入理解React组件传值(组合和继承)