安装portmidi库

时间:2013-01-02 19:19:28

标签: java

我正在尝试安装portmidi库:http://sourceforge.net/apps/trac/portmedia/wiki/Installing%20portmidi%20on%20Linux

我已按照说明操作,但当我做“制作”时,我会在下面收到此消息。我尝试了不同的Javapath,我不知道它现在是不是。谁能告诉我这里出了什么问题?

natanael@natanael-iMac:~/workspace/portmidi$ make
-- JAVA_JVM_LIB_PATH is 
-- JAVA_INCLUDE_PATH is /usr/lib/jvm/java-6-openjdk/include
-- JAVA_INCLUDE_PATH2 is /usr/lib/jvm/java-6-openjdk/include/linux
-- JAVA_JVM_LIBRARY is /usr/lib/jvm/java-6-openjdk/jre/lib/i386/client/libjvm.so
-- Configuring done
-- Generating done
-- Build files have been written to: /home/natanael/workspace/portmidi
[ 93%] Built target pmjni
[ 93%] Built target portmidi-static
[ 93%] Built target latency
[ 93%] Built target midiclock
[ 93%] Built target midithread
[ 93%] Built target midithru
[ 93%] Built target mm
[ 93%] Built target qtest
[ 93%] Built target sysex
[ 93%] Built target test
[ 93%] Built target portmidi-dynamic
[ 93%] Generating pmdefaults/PmDefaults.class
/bin/sh: 1: cd: can't cd to /home/natanael/workspace/portmidi/pm_java/pm_java
make[2]: *** [pm_java/pmdefaults/PmDefaults.class] Fehler 2
make[1]: *** [pm_java/CMakeFiles/pmdefaults_target.dir/all] Fehler 2
make: *** [all] Fehler 2
natanael@natanael-iMac:~/workspace/portmidi$ 

谢谢!

1 个答案:

答案 0 :(得分:3)

显然,Makefile生成的ccmake之一已被破坏。我能够通过运行

解决问题
sed -i 's/pm_java\/pm_java/pm_java/' build.make
在运行pm_java/CMakeFiles/pmdefaults_target.dir/之后在项目ccmake .子目录中(尽管在Ubuntu上)。 (sed命令将所有pm_java/pm_java替换为pm_java。)

所有内容都会编译,我甚至可以使用

pmdefaults目录运行Release
java -Djava.library.path=. -jar pmdefaults.jar