fix build: duplicate define
Update: STE
Fixed ifdef and endifs