When you unlock or unlock the trunk, do the doors locks function at all. If not, then the actuator for the trunk is bad or the linkage is out of order. The alarm will go off when the trunk is opened and the light circuit is closed. it is not slaved to the vacuum system. From what you describe, the problem sounds like it is located in the actuator for the trunk. On the 300e, the trunk should lock and unlock all other locks in the vehicle. if it is not doing that, then either the actuator or a check valve is out of order.
1987 BMW 325