haxelib: Handle command line arguments appropriately

Fixes #2242
Merge pull request #2306 from tkawachi/patch-1

haxelib: Handle command line arguments appropriately