A session that has been rotated within its lifetime will be
rotated during its destruction to rename the last trace chunk.
Currently, the liblttng-ctl library's session destruction function
only waits for the data pending to indicate that all data has
been consumed. This used to be sufficient, but it is now necessary
to wait for the implicit session rotation to complete.
The "wait" variant of the session destruction function will wait
for any implicit session rotation to compete. A new
lttng_destruction_handle class is introduced to allow a client to
wait for the destruction of a session and obtain the location of
the last trace archive produced by the implicit session rotation.
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>