As mentioned by Warrent Hill, Execute command before shutdown/reboot is the way to do it. Create a script under /etc/init.d/shutdown_google_drive.sh and add softlinks as required in rc6.d.
However, if the synchronization may take over 60 seconds (I'm pretty sure this is the default timeout,) then it won't work because the shutdown process has a watchdog and a script that takes too long is simply stopped (as in killed) and the shutdown process moves on.
To make sure you do not lose data, you may consider using shutdown -c
in your script (I would think it's possible) and let the user know that the shutdown was cancelled in the event your sync-ing is taking too much time.