You might think the adhesive would fail but it is unlikely.

Flooring adhesive, for example, can be permanently bound given proper application and even very wet conditions.

There are also no restrictions on using non-adhesive based flashings for windows and doors.

Codes allow for the use of metal, vinyl, and fabric based flashings that can be stapled or nailed into place and these are generally much cheaper than self-adhereing types.