Indeed, one of the primary ways the federal government was to be funded was through taxes on imports, which implies the existence of a customs function at the border. Do you think the framers envisioned a customs system that couldn't enforce its tariffs without getting a court order to search incoming ships? They obviously didn't envision that, because one of the first things Congress did was to set up the framework for warrant-less customs searches.
Do you know what, if any, limits are placed on border searches? Is literally anything "reasonable" there, or are the limits just different?
Re: border searches, I'm not well-versed so I'll just point you to the wikipedia page: http://en.wikipedia.org/wiki/Border_search_exception. Long story short, it still has to be reasonable, it's just that the bar is lowered because you should expect to get searched at a border.