USe correct -[x]platform options and create index with correct ranlib