Turkey's government has dismissed several thousand police, ministry staff and academics a day before the anniversary of last year's failed military coup.