  In this paper, we study the maximum number of limit cycles for the piecewise
smooth system of differential equations $\dot{x}=y, \ \dot{y}=-x-\varepsilon
\cdot (f(x)\cdot y +{\rm sgn}(y)\cdot g(x))$. Using the averaging method, we
were able to generalize a previous result for Li\'enard systems. In our
generalization, we consider $g$ as a polynomial of degree $m$. We conclude that
for sufficiently small values of $|\epsilon|$, the number
$\left[\frac{n}{2}\right]+\left[\frac{m}{2}\right]+1$ serves as a lower bound
for the maximum number of limit cycles in this system, which bifurcates from
the periodic orbits of the linear center $\dot{x}=y$, $\dot{y}=-x$.
Furthermore, we demonstrate that it is indeed possible to achieve such a number
of limit cycles.
