  We develop an extension of \textit{the Halo Model} that describes
analytically the corrections to the matter power spectrum due to the physics of
baryons. We extend these corrections to the weak-lensing shear angular power
spectrum. Within each halo, our baryonic model accounts for: 1) a central
galaxy, the major stellar component whose properties are derived from abundance
matching techniques; 2) a hot plasma in hydrostatic equilibrium and 3) an
adiabatically-contracted dark matter component. This analytic approach allows
us to compare our model to the dark-matter-only case. Our basic assumptions are
tested against the hydrodynamical simulations of Martizzi et. al. (2014), with
which a remarkable agreement is found. Our baryonic model has only one free
parameter, $M_{\rm crit}$, the critical halo mass that marks the transition
between feedback-dominated halos, mostly devoid of gas, and gas rich halos, in
which AGN feedback effects become weaker. We explore the entire cosmological
parameter space, using the angular power spectrum in three redshift bins as the
observable, assuming a Euclid-like survey. We derive the corresponding
constraints on the cosmological parameters, as well as the possible bias
introduced by neglecting the effects of baryonic physics. We find that, up to
$\ell_{max}$=4000, baryonic physics plays very little role in the cosmological
parameters estimation. However, if one goes up to $\ell_{max}$=8000, the
marginalized errors on the cosmological parameters can be significantly
reduced, but neglecting baryonic physics can lead to bias in the recovered
cosmological parameters up to 10$\sigma$. These biases are removed if one takes
into account the main baryonic parameter, $M_{\rm crit}$, which can also be
determined up to 1-2\%, along with the other cosmological parameters.
