proxytoworld
V2EX  ›  问与答

VS2017 怎么在一个项目里面生成多个 DLL,刚接触 dll 编写,现在只知道一个生成一个 dll 项目产出一个 dll,不知道有没有办法一个项目生成多个 dll 呢?

  •  
  •   proxytoworld · Mar 15, 2021 · 1175 views
    This topic created in 1890 days ago, the information mentioned may be changed or developed.
    6 replies    2021-03-16 11:16:40 +08:00
    lcdtyph
        1
    lcdtyph  
       Mar 16, 2021 via iPhone
    你需要 solution,每个 solution 包含多个相互联系的项目,每个项目产生一个 dll
    ysc3839
        2
    ysc3839  
       Mar 16, 2021
    不行,可以新建多个项目,然后都添加到同一个“解决方案”下。
    ReferenceE
        3
    ReferenceE  
       Mar 16, 2021 via Android   ❤️ 1
    每个 dll 代码拆分成一个项目 project
    然后导入到同一个解决方案 solution (.sln)中即可
    参考微软文档概念
    A solution is simply a container used by Visual Studio to organize one or more related projects. When you open a solution in Visual Studio, it automatically loads all the projects that the solution contains.
    imjamespond2020
        4
    imjamespond2020  
       Mar 16, 2021 via Android
    可以用命令行啊 写个 makefile 开搞
    kiracyan
        5
    kiracyan  
       Mar 16, 2021
    你搞清楚 solution 和 project 就知道怎么操作了
    proxytoworld
        6
    proxytoworld  
    OP
       Mar 16, 2021
    @lcdtyph
    @ysc3839
    @ReferenceE
    现在是一个解决方案多个项目,一个项目一个 dll,看来没办法一个项目多个 dll
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   1019 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 59ms · UTC 22:27 · PVG 06:27 · LAX 15:27 · JFK 18:27
    ♥ Do have faith in what you're doing.