开发者

Cross platform autorun

I am writing a program in qt that will be installed on a flash drive. I need it to run on several operating s开发者_如何学Cystems as soon as it is plugged in. I was thinking I could do this by putting all of the different os compiles in separate folders and having the autorun for each os in the first part of the drive. Would this work? It is supposed to be somewhat like sandisks u3 in the fact that it pops up as soon as it is plugged in and runs off the drive.


It would certainly work - basically each autorun configuration file is OS specific, and you can specify exactly which executable to run on plug-in.

The Sandisk U3 platform is a rather devious trick around a typical Windows setting, which forbids autorun from a flash device, but allows it nonetheless on an CDrom drive. U3 device has two partitions, one of which (around 16MB) holds an ISO image, that, together with the special USB controller, gets recognized as an optical drive.

If you can get a hand on one of those drives, they can be reprogrammed to do anything else you want.


I had a friend that fixed an auto-sync script on his thumb drive.

On Windows it basically boils down to a single AutoRun.inf file.

On other platforms, I don't know. On Linux, it will probably depend on Desktop Environment and security settings.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