mirror of
https://gitee.com/openharmony/third_party_cups
synced 2024-11-23 09:59:45 +00:00
commit
ce9f0ec99c
70
BUILD.gn
70
BUILD.gn
@ -29,6 +29,7 @@ group("third_party_cups") {
|
||||
deps = [
|
||||
":cups",
|
||||
":cups-deviced",
|
||||
":cups-driverd",
|
||||
":cups-exec",
|
||||
":cupsd",
|
||||
":cupsfilter",
|
||||
@ -45,7 +46,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 +190,57 @@ 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 +375,24 @@ 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" ]
|
||||
|
||||
|
@ -24,7 +24,8 @@
|
||||
"components": [],
|
||||
"third_party": [
|
||||
"zlib",
|
||||
"openssl"
|
||||
"openssl",
|
||||
"libusb"
|
||||
]
|
||||
},
|
||||
"build": {
|
||||
|
4
config.h
4
config.h
@ -26,7 +26,7 @@
|
||||
#define CUPS_DEFAULT_SYSTEM_AUTHKEY ""
|
||||
#define CUPS_DEFAULT_CONFIG_FILE_PERM 0640
|
||||
#define CUPS_DEFAULT_LOG_FILE_PERM 0644
|
||||
#define CUPS_DEFAULT_LOG_LEVEL "warn"
|
||||
#define CUPS_DEFAULT_LOG_LEVEL "debug2"
|
||||
#define CUPS_DEFAULT_ACCESS_LOG_LEVEL "none"
|
||||
#define CUPS_DEFAULT_MAX_LOG_SIZE "1m"
|
||||
#define CUPS_DEFAULT_FATAL_ERRORS "config"
|
||||
@ -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
|
||||
|
11
cups.gni
11
cups.gni
@ -15,25 +15,24 @@ 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"
|
||||
cups_serverbin_dir = "bin/cups"
|
||||
cups_data_dir = "$CUPS_SERVICE_DATA_DIR/share"
|
||||
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/\"",
|
||||
"CUPS_LOGDIR = \"$CUPS_SERVICE_DATA_DIR/log\"",
|
||||
|
||||
"CUPS_SERVERROOT = \"$CUPS_SERVICE_DATA_DIR/\"",
|
||||
"CUPS_SERVERROOT = \"$CUPS_SERVICE_DATA_DIR\"",
|
||||
"CUPS_CACHEDIR = \"$CUPS_SERVICE_DATA_DIR/cache\"",
|
||||
"CUPS_REQUESTS = \"$CUPS_SERVICE_DATA_DIR/spool\"",
|
||||
"CUPS_STATEDIR = \"$CUPS_SERVICE_DATA_DIR/run\"",
|
||||
|
Loading…
Reference in New Issue
Block a user