Fry the onion and the ham in some olive oil