manywaypark's Blog
개발, 검색, 함수

문제:

macport로 python36을 설치하고, 안내에 따라 py36-readline을 설치했는데 아래 처럼 crash가 났다.

$ python

Python 3.6.1 (default, Mar 22 2017, 15:53:21) 

[GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.42.1)] on darwin

Type "help", "copyright", "credits" or "license" for more information.

>>> ''.join(sorted('azbasdfasdf'))

Python(4369,0x7fffa0cba3c0) malloc: *** error for object 0x10592a4f0: pointer being freed was not allocated

*** set a breakpoint in malloc_error_break to debug

Abort trap: 6



해결:

$ sudo port uninstall py36-readline

$ sudo port install python36 +readline


python36 package를 설치하고 나면 py36-readline도 꼭 설치하라는 식의 메시지가 나오는데 이거 잘못된 것인 듯


ref: https://trac.macports.org/ticket/53360


happy hackin'

[macport] port select --set

tips & tricks/Mac 2016. 7. 6. 10:49 by manywaypark

macport를 쓰다보면 같은 package이지만 여러 버전이 있는 경우가 있다.

postgresql의 예를 들자면 아래와같이 하면 9.4버전으로 설정을 맞추어준다.

sudo port select --set postgresql postgresql94

설정을 맞춘다는 것의 의미는 각종 파일 및 링크(eg, /opt/local/bin/pg_config 등)를 업데이트해주는 것을 말한다.


ref: http://stackoverflow.com/questions/7832296/usage-of-postgresql-select-on-macports


happy hackin'


PS. packagename_select 패키지를 설치해야되는 듯. postgresql은 postgresql_select

R같은 한 글자로 된 패키지를 찾으려고 port search R 처럼 하면 엄청나게 많은 패키지가 리스팅된다.

아래처럼 하면 정확한 이름으로 찾아준다.

$ port search --exact R

R @3.3.0 (math, science)

    R is GNU S - an interpreted language for statistical computing


ref: http://johnlaudun.org/20140721-install-r-with-macports/


happy hackin'

[TIP] macport svn downgrade

tips & tricks 2012. 3. 14. 16:42 by manywaypark
macport에서 subversion을 downgrade할 일이 생겼다(1,7.x -> 1.6.x).
현재로서는 간단하게 하는 방법은 없는 듯하고 아래처럼 수동으로 해야한다. 

$ cd /tmp
$ svn co http://svn.macports.org/repository/macports/trunk/dports/devel/subversion
$ cd subversion
$ svn log
......
------------------------------------------------------------------------
r85581 | dluke@macports.org | 2011-10-15 03:56:06 +0900 (Sat, 15 Oct 2011) | 2 lines

subversion: version bump, subversion and bindings ports to 1.7.0

------------------------------------------------------------------------
r80777 | blair@macports.org | 2011-07-17 14:55:53 +0900 (Sun, 17 Jul 2011) | 5 lines

subversion, subversion-javahlbindings, subversion-rubybindings,
subversion-python26bindings, subversion-python27bindings,
subversion-python24bindings, subversion-perlbindings,
subversion-python25bindings: Depend upon serf0 instead of serf.
......
$ cd ..
$ svn co -r 80777 http://svn.macports.org/repository/macports/trunk/dports/devel/subversion subversion80777
$ cd subversion80777
$ sudo port install
......
--->  Attempting to fetch subversion-1.6.17_1......
......
$ port installed subversion
The following ports are currently installed:
  subversion @1.6.17_1 (active)
  subversion @1.7.3_1

 
refs:
http://reinout.vanrees.org/weblog/2008/09/19/macports-downgrading-subversion.html
https://trac.macports.org/wiki/howto/InstallingOlderPort 

happy hackin' 

macport에서 git-svn 쓰기

카테고리 없음 2012. 3. 12. 17:10 by manywaypark
windows의 cygwin에서는 git-core package만 설하면 git-svn도 같이 설치되어 편하게 사용할 수 있었는데, mac의 macport에서는 git-core만 설치하면 git-svn이 설치되지 않는다.
다음과 같이 설치하면 된다.
sudo port install git-core +svn 

/opt/local/libexec/git-core/git-svn이 깔린 것을 확인 할 수 있다.
git-svn을 직접 실행해도 되지만 아마 PATH에 없을 것이다. 아래와 같이 git svn의 형태로 실행시키면 된다.
git svn clone [-s] http://url.to.svn.repo/

refs: 
 http://alecthegeek.wordpress.com/2007/09/20/getting-git-svn-working-on-the-mac/
 http://rajshekhar.net/blog/archives/343-git-svn-on-macports.html

happy hackin' 

MacPort 전체 정리

tips & tricks 2011. 4. 6. 18:32 by manywaypark
생각없이 쓰다보니 맥북의 하드가 꽉찼다. Orz
다운로드 폴더에서 이거 저거 지우다가 문득 든 생각... 어제 port upgrade outdated를 하고 나서 disk full이 난거같았다.
MacPort가 생성한 임시 파일들 정리하는 법은 의외로 간단했다.

$ sudo port clean --all all


추가적으로 비활성(inactive) 패키지 삭제(uninstall) :

$ sudo port uninstall inactive


다 하고 나니 약 4G 정도 늘어난듯...

refs:
Clean way to uninstall outdated inactive ports

happy hackin' 
1 
분류 전체보기 (306)
잡담 (20)
함수형 언어 (65)
emacs (16)
java (18)
tips & tricks (154)
사랑 (1)
가사 (0)
독서 (4)
mobile (6)
비함수형 언어 (2)

공지사항

최근에 올라온 글

최근에 달린 댓글

최근에 받은 트랙백

03-19 11:02