http://4fire.wordpress.com/2012/03/18/gsl-1-15-building-with-visual-studio-2010/

Update 05/02/2014: A good book for GSL (updated with 1.16 version) is GNU Scientific
Library Reference Manual – Third Edition
.

Update 14-11-2013: Building GSL 1.16with Visual Studio 2010 (VC++ 10): In July, GSL 1.16 was released, the source code files can be obtained fromthis. If one
wants to build it with Visual Studio 2012 (VC++ 11), the VS solution file can be downloaded fromthis URL and the same steps
(from 1 to 6) as doing with GSL 1.15 and VS 2010 are needed. Based onVC++ 11 solution files,
I have created solution for some one who still works with Visual Studio 2010 (VC++ 10), and that file can be downloaded fromthis
address
.

Today I build GSL 1.15 for using with Visual Studio 2010. After downloading GSL 1.15 source code, I download VS 2010 solution files and start building GSL’s .dll and .lib for my own. And these are the steps:

1. Exatracting file gsl-1.15-vc10.zip into a folder (GSL_build for example). You should have the folder GSL_build\gsl-1.15-vc10after this step.

2. Exatracting file gsl-1.15.tar.gz into folderGSL_build\gsl-1.15.

3. Copy all gsl_*.h files from GSL_build\gsl-1.15 folder to
GSL_build\gsl-1.15-vc10\gsl
 folder (you should do a search here and make a copy on the found files).

4. Copy all files from folder GSL_build\gsl-1.15 to GSL_build\gsl-1.15-vc10 folder, do not overwrite the two filetemplates_on.h and env.c or you will encounter errors withRelease build.

5. Open file GSL_build\gsl-1.15-vc10\build.vc10\gsl.lib.sln with VS 2010 and startDebug andRelease build.

6. Open file GSL_build\gsl-1.15-vc10\build.vc10\gsl.dll.sln with VS 2010 and start Debug and Release build. You may need to copy cblas.lib file from folder build.vc10\lib\Win32to
folder build.vc10\dll\Win32 (Debug or Release sub folder) to make this step runs.

7. If you encounter errors (like me), then these are the fixings:

+ file bspline.c: moving variables declarations to the first part of the function:gsl_bspline_greville_abscissa(size_t i, gsl_bspline_workspace *w)

+ file rk4imp.c: replacing sqrt(3) with
M_SQRT3
.

It’s done now. You should have your .dll in gsl_build\gsl-1.15-vc10\build.vc10\dll and .lib in the foldergsl_build\gsl-1.15-vc10\build.vc10\lib.

8. Notes:

+ When copying these above files and folders, do not over write anyfiles.

+ You can build GSL with other blas library like Goto Blas, Atlas. Just replacing the cblas.lib with the suitable .lib file in buildinggsl.dll.

+ For using GSL, you need both .lib file in the gsl_build\gsl-1.15-vc10\build.vc10\lib folder and .dll file in thegsl_build\gsl-1.15-vc10\build.vc10\dll
folder. Do not use .lib files fromgsl_build\gsl-1.15-vc10\build.vc10\dll folder.

+ You can use examples from Physics 780.20 Computational Physics course for testing your .dll and .lib files.

+ Another source you can use is located at: Data Analysis with Open source Tools. This is a good book with good examples.

+ Even though I did not test the above process of building GSL with other Visual Studio versions (VS Express, VS 2008, VS 2012) but I strongly believe that the same details can be applied.

!!! PS: add #define GSL_DLL at the beginning of the code.

!!! PPS: when using win32 application, 'include stdafx.h' should be placed ahead.

!!! PPPS: the binary and src exe files can be downloaded from: http://download.csdn.net/detail/aldenphy/7407527

