当前位置:网站首页>d,ldc构建共享库
d,ldc构建共享库
2022-07-03 00:59:00 【fqbqrr】
module dimedll;
export void testFunc() {
// 仅用`-fvisibility=hidden`编译时,需要export
import std.stdio;
writeln("This is from dll");
}
用ldc2 -shared dimedll.d生成lib/dll.
import dimedll : testFunc;
pragma(lib, "dimedll");
void main() {
import std.stdio;
writeln("构建ime");
testFunc();
}
用ldc2 -link-defaultlib-shared dime.d生成带dimedll.dll的exePosix中区别是,不是用pragma(lib),你要用-L-ldimedll链接至libdimedll.{so,dylib}.
边栏推荐
- [system analyst's road] Chapter V double disk software engineering (development model development method)
- 按键精灵打怪学习-自动回城路线的判断
- 【系统分析师之路】第五章 复盘软件工程(开发模型开发方法)
- 安全运营四要素之资产、脆弱性、威胁和事件
- Win10 can't be installed in many ways Problems with NET3.5
- Telephone network problems
- Asynchronous, email and scheduled tasks
- MySQL foundation 04 MySQL architecture
- Kivy教程大全之如何在 Kivy 中创建下拉列表
- JDBC courses
猜你喜欢

FPGA - 7系列 FPGA内部结构之Clocking -04- 多区域时钟
![[AUTOSAR twelve mode management]](/img/42/292e3da3f5d488a1e8c10ea9bbfbab.png)
[AUTOSAR twelve mode management]

机器学习术语
[AUTOSAR five methodology]

Asynchronous, email and scheduled tasks

基本远程连接工具Xshell

matlab将数字矩阵保存为地理空间数据出错,显示下标索引必须为正整数类型或逻辑类型,解决

寻找标杆战友 | 百万级实时数据平台,终身免费使用

Esp32 simple speed message test of ros2 (limit frequency)

Basic concept and implementation of overcoming hash
随机推荐
按键精灵打怪学习-自动寻路回打怪点
Canvas drawing -- bingdd
FPGA - 7 Series FPGA internal structure clocking -04- multi area clock
[AUTOSAR XIII NVM]
excel去除小数点后面的数据,将数字取整
拥抱平台化交付的安全理念
(C语言)数据的存储
How to convert Quanzhi a40i/t3 to can through SPI
Key wizard hit strange learning - automatic path finding back to hit strange points
ROS2之ESP32简单速度消息测试(极限频率)
信息熵的基础
Strongly connected components of digraph
leetcode:871. Minimum refueling times [Pat has done before + maximum stacking + greed]
[AUTOSAR eight OS]
Usage of using clause in kingbases alter table
Understanding and distinguishing of some noun concepts in adjustment / filtering
MySQL --- 数据库查询 - 条件查询
合并K个已排序的链表
Basis of information entropy
leetcode 6103 — 从树中删除边的最小分数