Package Details: cups-bjnp 2.0.3-3

Git Clone URL: https://aur.archlinux.org/cups-bjnp.git (read-only, click to copy)
Package Base: cups-bjnp
Description: CUPS back-end for the canon printers using the proprietary USB over IP BJNP protocol
Upstream URL: http://sourceforge.net/projects/cups-bjnp/
Licenses: GPL
Submitter: None
Maintainer: Skythrew
Last Packager: Skythrew
Votes: 60
Popularity: 0.86
First Submitted: 2008-11-29 06:34 (UTC)
Last Updated: 2023-05-26 16:01 (UTC)

Latest Comments

1 2 3 Next › Last »

guoxh commented on 2023-05-19 13:52 (UTC)

@Skythrew I do not use this driver anymore and will disown it. Please consider adopting the package and modifying it directly.

Skythrew commented on 2023-05-18 15:03 (UTC)

Please correct configure script to disable Werrors because it's causing some errors on compiling nowadays.

guoxh commented on 2023-03-25 14:39 (UTC)

@dreieck Do you still have the problem with the current PKGBUILD? LTO was disabled in last update, as a workaround.

dreieck commented on 2023-03-24 18:29 (UTC)

Can this be fixed in the PKGBUILD, please; and a probable coding error be reported upstream?

Regards!

Maxr commented on 2022-06-02 10:33 (UTC)

@dreieck works for me, thank you!

piater commented on 2022-05-28 07:37 (UTC)

@dreieck: I got the same error. To me, writing 1 byte into a region of size 0 looks like a scary bug, and the fact that LTO stumbles over it prompted me to try turning this off first. But the real issue and why it is not flagged without LTO merit further investigation.

dreieck commented on 2022-05-27 16:16 (UTC)

I think somewhere an option -Wno-error=stringop-overflow= or just a general -Wno-error needs to be explicitly added to the gcc options (i.e. the CFLAGS/ CXXFLAGS). I get a -Werror=stringop-overflow= compilation error, and I have not set manually any -Werror option:

gcc -Wall  -Werror  -g0 -march=x86-64 -mtune=native -O3 -flto -pipe -fstack-protector --param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -fomit-frame-pointer -fPIC  -Wl,-O1,--sort-common,--as-needed,-z,relro,--hash-style=gnu -o bjnp bjnp-bjnp.o bjnp-bjnp-runloop.o bjnp-bjnp-io.o bjnp-bjnp-debug.o bjnp-bjnp-utils.o bjnp-bjnp-discover.o bjnp-bjnp-commands.o bjnp-bjnp-levels.o -lcups 
In function ‘bjnp_backendGetDeviceID’,
    inlined from ‘bjnp_backendRunLoop’ at bjnp-runloop.c:256:29,
    inlined from ‘main’ at bjnp.c:394:18:
bjnp-io.c:505:31: error: writing 1 byte into a region of size 0 [-Werror=stringop-overflow=]
  505 |     device_id[device_id_size] = '\0';
      |                               ^
bjnp-runloop.c: In function ‘main’:
bjnp-runloop.c:74:10: note: at offset 1024 into destination object ‘dev_id’ of size 1024
   74 |     char dev_id[BJNP_IEEE1284_MAX];       /* IEEE1284 device id */
      |          ^
In function ‘bjnp_backendGetDeviceID’,
    inlined from ‘bjnp_backendRunLoop’ at bjnp-runloop.c:256:29,
    inlined from ‘main’ at bjnp.c:394:18:
bjnp-io.c:508:33: error: writing 1 byte into a region of size 0 [-Werror=stringop-overflow=]
  508 |     make_model[make_model_size] = '\0';
      |                                 ^
bjnp-runloop.c: In function ‘main’:
bjnp-runloop.c:73:10: note: at offset 64 into destination object ‘model’ of size 64
   73 |     char model[BJNP_MODEL_MAX];           /* printer make & model */
      |          ^
lto1: all warnings being treated as errors
lto-wrapper: fatal error: gcc returned 1 exit status
compilation terminated.
/usr/bin/ld: error: lto-wrapper failed

For me the problem was mitigated with adding

  CFLAGS+=' -Wno-error'
  CXXFLAGS+=' -Wno-error'
  export CFLAGS
  export CXXFLAGS

before the ./configure call.

Btw., I could compile it with LTO.

Thanks for maintaining!

piater commented on 2022-05-27 08:17 (UTC)

Compilation fails with LTO enabled (which is the default, at least on my system). A workaround is to add the line "options=('!lto')" to the PKGBUILD.

ported commented on 2019-07-28 18:29 (UTC)

Compiling on GCC 8.1+ is fixed, many thanks to @ThoSTe and sorry for the delay.