`chicken-install` will install `c-object` when object name contain "/"

li lu via Chicken-users <[email protected]>
Newsgroups gmane.lisp.scheme.chicken
Message-ID <DS7P223MB1424A4F81167FFA81FA1BF05ECA02@DS7P223MB1424.NAMP223.PROD.OUTLOOK.COM>
Hi all,

I'm porting the egg libyaml from chicken-5 to chicken-6,
The egg uses lots of C sources from another repository,
and statically links the C sources into the egg.

I found that `chicken-install` will install c-object when
the c-object name contains "/" character.
For convenient, here is a minimal example.
- File `./c-source/foo.c`:
  ```
  void foo() {}
  ```
- File `./link-c.scm`:
  ```
  (module link-c (foo)
  (import scheme (chicken foreign))
  (foreign-declare "void foo();")
  (define foo (foreign-lambda void "foo")))
  ```
- File `./link-c.egg`
  ```
  ((components
      (c-object c-source/foo.c (source c-source/foo.c))
      (extension link-c
            (source link-c.scm)
            (objects c-source/foo.c))))
  ```

When run `chicken-install -s -l .`, it will report:
```
install: cannot create regular file '/usr/lib/chicken/12/c-source/foo.c.o': No such file or directory
```

And the file `link-c.install.sh` did contain the line:
```
install -m 644 '/tmp/chicken-install-bug/c-source/foo.c.o' "${DESTDIR}"'/usr/lib/chicken/12/c-source/foo.c.o'
```

Since the egg had been built by chicken-5 on versions,
I think it might be a bug of `chicken-install` in chicken-6.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.