If rooting your device is no problem for you, the second approach should be possible also without the SDK -- if you have a terminal emulator such as Android Terminal Emulator installed on your Android device. You could then execute the commands quoted there within the terminal emulator, but probably need to prefix them with the su command (to have them run by root):

your SSID should be replaced with the name of your Adhoc network, and 10.0.0.x is a different IP you give each device.

I didn't test/verify that, but from my Linux knowledge, it sounds quite reasonable. Drawback is, you would need to execute those commands each time you need to establish the ad-hoc connection -- but here some other app could kick in, once you verified the steps are working. One I found is Script Manager - SManager -- but there were some easier ones I just cannot remember at the moment. If this is an acceptable approach to you, I can update my answer and add a few more tools to compensate.

EDIT:

Here's the one I had in mind to make the script-running easier: Scripter