Have a look at the port's Makefile. Usually the switch is just an ".if defined(SOMEVARIABLE)", meaning if it exists, if that's the case it's value doesn't really matter. Other options like USE_GECKO do matter which value they're set to. Most of the stuff beginning with WITH_ or WITHOUT_ just need to be set.
There's a bunch of "standard knobs" you can test for if you create your own port, have a look at /usr/ports/KNOBS.