Talking to ATmega 32u4 over USB

Working on a homebrew board with an ATmega32u4 and I installed the Leonardo bootloader using a Dragon AVR programmer over the SPI bus and Atmel studio, which seemed to work. But Windows won't recognize the USB device after pointing it at the Arduino drivers folder, and the Arduino IDE won't even recognize that there is an Arduino on a port. I'm drawing a blank on what could even be wrong in software or firmware. Any help would be appreciated.

Use the Arduino IDE to burn the bootloader, with another Arduino as iSP or a USBasp programmer. The Burn Bootloader function also includes setting the fuses and lock bits. Make sure your crystal is 16MHz.

If you need to troubleshoot, you can upload a sketch via programmer such as the blink sketch and see if the sketch works OK. After you upload a sketch via programmer, you need to Burn Bootloader again.

Finally, make sure your USB cable is good, and not a charge-only cable.

Okay, I'm using an 8MHz crystal and realized I needed to be using the LilyPad USB bootloader instead of the Leonardo. So I tried that and set the fuse bits. Now the problem is that the computer doesn't recognize it as anything, even an unknown USB peripheral. (Before, the behavior was that it would at least recognize that a device was connected). Resetting and power cycling has no effect.

Update: I can confirm that the device configuration is working, from uploading a blink program with the programmer over SPI. So it's really a USB problem, not a microcontroller problem. What's the right place to take this question?

Did you compile and upload the blink program using the Arduino IDE with the LilyPad USB selected as the board? Let's see your schematic. Confirm with a multimeter all the connections through the USB cable to the processor pins is OK, and attached components such as resistors and capacitors are connected OK and the right values.