Gluing oriented manifold along boundaries Let $M_1$ and $M_2$ be oriented manifolds with boundaries. Suppose they have homeomorphic boundaries. I want to glue $M_1$ and $M_2$ along the boundaries via some homeomorphism. To ensure that the resulting space is again an oriented manifold, I think I need to take an orientation reversing homeomorphism between boundaries.
So let $f:\partial M_1 \to \partial M_2$ be a homeomorphism. 
My question is that:should $f$ be an orientation preserving with respect to the induced orientation on the boundaries? Or can we choose any orientations on the boundaries so that $f$ is orientation reversing with respect to the choice of the orientations of the boundaries?
Thank you.
 A: The resulting object will be (assuming everything's compact, say...) an orientable manifold, but not an oriented one. If you want it to be oriented, with the orientation matching that of $M_1$, say, then the map $f$ should be orientation reversing (which may not be possible without reversing the orientation on $M_2$, and hence the induced orientation on $\partial M_2$).
If you think hard about two unit disks in the plane, joined to make a sphere, you'll see what I mean.
post-comment edits
A manifold $M$ is a topological space $X$ together with a (maximal) atlas $A$ that satisfies certain rules that are well-known to the questioner, so I won't write them out. An oriented manifold is the same thing, together with a subset $S$ of the atlas that consists of charts that are declared to be "orientation preserving" (and which, when they have overlapping domains, satisfy something that's the equivalent (in the smooth case) of the transition function's derivative having positive determinant on the overlap).
To any oriented manifold, $(X, A, S)$ there's an associated manifold $(X, A)$ gotten by ignoring the orientation.
If we glue oriented manifolds $M_1$ and $M_2$ together as in the question and if their boundaries are each connected and $f$ is an orientation-reversing homeomorphism between them, then $M = M_1 \cup_f M_2$ is orientable, and indeed, the orientation can be made consistent with that of $M_1$ and $M_2$, in the sense that both $M_1$ and $M_2$ are embedded in $M$, and the embeddings are orientation-preserving. The glued up manifold is orientable, but until we pick an orientation, it's just a manifold! And the homeomorphism class of that manifold is independent of the orientations of $M_1$ and $M_2$. That's the claim that Michael Albanese, in the comments, seems willing to believe. Let's look at the orientation preserving case now.
If $f$ happens to be orientation-preserving, then we can reverse the orientation on $M_2$ to get a different oriented manifold, $M_2'$, and a map $f' : \partial M_1 \to \partial M_2': x \mapsto f(x)$ which is exactly the same as $f$, except that the target oriented-manifold is now $M_2$ with the other orientation. Note, too, that $M_2'$ and $M_2$ are homeomorphic as manifolds, by the identity map, but are not necessarily homeomorphic by an orientation-preserving homeomorphism.
If we now build $M' = M_1 \cup_{f'} M_2'$, it's homeomorphic to $M$, but not necessarily oriented-homeomorphic. It's orientable, and with the right orientation, we find that $M_1$ and $M_2'$ are both embedded in it by orientation-preserving embeddings.
On the other hand, it's not true that $M_2$ is embedded in it by an orientation-preserving embedding.
What IS true is that $M_2$ is embedded in it as a topological submanifold-with-boundary.
In the case Michael asked about, where $\partial M_1 = \partial M_2 = S^3$, and $M_1$ and $M_2$ are both $\Bbb CP^2$,  we get that
$$
M' = \Bbb CP^2 \# \overline{\Bbb CP^2}
$$
where the "equality" here is an orientation-preserving homeomorphism (basically just "inclusion"). But it's also true that $M'$ is homeomorphic (again by inclusion) to
$\Bbb CP^2 \# \Bbb CP^2$, by a non-orientation-preserving homeomorphism.
