It's a side effect of the weight of the atmosphere. So you can see that weather mostly controls pressure, and not the other way around. This lifting effect is why pressure drops before a storm, also because storms themselves suck air up and away from the ground. As the front lifts the air ahead of it, clouds form (air cools as it gets higher in the atmosphere because it decompresses with altitude) and you get rain, storms, etc. High pressure systems move down from the north (or up from the south in the southern hemisphere) and push into regions of warmer, moister air, forcing that air up the leading edge of the colder mass of air, exactly like a bulldozer blade. But weather systems are the main factor driving air pressure.
Cold air is dense and tends to move downward in the atmosphere, creating more pressure at the surface. The influence of temperature is pretty simple: warm air is less dense and tends to rise, reducing pressure at the surface because the air weighs less. It is driven by two things, weather systems and temperature. Air pressure is a result of the weight of all the air above you in the atmosphere, much like the pressure at the bottom of the ocean is a result of the weight of the water.
It's measured in either inches of mercury (how far mercury can be driven up a J-shaped tube with a vacuum at one end and open at the other) or hectopascals, which is the SI unit for air pressure. So, "barometric pressure" is simply a fancy way of saying "air pressure".