Permalink
Cannot retrieve contributors at this time
Name already in use
A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
genetics-jargon-counter/Makefile
Go to fileThis commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
31 lines (24 sloc)
691 Bytes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Create XML files from PDFs as the XML files can more reliably be examined. | |
PDF_FILES=$(wildcard *.pdf) | |
XML_FILES=$(patsubst %.pdf, %.xml, $(PDF_FILES)) | |
TXT_FILES=$(patsubst %.pdf, %-extracted.txt, $(PDF_FILES)) | |
# Generate TXT files from XML files. | |
.PHONY : txt | |
txt : $(TXT_FILES) | |
# Extract concept list from XML. | |
%-extracted.txt : %.xml | |
python extract-concepts.py $< | |
# Generate XML files. | |
.PHONY : xml | |
xml : $(XML_FILES) | |
# Convert PDF to XML. | |
%.xml : %.pdf | |
pdftohtml -xml $< | |
# Show the files the Makefile will operate on. | |
.PHONY : variables | |
variables : | |
@echo Input PDF_FILES: $(PDF_FILES) | |
@echo Output XML_FILES: $(XML_FILES) | |
.PHONY : clean | |
clean : | |
rm -f *.xml *-extracted.txt |