荔园在线

荔园之美,在春之萌芽,在夏之绽放,在秋之收获,在冬之沉淀

[回到开始] [上一篇][下一篇]


发信人: Lg (创造人生的传奇), 信区: InstallBBS
标  题: hztty for bbs BIG5->GB->BIG5
发信站: BBS 荔园晨风站 (Wed Oct 28 00:36:40 1998), 站内信件

1.first vi hztty main.c
        if (loginsh)
             *cmdargv = "-";

        /* Begin for bbs */
        o_stream = "gb2big";
        i_stream = "big2gb";
        utmp = 0;
        debug = 0;
        cmd = "bin/bbs";
        shell[0]="bbs";
        shell[1]="h";
        shell[2]=argv[1];
        shell[3]=argv[2];
        shell[4]=(char *)0;
        cmdargv = shell;
        /* End for bbs */

        getmaster();
2.make linux -> hztty
3.cp hztty /home/bbs/bin/hzbbs
4.vi bbsrf.c
#ifdef BBSRF_CHROOT
        sprintf( bbs_prog_path, "/bin/hzbbs", BBSHOME );
                                /*    ^^        */
        if (chroot(BBSHOME) != 0) {
            printf("Cannot chroot, exit!\n");
            exit( -1 );
        }
#else
        sprintf( bbs_prog_path, "%s/bin/hzbbs", BBSHOME );
                                /*      ^^      */
#endif

            RF_DEBUG("Before execl (whee)....");

            execl( bbs_prog_path,"hzbbs","h", hid, ttybuf, NULL) ;
                        /*        ^^    */
        } else {
            RF_DEBUG("Before execl (not whee)....");
            execl( bbs_prog_path,"hzbbs","h", "unknown", "notty", NULL) ;
                        /*        ^^    */
        }
5.make->bbsrf
6.cp bbsrf /home/bbs/bin/big5bbsrf
6.add account bb5(9999 99) /home/bbs/bin/big5bbsrf
--
□□□□□□□□□□□□□□□□□□□□□□□□□□□□□□□□□
□          深圳大学荔园晨风 BBS 站为大家提供以下服务:          □
□    BBS: bbs.szu.edu.cn               FTP: bbs.szu.edu.cn     □
□    MUD: bbs.szu.edu.cn 5000          WWW: bbs.szu.edu.cn     □
□□□□□□□□□□□□□□□□□□□□□□□□□□□□□□□□□

※ 来源:.BBS 荔园晨风站 bbs.szu.edu.cn.[FROM: lg.szu.edu.cn]


[回到开始] [上一篇][下一篇]

荔园在线首页 友情链接:深圳大学 深大招生 荔园晨风BBS S-Term软件 网络书店