[GUIDE] How to package apps for My Cloud Pro Nas on a 64bit platform

Most of the steps are explained in http://developer.mycloud.com/MCDSDKindex.html
However to create the package you must use mksapkg, a 32bit binary :cry: (2017 says hello)

This is a crossplatform workaround:

  • download and install Vagrant
  • install this 32bit centos box
  • copy mksapkg to the shared vagrant directory (same dir as the Vagrantfile)
  • vagrant ssh
  • mv /vagrant/mksapkg /usr/local/bin

Now you can create packages if all required files are present in the directory

[vagrant@localhost myproject]$ ls
apkg.rc    clean.sh  install.sh  remove.sh  stop.sh  web
build.sh   init.sh   preinst.sh  start.sh
[vagrant@localhost myproject]$ mksapkg -E -s -m MyCloudPR4100

I made a build.sh script as I hate typing this whole command.

Edit: as with any info that’s not from the official sources, use at own risk.


Thanks for sharing. Make sure to add a disclaimer to let the user know that they will be doing this at their own risk.

mksapkg.pdf (15.5 KB)

As the OS3 developer website is gone, here is the mksapkg file again, disguised as a PDF to allow upload to this forum.

mv mksapkg.pdf mksapkg
chmod +x mksapkg

You don’t need vagrant / centos.
On Ubuntu 16.04 - 64bit, I just needed this:

apt-get update
apt-get install libxml2:i386

This setup is much faster and lighter.

Thanks, @Tfl ! I had the packages for a development environment when I first bought my PR4100 but didn’t have the time. Now that I have the time (well, not really :stuck_out_tongue:), WD seems to have killed 3rd party development (not that they were ever that supportive to begin with). Your Docker CE release has actually made the appliance 1000x more useful, however, there are a couple of application (duplicati, ps3netsrv, etc) that I would like to try and compile into a native package to cut down on resource use (also “just because™”).