import calendar


def toUnixSeconds(timestruct):
    """Convert a datetime struct to a Unix timestamp in seconds.

    :param timestruct: A ``datetime.datetime`` object to convert into a
        timestamp in Unix Era seconds.
    :rtype: int
    """
    return calendar.timegm(timestruct)