GSL 1.15 and 1.16 building with Visual Studio 2010 --FROM 4fire的更多相关文章

  1. Building Python 2.7.10 with Visual Studio 2010 or 2015 - Google Chrome

    您的浏览器(Chrome 33) 需要更新.该浏览器有诸多安全漏洞,无法显示本网站的所有功能. 了解如何更新浏览器 × p-nand-q.com C++  Python  Programming  L ...

  2. 【C++】GSL(GNU Scientific Library) 的安装及在 Visual Studio 2017 中的使用

    GSL 是 GNU 开发并维护的科学计算的库,其中包括: 复数 多项式的根 特殊函数 向量和矩阵 排列 排序 BLAS支持 线性代数 Eigensystems 快速傅立叶变换 正交 随机数 准随机序列 ...

  3. ubuntu 16.04安装visual studio code 提示libnss3版本低:NSS >= 3.26 is required

    Linux Ubuntu 1604安装VS CODE之后,执行./code报错误: [3781:0914/160851.489979:FATAL:nss_util.cc(632)] NSS_Versi ...

  4. Python:安装opencv出现错误Could not find a version that satisfies the requirement numpy==1.13.3 (from versions: 1.14.5, 1.14.6, 1.15.0rc2, 1.15.0, 1.15.1, 1.15.2, 1.15.3, 1.15.4, 1.16.0rc1, 1.16.0rc2,

    安装opencv的时候,出现numpy的版本不匹配,卸载了不匹配的版本,重新安装却是一点用都没有,后面尝试了一下这里的提示pip更新,居然安装成功了,看来pip的版本过低真是误事啊. 报错是: Cou ...

  5. Visual Studio 2017 发布 15.5 版本,百度网盘离线安装包下载。

    Visual Studio 2017 15.5 版本已正式发布,同时发布的还有 Visual Studio for Mac 7.3 .此次更新包含主要性能改进,新特性以及 bug 修复.发行说明中文版 ...

  6. 在WINDOWS中安装使用GSL(MinGW64+Sublime Text3 & Visual Studio)

    本文介绍在Windows下安装使用GSL库,涉及GSL两个版本(官方最新版及GSL1.8 VC版).msys shell.GCC.G++等内容,最终实现对GSL安装及示例基于MinGW64在Subli ...

  7. Building OpenCascade on Windows with Visual Studio

    Building OpenCascade on Windows with Visual Studio eryar@163.com 摘要Abstract:详细说明OpenCascade的编译配置过程,希 ...

  8. Visual Studio 15 Preview 4安装

    今天看到了有Visual Studio 15 Preview 4的安装文件放出,便想去安装体验一下C# 7.0的新语法.谁知安装时遇到一个错误: 手动下载这个补丁安装后,还是提示这个错误.本来以为是还 ...

  9. 【译】Visual Studio 15 预览版更新说明

    序:恰逢Build2016大会召开,微软发布了VS2015的update2更新包和VS2016预览版.本人正在提升英文水平中,于是在这里对VS2016预览版的官方文档进行了部分翻译.因为VS有些功能使 ...

随机推荐

  1. BZOJ4555 [Tjoi2016&Heoi2016]求和 【第二类斯特林数 + NTT】

    题目 在2016年,佳媛姐姐刚刚学习了第二类斯特林数,非常开心. 现在他想计算这样一个函数的值: S(i, j)表示第二类斯特林数,递推公式为: S(i, j) = j ∗ S(i − 1, j) + ...

  2. JavaScript简明教程之Node.js

    Node.js是目前非常火热的技术,但是它的诞生经历却很奇特. 众所周知,在Netscape设计出JavaScript后的短短几个月,JavaScript事实上已经是前端开发的唯一标准. 后来,微软通 ...

  3. HDU 5696 RMQ+滑窗

    区间的价值 Time Limit: 10000/5000 MS (Java/Others)    Memory Limit: 65536/65536 K (Java/Others)Total Subm ...

  4. vue使用stylus

    在package.json中添加  stylus-loader "css-loader": "^0.28.0", "stylus-loader&quo ...

  5. layer相关

    关闭窗口 var index = parent.layer.getFrameIndex(window.name);parent.layer.close(index);

  6. 【NOIP2009】最优贸易

    描述 C 国有 n 个大城市和 m 条道路,每条道路连接这 n 个城市中的某两个城市.任意两个城市之间最多只有一条道路直接相连.这 m 条道路中有一部分为单向通行的道路,一部分为双向通行的道路,双向通 ...

  7. 恶补一下DP+背包专题(刷刷水题)L2

    开心的金明 题目大意 就是求一定背包容量的最大值 思路 想必大家都知道,一看到这种题目,就会想起01背包 虽然特别简单但是还是讲一下吧 状态设置 由于这题差不多是一个01背包的版子题,那么我们就只需要 ...

  8. [LeetCode] Path Sum II 深度搜索

    Given a binary tree and a sum, find all root-to-leaf paths where each path's sum equals the given su ...

  9. 获取当前应用程序实例(instance:HINSTANCE)(转)

    if using MFC AfxGetInstanceHandle(). For console programs, call GetConsoleWindow() to get the HWND t ...

  10. Qualcomm 專業名詞

    APSS Application processor subsystem software BAM Bus Access Manager blsp BAM low speed peripheral T ...