If you have an e30 323 or 325 you can do a cheap and easy swap to get a 2.7 litre engine.
You just need the crank, pistons, conrods and a cylinder head from a few old bm's... in brief
Get the crank from a 324d/td, 524d/td or 525e. Conrods from a 2.0, 2.3 or 525e.
Where it gets a little difficult is the pistons and cylinder heads, it all depends on what u started with and what u want to use. e30zone has the full details.
E36, you can get the 325 rebored to 3.2, but it would just be cheaper to buy an m3. There is some talk of a 328 to 330 but nobody has done it yet.
However if you have an e46, no news on part swaps yet.
Good luck with yr search.