Skip to content

Commit

Permalink
Merge pull request #93 from Shaikh-Ubaid/fix_run_in_subdir
Browse files Browse the repository at this point in the history
Fix running `lc` in sub directory
  • Loading branch information
certik authored Feb 16, 2024
2 parents 5eb7bcb + ee895bb commit 530e5e5
Show file tree
Hide file tree
Showing 8 changed files with 903 additions and 7 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ jobs:
lc examples/expr2.c --backend c -o c_o -c
lc examples/expr2.c --backend llvm -o llvm_o -c
ls -1
cd examples
lc expr2.c
- name: Test3 (Linux / macOS)
shell: bash -l -e {0}
Expand Down
7 changes: 7 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,9 @@ if (WITH_LLVM)
${CLANG_LIBRARIES})
endif()

set(WITH_WHEREAMI yes
CACHE BOOL "Include whereami.cpp")

set(WITH_MACHO no
CACHE BOOL "Build with mach-o support")

Expand All @@ -125,6 +128,10 @@ if (WITH_MACHO)
set(HAVE_LFORTRAN_MACHO yes)
endif()

if (WITH_WHEREAMI)
add_definitions("-DHAVE_WHEREAMI=1")
endif()

enable_testing()

message("\n")
Expand Down
1 change: 1 addition & 0 deletions src/bin/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
add_executable(lc lc.cpp)
target_include_directories(lc PRIVATE "tpl")
target_link_libraries(lc p::clang p::llvm asr lc_lib)
install(TARGETS lc DESTINATION ${CMAKE_INSTALL_PREFIX}/bin)
Loading

0 comments on commit 530e5e5

Please sign in to comment.