Skip to content

Commit

Permalink
Merge pull request #81 from dinkelk/bind-fix
Browse files Browse the repository at this point in the history
Relax dependency check for Ada binding of C/C++
  • Loading branch information
dinkelk authored Oct 7, 2024
2 parents 3b09152 + 0fb64a5 commit 0cc149a
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions redo/rules/build_object.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,10 +118,14 @@ def _get_all_dependencies(source_files):
for source in new_ads_sources:
if source.endswith("_h.ads"):
with c_source_database() as db:
c_sources.extend(db.get_sources([os.path.basename(source[:-6])]))
binded_sources = db.try_get_sources([os.path.basename(source[:-6])])
if binded_sources:
c_sources.extend(binded_sources)
if source.endswith("_hpp.ads"):
with c_source_database() as db:
c_sources.extend(db.get_sources([os.path.basename(source[:-8])]))
binded_sources = db.try_get_sources([os.path.basename(source[:-8])])
if binded_sources:
c_sources.extend(binded_sources)
if c_sources:
redo.redo_ifchange(c_sources)
deps.extend(c_sources)
Expand Down

0 comments on commit 0cc149a

Please sign in to comment.