We perform a full analytical and numerical treatment , to the first post-Newtonian ( 1pN ) order , of the general relativistic long-term spin precession of an orbiting gyroscope due to the mass quadrupole moment J _ { 2 } of its primary without any restriction on either the gyro ’ s orbital configuration and the orientation in space of the symmetry axis \boldsymbol { \hat { k } } of the central body . We apply our results to the past spaceborne Gravity Probe B ( GP-B ) mission by finding a secular rate of its spin ’ s declination \delta which may be as large as \lesssim 30 - 40 \mathrm { milliarcseconds per year \left ( \mathrm { mas yr } ^ { -1 % } \right ) } , depending on the initial orbital phase f _ { 0 } . Both our analytical calculation and our simultaneous integration of the equations for the parallel transport of the spin 4-vector S and of the geodesic equations of motion of the gyroscope confirm such a finding . For GP-B , the reported mean error in measuring the spin ’ s declination rate amounts to \sigma ^ { \mathrm { GP - B } } _ { \dot { \delta } } = 18.3 \mathrm { mas yr } ^ { -1 } . We also calculate the general analytical expressions of the gravitomagnetic spin precession induced by the primary ’ s angular momentum \boldsymbol { J } . In view of their generality , our results can be extended also to other astronomical and astrophysical scenarios of interest like , e.g. , stars orbiting galactic supermassive black holes , exoplanets close to their parent stars , tight binaries hosting compact stellar corpses .