As far as i know, referencing other works shouldn't be a problem. It's a common thing after all to list references in books that have served as inspiration. However, using the distinct names present in some systems, such as Gelatinous Cube or Otilukes Freezing Sphere, from d&d in a published work and then giving a product reference, may be problematic.
If you really wish to publish a systemless resource, i personally think that you'd be better off by describing things such as beasts, spell effects etc in generic terms. This leaves it up to the reader to convert the descriptions to the system that they are using and also relieves you of any worries about legal responsibility.