  The four dimensional gauged supergravities descending from non-geometric
string compactifications involve a wide class of flux objects which are needed
to make the theory invariant under duality transformations at the effective
level. Additionally, complex algebraic conditions involving these fluxes arise
from Bianchi identities and tadpole cancellations in the effective theory. In
this work we study a simple T and S-duality invariant gauged supergravity, that
of a type IIB string compactified on a $T^6/(Z_2 x Z_2)$ orientifold with
O3/O7-planes. We build upon the results of recent works and develop a
systematic method for solving all the flux constraints based on the algebra
structure underlying the fluxes. Starting with the T-duality invariant
supergravity, we find that the fluxes needed to restore S-duality can be simply
implemented as linear deformations of the gauge subalgebra by an element of its
second cohomology class. Algebraic geometry techniques are extensively used to
solve these constraints and supersymmetric vacua, centering our attention on
Minkowski solutions, become systematically computable and are also provided to
clarify the methods.
