I've done this via footprints. Make a custom footprint for the structure that can allow pathing through it. Or, change the mover for the unit that is trying to pass through. ie: change the mover from ground to colossus or burrow.
They must be used in tandem with collision flags located in the unit object.
These are only two ways off the top of my head, several more exists. For instance, do you really need an actual building, or can you use a doodad without a footprint at all.
To allow certain units through, you need to look at the collision flags field in unit object. Footprint pathing only allows pathing. They must be used together to do what you want. Don't change the mover for the unit unless you have to or unless it makes more sense to do so per your specific goals; it will cause relational problems with other units and pathing.
Also, there is a radius field in unit objects. One of the radius fields is related to structural collisions.
To allow for units to go through my structure I've changed its pathing footprint from a 2X2 to the 2X2 (Underground) footprint. The units I want can pass through the structure now, but so can all other units. Even when the structure is set to collide with ground units and the units I want to collide with the structure are ground movers they still can walk through.
After diving deeper into the Footprint layer editor I was able to solve my problem by decreasing the collision radius of my specific units and then making specific passable slits in the structure's footprint so that the small collision units can walk through. This is how my footprint layer map looks like: http://i.imgur.com/4BKbQ0g.png