如何离线运行pulp代码呢?

大怪科学 20230617

  • 离线安装

引言

最近在折腾pulp,代码很优秀,强烈推荐。想在公司环境中跑起来,但鉴于公司eda服务器无法连外网,需要从外部导入数据。

整理了一些要求,供大家参考:

1.离线安装bender, 加入path路径

  • 把~/bin目录加到PATH路径中。
  • 测试下bender命令是否可行:bender --help

2.离线下载依赖仓库

例如打算跑axi这个repo,打开它目录下Bender.yaml文件,搜索dependencies关键词:

dependencies:  
    common_cells: { git: "https://github.com/pulp-platform/common_cells.git", version: 1.27.0 }  
    common_verification: { git: "https://github.com/pulp-platform/common_verification.git", version: 0.2.3 } 
    tech_cells_generic:  { git: "https://github.com/pulp-platform/tech_cells_generic.git", version: 0.2.2 }

说明它依赖comon_cellss、common_verification、tech_cells_generic这三个仓库,把那些仓库也clone到与axi平行的目录。

目录树结构如下图所示:

3.修改Bender.yml 文件

默认运行会根据Bender.yml中的depenencies关键词,自动clone代码下来。

我们需要做离线运行,代码已经下载好了,直接改Bender.yml。把git关键词改成path,目录也改成相对路径(相对Bender.yml的路径)。

common_cells: { git: "https://github.com/pulp-platform/common_cells.git", version: 1.27.0 } 
改成 
common_cells: { path: "../common_cells"}

此外,我们还需要进一步修改依赖包中的Bender.yml ,否则bender还是会在读取依赖包的时侯再次发起git clone操作。

比如common_cells中的bender.yml

common_verification: { git: "https://github.com/pulp-platform/common_verification.git", version: 0.2.0 }
tech_cells_generic: { git: "https://github.com/pulp-platform/tech_cells_generic.git", version: 0.2.11 }
修改成
common_verification: { path: "../common_verification", version: 0.2.0 }
tech_cells_generic: { path: "../tech_cells_generic", version: 0.2.11 }

4.编译运行

以axi为例,需要切换到scripts目录下运行

cd scripts

#编译
./compile_vsim.sh

#运行
./run_vsim.sh

查看全文

点赞

大怪科学

作者最近更新

  • Aigtek功率放大器在传感器测试领域研究中的应用
    大怪科学
    2天前
  • 泰科电子座椅位置传感器如何实现可靠保护
    大怪科学
    2天前
  • 中微爱芯推出高精度零漂移运算放大器AiP856X系列
    大怪科学
    4天前

期刊订阅

相关推荐

  • LINUXyum源替换为本地源

    2023-06-12

评论0条评论

×
私信给大怪科学

点击打开传感搜小程序 - 速览海量产品,精准对接供需

  • 收藏

  • 评论

  • 点赞

  • 分享

收藏文章×

已选择0个收藏夹

新建收藏夹
完成
创建收藏夹 ×
取消 保存

1.点击右上角

2.分享到“朋友圈”或“发送给好友”

×

微信扫一扫,分享到朋友圈

推荐使用浏览器内置分享功能

×

关注微信订阅号

关注微信订阅号,了解更多传感器动态

  • #{faceHtml}

    #{user_name}#{created_at}

    #{content}

    展开

    #{like_count} #{dislike_count} 查看评论 回复

    共#{comment_count}条评论

    加载更多

  • #{ahtml}#{created_at}

    #{content}

    展开

    #{like_count} #{dislike_count} #{reback} 回复

  • #{ahtml}#{created_at}

    #{content}

    展开

    #{like_count} #{dislike_count} 回复

  • 关闭
      广告