We study the dynamics of pattern formation of two-dimensional smectic systems constrained to lie on a substrate with sinusoidal topography. We observe a coupling between defects and geometry that induces the preferential location of positive (negative) defects onto regions with positive (negative) Gaussian curvature. For the curvatures studied here we observe unbinding and self-organization of disclination pairs. The local orientation of the pattern and the location of topological defects can be accurately controlled with the curvature of the underlying substrate. Thus, long-range interactions arising from the geometry of the substrate lead to ordered patterns with potential applications to nanotechnology.