I remember reading a book around 10-12 years ago about a crew on a spaceship which was in danger of crashing into a either a black-hole or a white dwarf / some other star. The book was semi-humorous in tone, with some comedic characters, but I remember there being some fairly brutal murders (or at least to my young mind they were)
The main plot elements I can remember are:
The ship is constructed in Antarctica, possibly using a space ladder
The ship is able to react to damage it receives (can repair a bullet hole in glass) and is possibly called the Mayflower or Mayflower II
The main character is incapacitated in some manner just after the ship departs, and wakes up several decades after the original flight, so all the members of the crew are different, and slightly mad from being in space their entire lives (and reduced gene pool?)
The ship is a wreck, with several engines stopping working and them due to crash
People on board the ship begin to be killed off, possibly due to a rogue robot on board killing people
At the end, the ship repairs itself and saves all those aboard, due to it's semi-sentience(?)
This is "Colony" by Rob Grant, published in 2000. The book is a comedy/science-fiction novel by the co-creator of Red Dwarf.
The ship (the Willflower) is being constructed by "The Project" at the South Pole.
The energy required for take-off would split the planet in two. So
it's being put together in orbit above the point of least spin: the
It's tethered to the drowning Earth by the tallest structure in human
history: the Hoist. The Hoist -- or, more romantically, the Stairway
To Heaven -- is a giant elevator that ferries supplies and personnel
to and from the ship.
They're going to crash into a massive gas-giant
The ship is way off where Eddie expected it to be. Closer to the
planet. Far too close. The massive pull of the gas giant is dragging
the Willflower off course towards it. 'And in ninety-six hours...'
The Willflower has gone.
The main character is incapacitated after launch and is revived (as a head in a jar) some time after the launch.
The ship is indeed a wreck.
The main antagonist is a professional hitman paid to kill the hero, revived in the future using the same "head in a jar" technology and driven mad. He spends much of the latter part of the novel attempting to kill the crew (hat tip to @JamesSheridan)