CFD中文网

    CFD中文网

    • 登录
    • 搜索
    • 最新

    我openfoam6中的dirToString和wmkdep被误删了,请问这两个该怎么编译

    OpenFOAM
    2
    4
    1469
    正在加载更多帖子
    • 从旧到新
    • 从新到旧
    • 最多赞同
    回复
    • 在新帖中回复
    登录后回复
    此主题已被删除。只有拥有主题管理权限的用户可以查看。
    • 郑
      郑澄远 最后由 编辑

      路径是home/zcy/OpenFOAM/OpenFOAM-6/wmake/platforms/linux64Gcc
      在其他虚拟机中OpenFOAM显示的样子
      5WNI}X}S)IO2GK15WW`LTUB.png

      1 条回复 最后回复 回复 引用
      • 李东岳
        李东岳 管理员 最后由 编辑

        拷贝复制过去就行,如果别的文件没删除只删除这两个的话

        线上CFD课程开始报名:http://www.dyfluid.com/class.html

        CFD高性能服务器 http://dyfluid.com/servers.html

        郑 1 条回复 最后回复 回复 引用
        • 郑
          郑澄远 @李东岳 最后由 李东岳 编辑

          @东岳 在编译openfoam6时是输入./Allwmake进行编译,此时终端会输出:

          Allwmake /home/zcy/OpenFOAM/OpenFOAM-6
          gcc -m64 -Dlinux64 -DWM_ARCH_OPTION=64 -DWM_DP -DWM_LABEL_SIZE=32 -Wall -O3   -fPIC dirToString.c -o /home/zcy/OpenFOAM/OpenFOAM-6/wmake/platforms/linux64Gcc/dirToString
          flex wmkdep.l; \
          gcc -m64 -Dlinux64 -DWM_ARCH_OPTION=64 -DWM_DP -DWM_LABEL_SIZE=32 -Wall -O3   -fPIC lex.yy.c -o /home/zcy/OpenFOAM/OpenFOAM-6/wmake/platforms/linux64Gcc/wmkdep
          lex.yy.c:1264:17: warning: ‘yyunput’ defined but not used [-Wunused-function]
               static void yyunput (int c, char * yy_bp )
                           ^
          lex.yy.c:1307:16: warning: ‘input’ defined but not used [-Wunused-function]
               static int input  (void)
                          ^
          Allwmake: no ThirdParty directory found - skipping
          Allwmake src
          

          这个时候dirToString和wmkdep应该已经编译好了,我想知道能不能在编译而不是复制这两个,给上Allwmake脚本内容

          #!/bin/sh
          cd ${0%/*} || exit 1    # Run from this directory
          
          # Parse arguments for library compilation
          . wmake/scripts/AllwmakeParseArguments
          # Perform various checks
          wmakeCheckPwd "$WM_PROJECT_DIR" || {
              echo "Allwmake error: Current directory is not \$WM_PROJECT_DIR"
              echo "    The environment variables are inconsistent with the installation."
              echo "    Check the OpenFOAM entries in your dot-files and source them."
              exit 1
          }
          
          [ -n "$FOAM_EXT_LIBBIN" ] || {
              echo "Allwmake error: FOAM_EXT_LIBBIN not set"
              echo "    Check the OpenFOAM entries in your dot-files and source them."
              exit 1
          }
          
          # Compile wmake support applications
          (cd wmake/src && make)
          
          # Compile ThirdParty libraries and applications
          if [ -d "$WM_THIRD_PARTY_DIR" ]
          then
              $WM_THIRD_PARTY_DIR/Allwmake
          else
              echo "Allwmake: no ThirdParty directory found - skipping"
          fi
          
          # Compile OpenFOAM libraries and applications
          src/Allwmake $targetType $*
          
          # Compile OpenFOAM libraries and applications
          applications/Allwmake $targetType $*
          
          1 条回复 最后回复 回复 引用
          • 李东岳
            李东岳 管理员 最后由 编辑

            可以没问题,直接用吧 :duang:

            线上CFD课程开始报名:http://www.dyfluid.com/class.html

            CFD高性能服务器 http://dyfluid.com/servers.html

            1 条回复 最后回复 回复 引用
            • First post
              Last post