Dev./persistence
[pgloader] libsybdb.dylib 에러 해결 방법(mac)
인쥭
2022. 4. 18. 18:16
반응형
- 설치 과정에서 다음과 같은 에러가 발생할 수 있다.
44,210 bytes in 0.19 seconds (230.88KB/sec)
; Fetching #<URL "http://beta.quicklisp.org/archive/cl-mssql/2013-10-03/cl-mssql-20131003-git.tgz">
; 15.04KB
==================================================
15,398 bytes in 0.00 seconds (0.00KB/sec)
; Loading "mssql"
[package garbage-pools]...........................
[package mssql].
debugger invoked on a LOAD-FOREIGN-LIBRARY-ERROR in thread
#<THREAD "main thread" RUNNING {1002E06D43}>:
Unable to load foreign library (SYBDB).
Error opening shared object "libsybdb.dylib":
dlopen(libsybdb.dylib, 10): image not found.
Type HELP for debugger help, or (SB-EXT:EXIT) to exit from SBCL.
restarts (invokable by number or by possibly-abbreviated name):
0: [RETRY ] Try loading the foreign library again.
1: [USE-VALUE ] Use another library instead.
2: [SKIP ] Skip loading foreign library tds.
3: [TRY-RECOMPILING ] Recompile mssql and try loading it again
4: [RETRY ] Retry
loading FASL for #<CL-SOURCE-FILE "mssql" "src" "mssql">.
5: [ACCEPT ] Continue, treating
loading FASL for #<CL-SOURCE-FILE "mssql" "src" "mssql">
as having been successful.
6: Retry ASDF operation.
7: [CLEAR-CONFIGURATION-AND-RETRY] Retry ASDF operation after resetting the
configuration.
8: [ABORT ] Give up on "mssql"
9: Give up on "pgloader"
10: [CONTINUE ] Ignore runtime option --eval "(ql:quickload \"pgloader\")".
11: Skip rest of --eval and --load options.
12: Skip to toplevel READ/EVAL/PRINT loop.
13: [EXIT ] Exit SBCL (calling #'EXIT, killing the process).
(CFFI::FL-ERROR "Unable to load foreign library (~A).~% ~A" SYBDB "Error opening shared object \"libsybdb.dylib\":
dlopen(libsybdb.dylib, 10): image not found.")
0] 13
;
; compilation unit aborted
; caught 2 fatal ERROR conditions
make: *** [build/libs.stamp] Error 1
- 원인은 /usr/local/lib 경로에 libsybdb.dylib이 존재하지 않기 때문이며, 다음과 같이 freetds를 설치하는 것으로 해결할 수 있다.
- 설치가 완료된 후 ls 명령어를 통해 /usr/local/lib/libsybdb.dylib을 확인할 수 있다.
- 설치가 완료된 후 다시 make pgloader 명령어를 실행할 경우 pgloader가 정상적으로 빌드된다.
- 여기에서 보면 소스에서 빌드하는 pgloader는 freetds가 설치되어야 한다는 것을 알 수 있다.
brew install freetds