The derivation of this word as meaning magic generally, or more specifically black magic runs thusly:

Magical practices often involved summoning or talking with the dead. The dead are dead, except as raised to eternal life by God, so this is impossible. Hence, anyone speaking to the dead must be being deceived by demons. Hence, necromancy is, de facto demonological black magic. This meaning came to be widely applied.

Mainly practiced by priests, as to do this stuff you needed to be able to read and speak funny old languages. They had the incentive as being ordained did not guarantee being employed by the Church. Each church was responsible for getting its own clerics. Unfortunately, supply rather outstripped demand, so priests had to turn to unsavoury practices.

Source: Magic in the Middle Ages, Richard Kieckhefer, Cambridge University Press