Let $P$ be a principal $U(1)$ bundle over a complex manifold $M$, and let $\rho\colon U(1)\to Aut(\mathbb{C})$ be the representation of $U(1)$ on $\mathbb{C}$ given by the standard multiplication. My question is: when is the complex, rank-one, vector bundle $L = P\times_{\rho} \mathbb{C}$ associated to $P$ an holomorphic line bundle? Or in other words: what conditions do the local transition functions of $P$ have to satisfy in order for $L$ to be an holomorphic line bundle?
Thanks.