simplify handring of printer model.

This commit is contained in:
Hajimu UMEMOTO 2004-08-29 09:31:34 +00:00
parent 99c126e32b
commit f8948d7b83
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=117553

View File

@ -24,6 +24,25 @@ DIST_TYPE= lpr
DIST_TYPE?= lpr_and_caps
PRTTYPE_PREFIX= ${PRTYPE:C|^([^0-9]+)[0-9]+.*$|\1|}
.if ${PRTTYPE_PREFIX} == -sc
PRT_MODEL= ${PRTYPE:U:S/^-//}
.elif ${PRTYPE} == 790
PRT_MODEL= PM${PRTYPE}PT
.elif ${PRTYPE} == "780cs"
PRT_MODEL= PM${PRTYPE:U}
.elif ${PRTYPE} == "820ug"
PRT_MODEL= PM820CUG
.elif ${PRTYPE} == 4000
PRT_MODEL= PM${PRTYPE}PX
.elif ${PRTTYPE_PREFIX} == v || ${PRTYPE} == g900
PRT_MODEL= PX${PRTYPE:U}
.elif ${PRTTYPE_PREFIX} == g
PRT_MODEL= PM${PRTYPE:U}
.else
PRT_MODEL= PM${PRTYPE}C
.endif
.if ${PRTTYPE_PREFIX} == -sc
MASTER_SITE_SUBDIR= ${PRTYPE:C|^-(sc[0-9]+)s$|\1|}
.elif ${PRTYPE} == 730
@ -33,20 +52,16 @@ MASTER_SITE_SUBDIR= pm750c_2000clpr
.elif ${PRTYPE} == 780 || ${PRTYPE} == 880
MASTER_SITE_SUBDIR= ${PRTYPE}_20
.elif ${PRTYPE} == 970
MASTER_SITE_SUBDIR= PM${PRTYPE}C
MASTER_SITE_SUBDIR= ${PRT_MODEL}
.elif ${PRTYPE} == 3500
MASTER_SITE_SUBDIR= pm${PRTYPE}c
.elif ${PRTYPE} == 4000
MASTER_SITE_SUBDIR= pm${PRTYPE}pxlpr
.elif ${PRTYPE} == g900
MASTER_SITE_SUBDIR= px${PRTYPE}lpr
.elif ${PRTTYPE_PREFIX} == g
MASTER_SITE_SUBDIR= pm${PRTYPE}lpr
MASTER_SITE_SUBDIR= ${PRT_MODEL:L}
.elif ${PRTYPE} == 4000 || ${PRTTYPE_PREFIX} == g
MASTER_SITE_SUBDIR= ${PRT_MODEL:L}lpr
.elif ${PRTTYPE_PREFIX} == v
.if ${DIST_TYPE} == cups
MASTER_SITE_SUBDIR= px${PRTYPE}cups
MASTER_SITE_SUBDIR= ${PRT_MODEL:L}cups
.else
MASTER_SITE_SUBDIR= px${PRTYPE}lpr
MASTER_SITE_SUBDIR= ${PRT_MODEL:L}lpr
.endif
.elif ${PIPS_LEVEL} == 201
MASTER_SITE_SUBDIR= ${PRTYPE}_21
@ -55,7 +70,7 @@ MASTER_SITE_SUBDIR= ${PRTYPE}Ccups
.elif ${PIPS_MAJOR} >= 2 && ${DIST_TYPE} == lpr
MASTER_SITE_SUBDIR= ${PRTYPE}Clpr
.else
MASTER_SITE_SUBDIR= pm${PRTYPE}clpr
MASTER_SITE_SUBDIR= ${PRT_MODEL:L}lpr
.endif
MAINTAINER= ume@FreeBSD.org
@ -140,41 +155,8 @@ CPPFLAGS+= ${PTHREAD_CFLAGS}
CONFIGURE_ENV+= CFLAGS="${CFLAGS}" CPPFLAGS="${CPPFLAGS}" LDFLAGS="${LDFLAGS}"
MAKE_ENV+= SED="${SED}"
.if ${PRTTYPE_PREFIX} == -sc
LIB_FILE= lib${PRTYPE:S/^-//}.so
MODEL_FILE= ekpm${PRTYPE:S/^-//}.ppd
PRT_MODEL= ${PRTYPE:U:S/^-//}
.else
.if ${PRTYPE} == 790
LIB_FILE= libpm${PRTYPE}pt.so
MODEL_FILE= ekpm${PRTYPE}pt.ppd
PRT_MODEL= PM${PRTYPE}PT
.elif ${PRTYPE} == "780cs"
LIB_FILE= libpm${PRTYPE}.so
MODEL_FILE= ekpm${PRTYPE}.ppd
PRT_MODEL= PM${PRTYPE:U}
.elif ${PRTYPE} == "820ug"
LIB_FILE= libpm820cug.so
MODEL_FILE= ekpm${PRTYPE}cug.ppd
PRT_MODEL= PM820CUG
.elif ${PRTYPE} == 4000
LIB_FILE= libpm${PRTYPE}px.so
MODEL_FILE= ekpm${PRTYPE}px.ppd
PRT_MODEL= PM${PRTYPE}PX
.elif ${PRTTYPE_PREFIX} == v || ${PRTYPE} == g900
LIB_FILE= libpx${PRTYPE}.so
MODEL_FILE= ekpx${PRTYPE}.ppd
PRT_MODEL= PX${PRTYPE:U}
.elif ${PRTTYPE_PREFIX} == g
LIB_FILE= libpm${PRTYPE}.so
MODEL_FILE= ekpm${PRTYPE}.ppd
PRT_MODEL= PM${PRTYPE:U}
.else
LIB_FILE= libpm${PRTYPE}c.so
MODEL_FILE= ekpm${PRTYPE}c.ppd
PRT_MODEL= PM${PRTYPE}C
.endif
.endif
LIB_FILE= lib${PRT_MODEL:L}.so
MODEL_FILE= ek${PRT_MODEL:L}.ppd
.if ${PIPS_LEVEL} == 201 || (${PIPS_LEVEL} >= 205 && ${DIST_TYPE} == lpr)
EKPNAVI_VER= 1.1.2