Context : Over 30 planetary systems have been discovered to reside in binary stars . As some of the binary separations are smaller than 20 astronomical units ( AU ) the gravitational perturbation of the secondary star has a very strong influence on the planet formation process , as it truncates the protoplanetary disk , possibly shortens its lifetime , and stirs up the embedded planetesimals . Due to its small semi-major axis ( 18.5 AU ) and relatively large eccentricity e = 0.35 the binary star \gamma Cephei represents a particularly challenging example worthy of study in greater detail . Aims : In the present study we model the orbital evolution and growth of embedded protoplanetary cores of about 30 earth masses in the putative protoplanetary disk surrounding the primary star in the \gamma Cep system . Methods : We assume coplanarity of the disk , binary and planet and perform two-dimensional hydrodynamic simulations of embedded cores in a protoplanetary disk perturbed by a secondary companion . Before embedding the planet , the equilibrium structure of the disk for the observed binary parameters of \gamma Cep is determined . We initiate the embedded planets in the disk on circular orbits with different initial distances from the primary . Results : The presence of the eccentric secondary star perturbs the disk periodically and generates strong spiral arms at periapse which propagate toward the disk centre . The disk perturbations then weaken as the secondary approaches apoapse . The disk also becomes slightly eccentric ( e _ { disk } \approx 0.1 - 0.15 ) , and displays a slow retrograde precession in the inertial frame . Embedded cores interact with the eccentric disk , are periodically disturbed by the strong spiral shocks , and also by the eccentric binary . We find that their eccentricity evolution depends primarily on the starting position in the disk . For all initial separations ( from 2.5 to 3.5 AU ) we find inward migration of the cores . For initial semi-major axes a _ { p } \raisebox { -2.58 pt } { $ \stackrel { { \displaystyle > } } { \sim } $ } 2.7 , however , we find a strong increase in the planetary eccentricity despite the presence of inward migration . Only cores which are initially far from the disk outer edge ( a _ { p } \raisebox { -2.58 pt } { $ \stackrel { { \displaystyle < } } { \sim } $ } 2.7 AU ) have a bounded orbital eccentricity which converges , after mass accretion , roughly to the value of the planet observed in the \gamma Cep system . Conclusions : Even though a close binary system such as \gamma Cep still presents a challenge to planet formation theory , we have shown that under the condition that protoplanetary cores can form at around 2.5 AU , it is possible to evolve and grow such a core to form a planet with final configuration similar to that observed .