Look into using the Surface Deformer. You can use this directly on a spline object. Make sure that the Spline is using an appropriate intermediate points mode that will give the spline sufficient detail to deform with the cloth (Natural is my go to in this situation, but Uniform with a high number value can work as well). However, if you extrude the spline from its deformed state the direction of the extrusion will still be in world space and won’t reflect the cloth deformation.
If you’re looking to deform the extrusion with the cloth then the setup gets a little more complicated. First you’ll need to prepare the extrusion for deformation.
Subdivide the Caps of the Extrude NURBS object under the ‘Caps’ tab. Using quadrangles in a regular grid is appropriate here.
Then place the Extrude NURBS in a Connect object with an appropriate weld setting (to attach the caps to the extrusion) and phong setting.
Finally put this Connect object inside a Null object. Place your Surface Deformer in the Null object at the same level as the Connect object.
The details of the Surface Deformer are covered pretty well in the C4D help but if you need assistance please post back!
Darby Edelen