📄 makefile
字号:
SIGTYPE=psx CHECKPW=psx CRXTYPE=nfs \ SPOOLDIR=/var/spool MAILSPOOL=/var/mail \ ACTIVEFILE=/usr/share/news/active \ RSHPATH=/usr/bin/rsh \ BASECFLAGS="-g -O -w" \ BASELDFLAGS="-lsocket -lnsl -lgen" \ RANLIB=true CC=/opt/SUNWspro/bin/cc# Note: It is a long and disgusting story about why cc is set to ucbcc. You# need to invoke the C compiler so that it links with the SVR4 libraries and# not the BSD libraries, otherwise readdir() will return the wrong information.# Of all the names in the most common path, ucbcc is the only name to be found# (on /usr/ccs/bin) that points to a suitable compiler. cc is likely to be# /usr/ucb/cc which is absolutely not the compiler that you want. The real# SVR4 cc is probably something like /opt/SUNWspro/bin/cc which is rarely in# anyone's path.## ucbcc is probably a link to acc, e.g. /opt/SUNWspro/SC4.0/bin/acc, and is# the UCB C compiler using the SVR4 libraries.## If ucbcc isn't on your system, then punt on the SUN C compiler and use gcc# instead (the gso port instead of the sol port).# # If, in spite of all the above warnings, you choose to use the "soc" port# instead of the "sol" port, be sure to check the behavior of the LIST command# in imapd. Also, note that the "soc" port uses -O. If you want to use the# real SVR4 compiler, you must use -O. If it works to compile with -O2, then# cc is probably using the UCB compiler with BSD libraries, and will not build# a good binary## To recap:# 1) The sol port is designed to be built using the UCB compiler using the# SVR4 libraries. This compiler is "ucbcc", which is lunk to acc. You# use -O2 as one of the CFLAGS.# 2) If you build the sol port with the UCB compiler using the BSD libraries,# you will get no error messages but you will get bad binaries (the most# obvious symptom is dropping the first two characters return filenames# from the imapd LIST command. This compiler also uses -O2, and is very# often what the user gets from "cc". BEWARE!!!# 3) If you build the sol port with the real SVR4 compiler, which is often# hidden away or unavailable on many systems, then you will get errors# from -O2 and you need to change that to -O. But you will get a good# binary. However, you should try it with -O2 first, to make sure that# you got this compiler and not the UCB compiler using BSD libraries.sol: os_sol.h # Solaris $(BUILD) `$(CAT) SPECIALS` OS=$@ \ SIGTYPE=psx CHECKPW=psx CRXTYPE=nfs \ SPOOLDIR=/var/spool MAILSPOOL=/var/mail \ ACTIVEFILE=/usr/share/news/active \ RSHPATH=/usr/bin/rsh \ BASECFLAGS="-g -O2" \ BASELDFLAGS="-lsocket -lnsl -lgen" \ RANLIB=true CC=ucbccsos: # Secure OSF/1 $(BUILD) `$(CAT) SPECIALS` OS=$@ \ SIGTYPE=psx CHECKPW=sce LOGINPW=sec CRXTYPE=nfs \ BASECFLAGS="-g3 -w -O2 -Olimit 1500" \ BASELDFLAGS="-lsecurity -laud"ssn: # Secure SUN-OS $(BUILD) `$(CAT) SPECIALS` OS=sun \ CHECKPW=ssn CRXTYPE=nfs \ BASECFLAGS="-g -Dconst=" \ BASELDFLAGS="-ldl"sua: # Windows Vista Subsystem for UNIX Applications $(BUILD) `$(CAT) SPECIALS` OS=sua \ SIGTYPE=psx CRXTYPE=nfs LOGINPW=old \ SPOOLDIR=/var/spool MAILSPOOL=/var/mail \ ACTIVEFILE=/var/lib/news/active \ RSHPATH=/usr/bin/rsh \ BASECFLAGS="-g -O2" \ BASELDFLAGS="-lcrypt"sun: # SUN-OS $(BUILD) `$(CAT) SPECIALS` OS=$@ \ CRXTYPE=nfs \ BASECFLAGS="-g -Dconst=" \ BASELDFLAGS="-ldl"sv2: # SVR2 @echo You are being *very* optimistic! $(BUILD) `$(CAT) SPECIALS` OS=$@ \ SIGTYPE=sv4 LOGINPW=old \ MAILSPOOL=/usr/mail \ RSHPATH=/usr/bin/remsh \ BASECFLAGS="-Dconst= -DSYSTEM5 -DSHORT_IDENT -I/usr/ethernet/include" \ BASELDFLAGS="-lnet" \ RANLIB=true LN=lnsv4: # SVR4 $(BUILD) `$(CAT) SPECIALS` OS=$@ \ SIGTYPE=sv4 CHECKPW=sv4 LOGINPW=sv4 \ SPOOLDIR=/var/spool MAILSPOOL=/var/mail \ ACTIVEFILE=/usr/share/news/active \ RSHPATH=/usr/bin/resh \ BASECFLAGS="-g -Dconst=" \ BASELDFLAGS="-lsocket -lnsl -lgen" \ RANLIB=trueult: # Ultrix $(BUILD) `$(CAT) SPECIALS` OS=$@ \ SIGTYPE=psx CHECKPW=ult CRXTYPE=nfs \ BASECFLAGS="-g3 -O2 -Olimit 1500 -Dconst=" \ BASELDFLAGS="-lauth -lc"uw2: # UnixWare SVR4.2 $(BUILD) `$(CAT) SPECIALS` OS=sv4 \ SIGTYPE=sv4 CHECKPW=sv4 \ SPOOLDIR=/var/spool MAILSPOOL=/var/mail \ ACTIVEFILE=/var/news/lib/active \ RSHPATH=/usr/bin/rsh \ BASECFLAGS="-g" \ BASELDFLAGS="-lsocket -lnsl -lgen" \ RANLIB=truevul: # VAX Ultrix $(BUILD) `$(CAT) SPECIALS` OS=ult \ SIGTYPE=psx CHECKPW=ult CRXTYPE=nfs \ BASECFLAGS="-O2 -Dconst=" \ BASELDFLAGS="-lauth -lc"vu2: # VAX Ultrix 2.3, etc. $(BUILD) `$(CAT) SPECIALS` OS=$@ \ CRXTYPE=nfs \ BASECFLAGS="-O2 -Dconst= -Dvoid=char"# Build it!build: clean once $(ARCHIVE)all: $(ARCHIVE)$(ARCHIVE): $(BINARIES) sh -c '$(RM) $(ARCHIVE) || true' @$(CAT) ARCHIVE @$(SH) ARCHIVE.c.o: `$(CAT) CCTYPE` -c `$(CAT) CFLAGS` $*.c# Cleanupclean: sh -c '$(RM) auths.c crexcl.c ip_unix.c linkage.[ch] siglocal.c osdep*.[ch] *.o ARCHIVE *FLAGS *TYPE $(ARCHIVE) || true'# Dependenciesdummy.o: mail.h misc.h osdep.h dummy.hfdstring.o: mail.h misc.h osdep.h fdstring.hflstring.o: mail.h misc.h osdep.h flstring.himap4r1.o: mail.h misc.h osdep.h imap4r1.h rfc822.hmail.o: mail.h misc.h osdep.h rfc822.h linkage.hmbx.o: mail.h misc.h osdep.h dummy.hmh.o: mail.h misc.h osdep.h dummy.hmix.o: mail.h misc.h osdep.h dummy.hmx.o: mail.h misc.h osdep.h dummy.hmisc.o: mail.h misc.h osdep.hmmdf.o: mail.h misc.h osdep.h pseudo.h dummy.hmtx.o: mail.h misc.h osdep.h dummy.hnetmsg.o: mail.h misc.h osdep.h netmsg.hnews.o: mail.h misc.h osdep.hnewsrc.o: mail.h misc.h osdep.h newsrc.hnntp.o: mail.h misc.h osdep.h netmsg.h smtp.h nntp.h rfc822.hphile.o: mail.h misc.h osdep.h rfc822.h dummy.hpseudo.o: pseudo.hpop3.o: mail.h misc.h osdep.h rfc822.hsmanager.o: mail.h misc.h osdep.hsmtp.o: mail.h misc.h osdep.h smtp.h rfc822.hrfc822.o: mail.h misc.h osdep.h rfc822.htenex.o: mail.h misc.h osdep.h dummy.hunix.o: mail.h misc.h osdep.h unix.h pseudo.h dummy.hutf8.o: mail.h misc.h osdep.h utf8.h tmap.c widths.cutf8aux.o: mail.h misc.h osdep.h utf8.h# OS-dependentosdep.o:mail.h misc.h env.h fs.h ftl.h nl.h tcp.h \ osdep.h env_unix.h tcp_unix.h \ osdep.c env_unix.c fs_unix.c ftl_unix.c nl_unix.c tcp_unix.c ip_unix.c\ auths.c crexcl.c flockcyg.c flocklnx.c flocksim.c fsync.c \ gethstid.c getspnam.c \ gr_wait.c gr_wait4.c gr_waitp.c \ kerb_mit.c \ auth_ext.c auth_gss.c auth_log.c auth_md5.c auth_pla.c \ pmatch.c scandir.c setpgrp.c strerror.c truncate.c write.c \ memmove.c memmove2.c memset.c \ tz_bsd.c tz_nul.c tz_sv4.c \ write.c sslstdio.c \ strerror.c strpbrk.c strstr.c strtok.c strtoul.c \ OSCFLAGS @echo Building OS-dependent module @echo If you get No such file error messages for files x509.h, ssl.h, @echo pem.h, buffer.h, bio.h, and crypto.h, that means that OpenSSL @echo is not installed on your system. Either install OpenSSL first @echo or build with command: make `$(CAT) OSTYPE` SSLTYPE=none `$(CAT) CCTYPE` -c `$(CAT) CFLAGS` `$(CAT) OSCFLAGS` -c osdep.cosdep.c: osdepbas.c osdepckp.c osdeplog.c osdepssl.c $(CAT) osdepbas.c osdepckp.c osdeplog.c osdepssl.c > osdep.cosdepbas.c: @echo osdepbas.c not found...try make clean and new make @falseosdepckp.c: @echo osdepckp.c not found...try make clean and new make @falseosdeplog.c: @echo osdeplog.c not found...try make clean and new make @falseosdepssl.c: @echo osdepssl.c not found...try make clean and new make @falsesiglocal.c: @echo siglocal.c not found...try make clean and new make @falsecrexcl.c: @echo crexcl.c not found...do make clean and new make @falseip_unix.c: @echo ip_unix.c not found...do make clean and new make @falseos_sol.h: sh -c 'if [ -f /lib/libc.a ]; then (strings /lib/libc.a | grep getpassphrase > /dev/null) && $(LN) os_soln.h os_sol.h || $(LN) os_solo.h os_sol.h ; else $(LN) os_soln.h os_sol.h ; fi'# Once-only environment setuponce: onceenv ckp$(PASSWDTYPE) ssl$(SSLTYPE) osdep.conceenv: @echo Once-only environment setup... echo $(CC) > CCTYPE echo $(BASECFLAGS) '$(EXTRACFLAGS)' -DCHUNKSIZE=$(CHUNKSIZE) > CFLAGS echo -DCREATEPROTO=$(CREATEPROTO) -DEMPTYPROTO=$(EMPTYPROTO) \ -DMD5ENABLE=\"$(MD5PWD)\" -DMAILSPOOL=\"$(MAILSPOOL)\" \ -DANONYMOUSHOME=\"$(MAILSPOOL)/anonymous\" \ -DACTIVEFILE=\"$(ACTIVEFILE)\" -DNEWSSPOOL=\"$(NEWSSPOOL)\" \ -DRSHPATH=\"$(RSHPATH)\" -DLOCKPGM=\"$(LOCKPGM)\" \ -DLOCKPGM1=\"$(LOCKPGM1)\" -DLOCKPGM2=\"$(LOCKPGM2)\" \ -DLOCKPGM3=\"$(LOCKPGM3)\" > OSCFLAGS echo $(BASELDFLAGS) $(EXTRALDFLAGS) > LDFLAGS echo "$(ARRC) $(ARCHIVE) $(BINARIES);$(RANLIB) $(ARCHIVE)" > ARCHIVE echo $(OS) > OSTYPE ./drivers $(EXTRADRIVERS) $(DEFAULTDRIVERS) dummy ./mkauths $(EXTRAAUTHENTICATORS) $(DEFAULTAUTHENTICATORS) echo " mail_versioncheck (CCLIENTVERSION);" >> linkage.c $(LN) os_$(OS).h osdep.h $(LN) os_$(OS).c osdepbas.c $(LN) log_$(LOGINPW).c osdeplog.c $(LN) sig_$(SIGTYPE).c siglocal.c $(LN) crx_$(CRXTYPE).c crexcl.c $(LN) ip$(IP)_unix.c ip_unix.c sh -c '(test $(OS) = sc5 -o $(OS) = sco -o ! -f /usr/include/sys/statvfs.h) && echo -DNOFSTATVFS >> OSCFLAGS || fgrep statvfs64 /usr/include/sys/statvfs.h > /dev/null || echo -DNOFSTATVFS64 >> OSCFLAGS'# Password checkersckpafs: # AFS @echo AFS password authentication echo $(AFSCFLAGS) >> OSCFLAGS# echo $(AFSLDFLAGS) >> LDFLAGS# Note: Steve Roseman says that AFS libraries have to be lunk before SSL echo $(AFSLDFLAGS) `$(CAT) LDFLAGS` > LDFLAGS.tmp mv LDFLAGS.tmp LDFLAGS $(LN) ckp_afs.c osdepckp.cckpdce: # DCE @echo DCE password authentication echo $(DCECFLAGS) >> OSCFLAGS echo $(DCELDFLAGS) >> LDFLAGS $(LN) ckp_dce.c osdepckp.cckpgss: # Kerberos V (must have gss EXTRAAUTHENTICATOR as well) @echo Kerberos V password authentication $(LN) ckp_gss.c osdepckp.cckpnul: # NUL authenticator (disables all plaintext authentication) @echo Plaintext authentication prohibited echo " mail_parameters (NIL,SET_DISABLEPLAINTEXT,(void *) 1);" >> linkage.c $(LN) ckp_nul.c osdepckp.cckppam: # Pluggable Authentication Modules authenticator @echo PAM password authentication echo $(PAMLDFLAGS) >> LDFLAGS $(LN) ckp_pam.c osdepckp.cckppmb: # Broken (e.g. SUN) Pluggable Authentication Modules authenticator @echo Broken PAM password authentication echo $(PAMLDFLAGS) >> LDFLAGS $(LN) ckp_pmb.c osdepckp.cckpstd: # Port standard @echo Standard password authentication $(LN) ckp_$(CHECKPW).c osdepckp.cckptwo: # Something plus standard @echo $(CHECKPWALT) password authentication first, then standard $(CAT) ckp_1st.c ckp_$(CHECKPWALT).c ckp_2nd.c ckp_$(CHECKPW).c \ ckp_3rd.c > osdepckp.c# SSL supportsslnone:# No SSL @echo Building without SSL support $(LN) ssl_none.c osdepssl.csslnopwd: sslunix snopwdsslunix.nopwd: sslnopwdsslsco.nopwd: sslsco snopwdsslunix: sbasic sldunixsslsco: sbasic sldscosbasic: # UNIX OpenSSL @echo Building with SSL $(LN) ssl_unix.c osdepssl.c echo $(SSLCFLAGS) >> OSCFLAGS echo " ssl_onceonlyinit ();" >> linkage.csnopwd: # Plaintext disable @echo Building with SSL and plaintext passwords disabled unless SSL/TLS echo " mail_parameters (NIL,SET_DISABLEPLAINTEXT,(void *) 2);" >> linkage.csldunix:# Normal UNIX SSL load flags echo $(SSLLDFLAGS) >> LDFLAGSsldsco: # SCO SSL load flags# Note: Tim Rice says that SSL has to be lunk before other libraries on SCO. echo $(SSLLDFLAGS) `cat LDFLAGS` > LDFLAGS.tmp mv LDFLAGS.tmp LDFLAGS# A monument to a hack of long ago and far away...love: @echo not war?
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -