My Smart Mailboxes would not work either. I have 4 Gmail Accounts, 3 Pop3 email accounts and 2 Exchange Server email accounts on my iMac with Yosemite. All worked fine before I upgraded.
Before I tried any of what I thought were more advanced changes in some of these threads above, I found this solution elsewhere on the web. Once I did this, all my Smart Mailboxes came back to normal.
1: On the Email Menu, Go to Mail Preferences > then click on the Advanced Tab.
2: For every email account listed, uncheck the first checkbox titled: "Automatically detect and maintain account settings"
3: Close Email, then Open Email again.
After this change all Smart Mailboxes were normal.
It also fixed my Spotlight email search that was not working as well. After I re-indexed my HD, email search still would find no results. Doing the 3 steps above now results in normal email searches.
Hope this helps some others with this issue.