A solution is to undefine min and max after the Snap.h include statement and then include other packages: