I have a layer that I want to merge and I want the dark colors in the layer to have more weight. How can I make it so that black pixels are 100% opacity, white pixels are 0%, and #7F7F7F pixels are 50%? I tried adjusting color curves, but that doesn't seem to be what I want.
I'd decompose the image two times, once into RGBA and once into HSV or HSL, with the Decompose filter: http://docs.gimp.org/en/plug-in-decompose-registered.html
Then, I'd do a RGBA compose with the RGB components taken from the first, and the V or L component (inverted prior to the compose, probably) of the second decompose for the A component: http://docs.gimp.org/en/plug-in-compose.html
An easy way to add transparency in Gimp is to convert a color to alpha by choosing Layer > Transparency > Color to Alpha.
In your example choosing white as the color to convert to alpha (i.e. is fully transparent) will lead to the desired result making black 100% opaque, white 0 % opaque (i.e. transparent), and giving all shades of grey a corresponding semi-transparency: