To build a starpack you need a) a tclkit runtime, b) sdx.kit. You also need a "basekit", the executable that will be wrapped with your tcl code. For this example I'll assume you're creating an application for the same platform you are running on. You can create a basekit by simply copying tclkit (or tclkit.exe on windows) to another name, such as "basekit"
% ls
sdx.kit tclkit
% cp tclkit basekit
% ls
basekit sdx.kit tclkit
Now, create the code that you want to have wrapped into an executable. The convention is to create a directory with the name of your app and the suffix ".vfs" (for 'virtual file system'), then create a file named 'main.tcl' in that directory:
% mkdir myapp.vfs
% cat > myapp.vfs/main.tcl
package require Tk
label .l -text "Hello, world"
pack .l
^D
% ls myapp.vfs
main.tcl
Now to do the wrapping: for this you'll need the sdx.kit file. Assuming it and tclkit (or tclkit.exe) are in your current working directory, you wrap your app like this:
% ./tclkit sdx.kit wrap myapp -runtime basekit
1 updates applied
% ls
basekit myapp myapp.vfs sdx.kit tclkit
The wrap command knows when you give it the argument "myapp" that it should wrap the contents of myapp.vfs, and that it should look for a file named "main.tcl" in that directory to be the program entry point. You can put whatever other files you want in that directory and they will all be wrapped, including platform-specific binary files, image files and anything else you want bundled up.
You now have an executable file, 'myapp', that is the wrapped application.
If you have the tclkits for different architectures you can use them (replacing 'basekit' on the command line with the kit for the target architecture) to cross-compile for other platforms.
For more information see How to create my first Starpack on the Tcl'ers Wiki