Combine sugar and water in a saucepan and bring to a boil. Add cranberries and bring back to a boil. Reduce heat and simmer for 10 minutes, stirring occasionally. Ladle hot relish into pint jars leaving 1/4 inch headspace, put the lid on and adjust the ring on top. Process in boiling-water canner for 10 minutes.