  On a compact manifold $M$ with boundary $\partial M$, we study the problem of
prescribing the scalar curvature in $M$ and the mean curvature on the boundary
$\partial M$ simultaneously. To do this, we introduce the notion of singular
metric, which is inspired by the early work of Fischer-Marsden in [18] and
Lin-Yuan in [23] for closed manifold. We show that we can prescribe the scalar
curvature and the mean curvature simultaneously for generic scalar-flat
manifolds with minimal boundary. We also prove some rigidity results for the
flat manifolds with totally geodesic boundary.
