If you use the template
Spotfire Extension VS.zip, this is done automatically.
To manually build a Spotfire package that can be debugged in Visual Studio,
follow the steps in this topic.
About this task
It is assumed that
the default paths from the template project were used.
<framework> is one of “net48” (.NET Framework) or
“net8.0” (netcore/Linux). The netcore version can be different depending on the
Spotfire version used. To create a package for the installed client, use
“net48”.
Procedure
-
Open a command window and go to the folder where the project file
is stored.
-
You must provide the following arguments to Package Builder
(assuming that the extension is called "Spotfire Extension"). For a full list
of possible argument, see
Package Builder console parameter reference.
/pkdesc:"Spotfire_Extension.pkdesc". This file contains the necessary
information for what must be included in the package.
-
/target:"..\Build\Packages\Spotfire_Extension.spk"
-
/basefolder:"..\Build\bin\<framework>"
/refpath:"..\Build\bin\<framework>;..\..\Binaries\<framework>".
This includes both the path to the extension binaries, and the Spotfire API
binaries.
/saveunpackedmodule. This argument instructs Package Builder to create
an unpacked module structure from the created package. This is needed to debug
in the installed client.
/unpackedmodulefolder:"..\Build\Modules"
/automaticpackageversionnumber. This is not really needed for
debugging purposes, but it will make sure that a new package file is created
without overwriting any earlier created packages.
-
/intendedplatform:<windows or linux>. If
building for Windows, this argument can be omitted because Windows is default.
-
/archiveformat:<cab or zip>. The default
is
cab but when building for Linux it is
recommended to use
zip, because the cab-format requires
installation of the 3rd party package "cabextract" on the Linux server running
web clients or Automation Services.
-
Build the package using one of the following commands:
When building a package for .NET Framework, use:
"..\..\Package Builder\Spotfire.Dxp.PackageBuilder-Console.exe" /pkdesc:"Spotfire_Extension.pkdesc" /target:"..\Build\Packages\Spotfire_Extension.spk" /basefolder:"..\Build\bin\net48" /refpath:"..\Build\bin\net48;..\..\Binaries\net48" /saveunpackedmodule /unpackedmodulefolder:"..\Build\Modules" /automaticpackageversionnumber /intendedplatform:windows /archiveformat:cab
The last two arguments can be omitted in this case.
When building a package for netcore/Linux, use:
"..\..\Package Builder\Spotfire.Dxp.PackageBuilder-Console.exe" /pkdesc:"Spotfire_Extension.pkdesc" /target:"..\Build\Packages\Spotfire_Extension.spk" /basefolder:"..\Build\bin\net8.0" /refpath:"..\Build\bin\net8.0;..\..\Binaries\net8.0" /saveunpackedmodule /unpackedmodulefolder:"..\Build\Modules" /automaticpackageversionnumber /intendedplatform:linux /archiveformat:zip
Results
The package is built.