-
Notifications
You must be signed in to change notification settings - Fork 69
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fpga: add independent compilation and usage support under fpga
- Loading branch information
1 parent
ee1ffa9
commit bdd099c
Showing
6 changed files
with
86 additions
and
18 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
|
||
FPGA = FPGA_HOST | ||
FPGA_TARGET = $(abspath $(BUILD_DIR)/simv) | ||
FPGA_BUILD_DIR = $(abspath $(BUILD_DIR)/simv-compile) | ||
FPGA_RUN_DIR = $(abspath $(BUILD_DIR)/$(notdir $(RUN_BIN))) | ||
|
||
FPGA_CSRC_DIR = $(abspath ./src/test/csrc/fpga) | ||
FPGA_CONFIG_DIR = $(abspath ./config) | ||
|
||
FPGA_CXXFILES = $(SIM_CXXFILES) $(shell find $(FPGA_CSRC_DIR) -name "*.cpp") | ||
FPGA_CXXFLAGS = $(subst \\\",\", $(SIM_CXXFLAGS)) -I$(FPGA_CSRC_DIR) -DNUM_CORES=$(NUM_CORES) | ||
FPGA_LDFLAGS = $(SIM_LDFLAGS) -lpthread -ldl | ||
|
||
fpga-build: fpga-clean fpga-host | ||
|
||
fpga-host: | ||
$(CXX) $(FPGA_CXXFLAGS) $(FPGA_CXXFILES) $^ -o $@ $(FPGA_LDFLAGS) | ||
fpga-clean: | ||
rm -f fpga-host |
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
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
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
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