WDMC gen2 - How to build some packages?

Hi, all…

I read a fantastic post of Fox_exe… (“WD MyCloud Gen2 - Enable apps install tab + Apps!”)
thx, Fox_exe… :slight_smile:

now… I’m wondering how to build a package with .bin suffix after compiling source codes…

for example, i wanna use htop command on WDMC gen2…
however, i have not found a way to create(or compile) an executable file from source code for WDMC gen2…

how could i do for it???
could i get some points???

thx in advance…

Hi, take a look here: WD MyCloud Gen2 - Enable apps install tab + Apps! - #62 by Fox_exe and here too High-Performance SSDs, HDDs, USB Drives, & Memory Cards | Western Digital

Those bins are just zips with custom/signed header.

Thx for your advice…
and sorry… I think my post is not clear…

I’ve already visited these links that hashashin proposed…
However, I understood that these posts describe how to repack the bin package created already by WD for wdmc gen2…

So I want to know how to compile the source code to make my own package…

of course, I also failed to create a complete .bin package with executable file (performed well on wdmc gen2) and script files (apkg.rc, install.sh, start/stop.sh and so on)…
In fact, the bin package was created normally, but the installation was not successful… :sob:

But now, I am more curious about how to make(compile) the executable file from source codes for wdmc gen2 rather than creating a complete bin package…

plz, let me know what can I do for it~ :wink:

Thx again…

Download “GPL Source codes” from WD website:

Inside this archive you can find all scripts for build base system (Package-by-package).
Its good start point for understand how to build packages for linux.
Also you can read “How to build software from scratch” and “Cross compile” for RaspberyPI (Its almost fully compatable with our device).

1 Like

IT’S MY MISTAKE…
After cleaning everything all, my building process was successfully… :heart_eyes:

Best regards…


Thanks for your guide, Fox_exe…

Compared to the previous gen1, it’s too hard to build a package from scratch… :dizzy_face:

At first, I downloaded the GPL Source Code having same version for my device(v2.21.119).
I installed Debian v8.7.1 32bit in my virtual box, and then built the cross-compile environment…

As a test, I compiled an rsync program that seems to be the simplest, moved it to my WDMC and executed it successfully. :grinning:

I choiced the nano program in Open_Source_packages for the second try…
However, the following error has occurred when building with “–enable-utf8”:

[The error part is quoted (full messages is attached) ]
(snipped)
configure: WARNING:
*** No curses lib available. Consider getting the official ncurses
*** distribution from ftp://ftp.gnu.org/pub/gnu/ncurses if you get
*** errors compiling nano.
checking for use_default_colors in -l… no
configure: error:
*** UTF-8 support was requested, but insufficient UTF-8 support was
*** detected in your curses and/or C libraries. Please verify that your
*** slang was built with UTF-8 support or your curses was built with
*** wide character support, and that your C library was built with wide
*** character support.
make: *** No targets specified and no makefile found. Stop.
make: *** No rule to make target ‘install’. Stop.

I thought the ncurses first…
then, tried to compile the ncurses, but also got an error.

[The error part is quoted (full messages is attached) ]
(snipped)
arm-mv5sft-linux-gnueabi-gcc -DHAVE_CONFIG_H -I…/ncurses -I. -I. -I…/include -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -DNDEBUG -I/home/roy/DNS-345_GPL/packages/ncurses-5.7/_install/include/ncurses -O2 --param max-inline-insns-single=1200 -c …/ncurses/./tty/hardscroll.c -o …/objects/hardscroll.o
make[1]: arm-mv5sft-linux-gnueabi-gcc: Command not found
Makefile:680: recipe for target ‘…/objects/hardscroll.o’ failed
make[1]: *** […/objects/hardscroll.o] Error 127
make[1]: Leaving directory ‘/work/WD_MyCloud_GPL_v2.21.119_20160901/Open_Source_packages/ncurses-5.7/ncurses’
Makefile:98: recipe for target ‘install’ failed
make: *** [install] Error 2

How could I solve these errors? :tired_face:
Thanks in advance…

Best regards,

full_error_messages_for_nano.txt (5.8 KB)
full_error_messages_for_ncurses.txt (119.9 KB)

I’ve almost not trouble using the toolchain and the scripts provided with the gpl sources, follow instructions in “WD_MyCloud_Release_Notes_GPL_v2.21.119_20160901.txt” inside the tar.gz you downloaded from Fox_exe link.

Thanks, hashashin…

I did clean everything all… then, I built it successfully…
I think there may be some mistakes…

from now… I will try to make the .bin package… I’m so excited…

Thx, again…

I’m glad to read that :smiley:
Take a look here if you want some examples: GitHub - hashashin/mycloudapps
I just put there all the ones I’ve mod or created.