Defining a constant via a function provided by another module?
You can use the standard global keyword provided by PHP. This is better placed somewhere early in a page load. One that I can think of is hook_menu or hook_init.

Personally though I would strongly recommend to use the variable_get() function provided by Drupal.