Counting flux vacua