How can I add a class to #markup output?
You can do this...

$form['actions']['cancel'] = array(
    '#markup' =&gt; l(t('Cancel'), $destination, array('attributes' =&gt; array('class' =&gt; array('cancel')))),
    '#weight' =&gt; 20,
  );


The third argument on the 'link' function is for attributes and such...

l($text, $path, array $options = array())


Documentation: http://api.drupal.org/api/drupal/includes%21common.inc/function/l/7