Skip to content

Commit

Permalink
do most generatedd lexc building in hidden dirs?
Browse files Browse the repository at this point in the history
  • Loading branch information
flammie committed Dec 17, 2024
1 parent bae46d2 commit 73ff89b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
6 changes: 3 additions & 3 deletions am-shared/lexc-include.am
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
###########################################

####### HFST build rules: ########
.generated/%.hfst: %.lexc $(GENDIR)
.generated/%.hfst: .generated/%.lexc $(GENDIR)
$(AM_V_HLEXC)"$(HFST_LEXC)" \
$(MORE_VERBOSITY) $(HFST_FORMAT) $(HFST_LEXC_FLAGS) -o $@ $<

Expand All @@ -29,7 +29,7 @@
$(MORE_VERBOSITY) $(HFST_FORMAT) $(HFST_LEXC_FLAGS) -o $@ $<

####### Xerox build rules: #######
.generated/%.xfst: %.lexc $(GENDIR)
.generated/%.xfst: .generated/%.lexc $(GENDIR)
$(AM_V_XFST)"$(XFST)" $(VERBOSITY) \
-e "read lexc $<" \
-e "save stack $@ " \
Expand All @@ -42,7 +42,7 @@
-stop

####### Foma build rules: #######
.generated/%.foma: %.lexc $(GENDIR)
.generated/%.foma: .generated.generated//%.lexc $(GENDIR)
$(AM_V_FOMA)"$(FOMA)" $(VERBOSITY) \
-e "set lexc-align ON" \
-e "read lexc $<" \
Expand Down
10 changes: 5 additions & 5 deletions am-shared/src-morphology-dir-include.am
Original file line number Diff line number Diff line change
Expand Up @@ -146,11 +146,11 @@ endif
####### when something doesn't work); hfst does the concatenation automatically
####### but by doing it explicitly we have a source file to relate line numbers
####### in error messages to. Foma can only read a single lexc file.
lexicon.lexc: $(GT_LEXC_ROOT) $(GT_LEXC_SRCS) $(GENERATED_LEXC_SRCS)
.generated/lexicon.lexc: $(GT_LEXC_ROOT) $(GT_LEXC_SRCS) $(GENERATED_LEXC_SRCS) $(GENDIR)
$(AM_V_at)echo "! automatically generated combined lexc file!!!" > $@
$(AM_V_GEN)cat $^ >> $@

lexicon-L2.lexc: $(GT_LEXC_ROOT) $(GT_LEXC_L2_SRCS) $(GENERATED_LEXC_SRCS)
.generated/lexicon-L2.lexc: $(GT_LEXC_ROOT) $(GT_LEXC_L2_SRCS) $(GENERATED_LEXC_SRCS) $(GENDIR)
$(AM_V_GEN)cat $^ > $@

# Copy shared url lexc file to local dir as tmp file before building. The tmp
Expand All @@ -173,9 +173,9 @@ lexicon-L2.lexc: $(GT_LEXC_ROOT) $(GT_LEXC_L2_SRCS) $(GENERATED_LEXC_SRCS)

####### TMP files to allow local overrides - copy by default: #######
DEPGEN=$(AM_V_CP)mv -f $< $@
%.foma: .generated/%.tmp.foma ; $(DEPGEN)
%.hfst: .generated/%.tmp.hfst ; $(DEPGEN)
%.xfst: .generated/%.tmp.xfst ; $(DEPGEN)
.generated/%.foma: .generated/%.tmp.foma ; $(DEPGEN)
.generated/%.hfst: .generated/%.tmp.hfst ; $(DEPGEN)
.generated/%.xfst: .generated/%.tmp.xfst ; $(DEPGEN)

####### Phonology source file defs: ########

Expand Down

0 comments on commit 73ff89b

Please sign in to comment.