One question: is there a mod that implements better defenses?
There are mods with indestructible walls but vanilla already has indestructible objects like stairs and stone benches that you can already use for this purpose.
Like automatic turrets or trap crossbows?
Nope. Unless you count overpowered ranged NPCs used like "turrets". But you can do it in vanilla anyway with Native Women equipped with bows. And Laser Androids (androids built with the Type C head). For AoE you can use Sadako (Elite Underground Woman).
You can build dedicated archer/laser/artillery towers (hint: stick the appropriate ranged NPC in a raised platform with a fence enclosing them, the same fence used to tame animals), but this is done mostly for looks and is more trouble than it's worth.
I can't build walls fast enough in normal gameplay,
You should have more than enough time to build walls unless you're trying to build them in the middle of a raid. Which you can also do with the game paused but they won't snap to each other properly. Still useful in a pinch in emergencies though.
If you're talking about the very early game, just spam like around 10 wooden spikes near the starting bonfire and leave an entrance/exit to the south. Heck, you have a lot of time before the first scout party spawns and even if you dilly-dailly around only 3 doods will spawn in. Even if they spot you and they summon a raid you only need to deal with 5~6 guys.
Unless you cheat in hundreds of levels without familiarizing yourself with the basics of the game (raider number scales with combined character levels), but that's on you for, to use the adage, running without learning how to walk first. Restart the game and play without level/XP cheats first.
Anyway, worse come to worse you can also duck into a cave to wait out a raid. You can also build a thatched house (the most basic of houses) and hide in that.
and the spikes don't do enough damage to the big enemies.
Cactus Walls (800 HP, reflects 100% of received damage) can be considered upgrades to the basic Wooden Spikes. They only require cacti to craft and are enough to cause most raids to self-destruct on them unless you are challenging raids with levels boosted to hundreds or above.