# -*- coding: utf-8 -*-
# Copyright (C) 2016, ENPC - EDF R&D
#     Author(s): Sylvain Doré
#
# This file is part of the air quality modeling system Polyphemus.
#
# Polyphemus is developed in the INRIA - ENPC joint project-team CLIME and in
# the ENPC - EDF R&D joint laboratory CEREA.
#
# Polyphemus is free software; you can redistribute it and/or modify it under
# the terms of the GNU General Public License as published by the Free
# Software Foundation; either version 2 of the License, or (at your option)
# any later version.
#
# Polyphemus is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
# more details.
#
# For more information, visit the Polyphemus web site:
#      http://cerea.enpc.fr/polyphemus/

import fnmatch
import os


utils = SConscript("./scons/utils")(globals())

black_list = ["SConstruct",
              "include/fastJX/CSection/SConstruct"]

project_list = []
for root, dirnames, filenames in os.walk('.'):
    for filename in fnmatch.filter(filenames, 'SConstruct'):
        project = os.path.relpath(os.path.join(root, filename), ".")
        if project not in black_list:
            utils.run.sconstruct(project)
