  For fixed graphs $F$ and $H$, the generalized Tur\'an problem asks for the
maximum number $ex(n,H,F)$ of copies of $H$ that an $n$-vertex $F$-free graph
can have. In this paper, we focus on cases with $F$ being $B_{r,s}$, the graph
consisting of two cliques of size $s$ sharing $r$ common vertices. We determine
$ex(n,K_t,B_{r,0})$, $ex(n,K_t,B_{r,1})$ and $ex(n,K_{a,b},B_{3,1})$ for all
values of $a,b,r,t$ if $n$ is large enough.
