mirror of
https://gitee.com/openharmony/third_party_cups
synced 2024-11-26 19:40:32 +00:00
Adaptable printer driver Singed-off-by:dongzhengkuan@huawei.com
Signed-off-by: 15549494042 <dongzhengkuan@huawei.com>
This commit is contained in:
parent
fee18c4c16
commit
dfadccc558
82
BUILD.gn
82
BUILD.gn
@ -36,6 +36,11 @@ group("third_party_cups") {
|
||||
":mime.convs",
|
||||
":mime.types",
|
||||
":rastertopwg",
|
||||
":usb",
|
||||
":lpinfo",
|
||||
":lpadmin",
|
||||
":lp",
|
||||
":cups-driverd"
|
||||
]
|
||||
}
|
||||
|
||||
@ -45,7 +50,7 @@ config("cups_config") {
|
||||
"$config_dir",
|
||||
"$cups_code_dir",
|
||||
"$core_code_dir",
|
||||
"//third_party/libusb/libusb",
|
||||
"//third_party/libusb/libusb-1.0.26/libusb",
|
||||
"//third_party/openssl/include",
|
||||
]
|
||||
|
||||
@ -189,8 +194,64 @@ ohos_executable("ipp") {
|
||||
part_name = "$PART_NAME"
|
||||
}
|
||||
|
||||
ohos_executable("usb") {
|
||||
sources = [
|
||||
"$backend_code_dir/usb.c"
|
||||
]
|
||||
|
||||
deps = [
|
||||
"//third_party/cups:backend",
|
||||
"//third_party/cups:cups",
|
||||
"//third_party/libusb:libusb"
|
||||
]
|
||||
|
||||
install_enable = true
|
||||
module_install_dir = "$cups_serverbin_dir/backend"
|
||||
public_configs = [ ":cups_config" ]
|
||||
subsystem_name = "$SUBSYSTEM_NAME"
|
||||
part_name = "$PART_NAME"
|
||||
}
|
||||
#end of backend
|
||||
|
||||
ohos_executable("lpadmin") {
|
||||
sources = [ "$cups_code_dir/systemv/lpadmin.c" ]
|
||||
|
||||
deps = [
|
||||
"//third_party/cups:cups",
|
||||
]
|
||||
|
||||
install_enable = true
|
||||
public_configs = [ ":cups_config" ]
|
||||
subsystem_name = "$SUBSYSTEM_NAME"
|
||||
part_name = "$PART_NAME"
|
||||
}
|
||||
|
||||
ohos_executable("lpinfo") {
|
||||
sources = [ "$cups_code_dir/systemv/lpinfo.c" ]
|
||||
|
||||
deps = [
|
||||
"//third_party/cups:cups",
|
||||
]
|
||||
|
||||
install_enable = true
|
||||
public_configs = [ ":cups_config" ]
|
||||
subsystem_name = "$SUBSYSTEM_NAME"
|
||||
part_name = "$PART_NAME"
|
||||
}
|
||||
|
||||
ohos_executable("lp") {
|
||||
sources = [ "$cups_code_dir/systemv/lp.c" ]
|
||||
|
||||
deps = [
|
||||
"//third_party/cups:cups",
|
||||
]
|
||||
|
||||
install_enable = true
|
||||
public_configs = [ ":cups_config" ]
|
||||
subsystem_name = "$SUBSYSTEM_NAME"
|
||||
part_name = "$PART_NAME"
|
||||
}
|
||||
|
||||
#ppdc
|
||||
ohos_shared_library("cupsppdc") {
|
||||
sources = [
|
||||
@ -325,6 +386,25 @@ ohos_executable("cups-deviced") {
|
||||
part_name = "$PART_NAME"
|
||||
}
|
||||
|
||||
ohos_executable("cups-driverd") {
|
||||
sources = [
|
||||
"$scheduler_code_dir/cups-driverd.cxx",
|
||||
"$scheduler_code_dir/util.c",
|
||||
]
|
||||
|
||||
deps = [
|
||||
"//third_party/cups:cups",
|
||||
"//third_party/cups:cupsppdc",
|
||||
]
|
||||
|
||||
install_enable = true
|
||||
module_install_dir = "$cups_serverbin_dir/daemon"
|
||||
public_configs = [ ":cups_config" ]
|
||||
subsystem_name = "$SUBSYSTEM_NAME"
|
||||
part_name = "$PART_NAME"
|
||||
}
|
||||
|
||||
|
||||
ohos_executable("cups-exec") {
|
||||
sources = [ "$scheduler_code_dir/cups-exec.c" ]
|
||||
|
||||
|
2
config.h
2
config.h
@ -34,7 +34,7 @@
|
||||
#define CUPS_DEFAULT_BROWSE_LOCAL_PROTOCOLS ""
|
||||
#define CUPS_DEFAULT_DEFAULT_SHARED 0
|
||||
#define CUPS_DEFAULT_IPP_PORT 1631
|
||||
#define CUPS_DEFAULT_PRINTCAP "/data/service/el1/public/cups/printcap"
|
||||
#define CUPS_DEFAULT_PRINTCAP "/data/service/el1/public/print_service/cups/printcap"
|
||||
#define CUPS_DEFAULT_ERROR_POLICY "stop-printer"
|
||||
#define CUPS_DEFAULT_MAX_COPIES 9999
|
||||
#define CUPS_DEFAULT_WEBIF 0
|
||||
|
6
cups.gni
6
cups.gni
@ -15,7 +15,7 @@ cups_path = rebase_path("//third_party/cups")
|
||||
exec_script("install.sh", [ "$cups_path" ])
|
||||
print("cups installed successfully")
|
||||
|
||||
CUPS_SERVICE_DATA_DIR = "/data/service/el1/public/cups"
|
||||
CUPS_SERVICE_DATA_DIR = "/data/service/el1/public/print_service/cups"
|
||||
|
||||
cups_bin_dir = "bin"
|
||||
cups_sbin_dir = "bin"
|
||||
@ -26,9 +26,9 @@ init_service_cfg_path = "etc/init"
|
||||
cups_defines = [
|
||||
"CUPS_BINDIR = \"/system/$cups_bin_dir\"",
|
||||
"CUPS_SBINDIR = \"/system/$cups_sbin_dir\"",
|
||||
"CUPS_SERVERBIN = \"/system/bin/cups\"",
|
||||
"CUPS_SERVERBIN = \"$CUPS_SERVICE_DATA_DIR/serverbin\"",
|
||||
|
||||
"CUPS_DATADIR = \"/system/etc/cups/share\"",
|
||||
"CUPS_DATADIR = \"$CUPS_SERVICE_DATA_DIR/datadir\"",
|
||||
"CUPS_DOCROOT = \"$CUPS_SERVICE_DATA_DIR/doc\"",
|
||||
"CUPS_LOCALEDIR = \"$CUPS_SERVICE_DATA_DIR/locale\"",
|
||||
"CUPS_LOGDIR = \"$CUPS_SERVICE_DATA_DIR/log/\"",
|
||||
|
Loading…
Reference in New Issue
Block a user