Output .dll from Rhino plugin V7 template

Hi @stevebaer,

Do you know how I can also output the .dll from the Rhino plugin V7 template? When the solution builds it only outputs the .rhp file but I also need to output the .dll



you could add a post build event to the project to copy the rhp to a dll. Why do you need this by the way?

Hi Steve,

Thanks for the quick reply. How would I change the extension while copying the rhp file? Also,

AfterBuild events like this one dont seem to work:

<Target Name="AfterBuild">
      <SourceDlls Include="$(TargetDir)*.dll" />
      <SourcePdbs Include="$(TargetDir)*.pdb" />
      <SourceRHP Include="$(TargetDir)*.rhp" />
    <Copy SourceFiles="@(SourceDlls)" DestinationFolder="C:\Program Files\Rhino 7\Plug-ins\SyncIO\" />
    <Copy SourceFiles="@(SourcePdbs)" DestinationFolder="C:\Program Files\Rhino 7\Plug-ins\SyncIO\" />
    <Copy SourceFiles="@(SourceRHP)" DestinationFolder="C:\Program Files\Rhino 7\Plug-ins\SyncIO\" />

I had to instead use an XCopy to copy the .rhp file

<Target Name="PostBuild" 

    <Exec Command="xcopy /y /d  &quot;$(ProjectDir)$(OutDir)&quot; &quot;C:\Program Files\Rhino 7\Plug-ins\SyncIO&quot;" />


How can I change the extension of .rhp to .dll in a second xcopy?

I need the .dll as well because I have some code which I need to reference in order to do some integration tests.



It looks like this should work

<Target Name="PostBuild" AfterTargets="PostBuildEvent">
  <Exec Command="copy $(TargetPath) $(OutDir)$(TargetName).dll" />
1 Like

Awesome, thanks!