OpenGLをPostScriptに変換するライブラリです.ParaViewを自家ビルドするときに使ってました.残念ながら, ParaView5.0以降では役に立ちません.どうやら, OpenGL1の機能を使っていたが,OpenGL2にアップするときに放棄されちゃったみたいです.
インストール
あわれなX86_64の場合:これですね libPNGも必要かな.
ARM64の場合:
ビルド
X86ビルド
x86_64$ git clone https://gitlab.onelab.info/gl2ps/gl2ps.git x86_64$ cd gl2ps x86_64$ mkdir build x86_64$ cd build x86_64$ cmake .. ... CMake Warning (dev): Policy CMP0042 is not set: MACOSX_RPATH is enabled by default. Run "cmake --help-policy CMP0042" for policy details. Use the cmake_policy command to set the policy and suppress this warning. MACOSX_RPATH is not specified for the following targets: gl2ps This warning is for project developers. Use -Wno-dev to suppress it.
なんすか,これ?ここに従って
if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin") set(CMAKE_MACOSX_RPATH 1) endif()
を../CMakeLists.txtに追加すると消えたが・・・
x86_64$ make
...
Output written on gl2ps.pdf (19 pages, 227246 bytes).
Transcript written on gl2ps.log.
[ 42%] Built target pdf
[ 57%] Building C object CMakeFiles/gl2psTestSimple.dir/gl2psTestSimple.c.o
[ 71%] Linking C executable gl2psTestSimple
[ 71%] Built target gl2psTestSimple
[ 85%] Building C object CMakeFiles/gl2psTest.dir/gl2psTest.c.o
[100%] Linking C executable gl2psTest
[100%] Built target gl2psTest
なんかできたぞ.gl2psTestってのが試験らしいので実行してみる:
x86_64$ ./gl2psTest
なんか出たwww
ぎょえー,マウス動かすとベーグルが回るぞこれ?!?
まあええわ.
x86_64$ make install -- Install configuration: "RelWithDebInfo" -- Installing: /usr/local/lib/libgl2ps.1.4.3.dylib CMake Error at cmake_install.cmake:41 (file): file INSTALL cannot copy file "/Users/sugimoto/Documents/Source/Free/gl2ps/build/libgl2ps.1.4.3.dylib" to "/usr/local/lib/libgl2ps.1.4.3.dylib": Permission denied.
なるほど. libgl2ps.1.4.3.dylib ってのが,その,ライブラリーとかいう奴なのだな.
x86_64$ lipo -info libgl2ps.1.4.3.dylib
Non-fat file: libgl2ps.1.4.3.dylib is architecture: x86_64
x86_64$ otool -L libgl2ps.dylib
libgl2ps.dylib:
@rpath/libgl2ps.1.dylib (compatibility version 1.0.0, current version 1.4.3)
/System/Library/Frameworks/OpenGL.framework/Versions/A/OpenGL (compatibility version 1.0.0, current version 1.0.0)
/System/Library/Frameworks/GLUT.framework/Versions/A/GLUT (compatibility version 1.0.0, current version 1.0.0)
/System/Library/Frameworks/Cocoa.framework/Versions/A/Cocoa (compatibility version 1.0.0, current version 23.0.0)
/usr/lib/libz.1.dylib (compatibility version 1.0.0, current version 1.2.11)
/usr/local/lib/libpng16.16.dylib (compatibility version 54.0.0, current version 54.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1292.100.5)
ふむ.x86ライブラリーができている.とりま,これで,ええわな.
x86_64$ fswatch -x /usr/local/ > files.log & x86_64$ sudo make install [ 28%] Built target gl2ps [ 42%] Built target pdf [ 71%] Built target gl2psTestSimple [100%] Built target gl2psTest Install the project... -- Install configuration: "RelWithDebInfo" -- Installing: /usr/local/lib/libgl2ps.1.4.3.dylib -- Installing: /usr/local/lib/libgl2ps.1.dylib -- Installing: /usr/local/lib/libgl2ps.dylib -- Installing: /usr/local/include/gl2ps.h -- Installing: /usr/local/share/doc/gl2ps/README.txt -- Installing: /usr/local/share/doc/gl2ps/COPYING.LGPL -- Installing: /usr/local/share/doc/gl2ps/COPYING.GL2PS -- Installing: /usr/local/share/doc/gl2ps/gl2psTest.c -- Installing: /usr/local/share/doc/gl2ps/gl2psTestSimple.c -- Installing: /usr/local/share/doc/gl2ps/gl2ps.pdf x86_64$ kill %1 x86_64$ fswatch_analyze.sh -c _binary files.log x86_64$ pkgbuild --identifier gawk --root _binary gl2ps_1.4.3-osx11.6-x86_64.pkg
ARM64豚りんご
まだやってねえっす.
添付 | サイズ |
---|---|
gl2ps_1.4.3-osx11.6-x86_64.pkg | 287.65 KB |