Running a command line bitcoin CPU miner on ubuntu for slush's pool
I suggest to use one of the updated cpuminer versions which support more than one algorithm. This way you are also set up to mine different coins which use other PoW functions. The most versatile one is tpruvot's fork:cpuminer-multi. For me this one worked out of the box on a recent Ubuntu 14.04 installation.

The syntax is similar to all other cpuminer versions:
cpuminer -a sha256d -o stratum+tcp://pool.com:port -O username.workername -p password