Move the stop_packages code to a function, and call the function from the shell script, and call the function directly for a reboot. Fixes #2402 and ticket #1564
Rework rc.stop_packages a little. Fixes #1564
Ticket #1564. Give +x to the script so it can be executed. Simple hah :)
fix typoes
Fix array parsing of rc files. Resolves #1541
Restore running custom scripts under /usr/local/etc/rc.d directory since it causes regressions and its a feature used by many users.
Ticket #1534. Change rc.start_packages and rc.stop_packages to php scripts so they do a proper job at start/stop packages, rather than assume every package has a .sh script which is not true. It mostly reuses code from rc.packages which is not used anywhere as of now!