This work proposes a sliding mode control barrier function to robustly deal with high relative-degree safety constraints in safety-critical control systems. Stability/tracking objectives, expressed as a nominal control law, and safety constraints, expressed as control barrier functions are unified through quadratic programming. The proposed control framework is numerically validated considering a Furuta pendulum and a magnetic levitation system. For the first system, a linear quadratic regulator is considered as a nominal control law, and a safety constraint is considered to guarantee that the pendulum angular position never exceeds a predetermined value. For the second one, a sliding mode controller is considered as a nominal control law and multiple safety constraints are considered to guarantee that the magnetic levitation system positions never exceed predetermined values. For both systems, we consider high relative-degree safety constraints robust against model uncertainties. The numerical results indicate that the stability/tracking objectives are reached and the safety constraints are respected even with model uncertainties.