Two of Australia’s biggest retailers have agreed to a merger as tough retail conditions continue to cut into the sales of both companies.