jwt27 / build-gcc

Shell scripts to build various gcc cross-compilers (primarily djgpp)
https://jw.h4ck.me/debian/
GNU General Public License v3.0
41 stars 9 forks source link

Target directory creation seems to be wrong #34

Closed SuperIlu closed 1 year ago

SuperIlu commented 1 year ago

running ./build-djgpp.sh --target=i586-pc-msdosdjgpp on Arch I get

You are about to build and install:

With the following options:
    TARGET=i586-pc-msdosdjgpp
    HOST=
    BUILD=
    PREFIX=/usr/local/cross
    CC=gcc
    CXX=g++
    CFLAGS=
    CXXFLAGS=
    CFLAGS_FOR_TARGET=-O2 -g -ffunction-sections -fdata-sections
    CXXFLAGS_FOR_TARGET=-O2 -g -ffunction-sections -fdata-sections
    LDFLAGS=
    MAKE=make
    MAKE_JOBS=2
    MAKE_CHECK=
    MAKE_CHECK_GCC=

WARNING: no write access to /usr/local/cross
You may need to enter your sudo password several times during the build process.

If you wish to change anything, press CTRL-C now. Otherwise, press any other key to continue.
Download source files...
Creating install directory: /usr/local/cross
Removing old specs file
Copy long name executables to short name.
/usr/local/cross ~/build-gcc/build
~/build-gcc/build
Installing i586-pc-msdosdjgpp-setenv
cp: cannot create regular file '/usr/local/cross/bin/': Not a directory
Done.
To remove temporary build files, use: rm -rf build/
To remove downloaded source packages, use: rm -rf download/
[ilu@nonpi build-gcc]$

Download and build don't happen? Seems like the script wants to copy to the wrong directory?

[ilu@nonpi build-gcc]$ ll /usr/local/cross/
total 12
drwxr-xr-x  3 root root 4096 Apr  8 18:30 .
drwxr-xr-x 12 root root 4096 Apr  8 18:30 ..
drwxr-xr-x  4 root root 4096 Apr  8 18:30 i586-pc-msdosdjgpp
[ilu@nonpi build-gcc]$ ll /usr/local/cross/i586-pc-msdosdjgpp/
total 16
drwxr-xr-x 4 root root 4096 Apr  8 18:30 .
drwxr-xr-x 3 root root 4096 Apr  8 18:30 ..
drwxr-xr-x 2 root root 4096 Apr  8 18:30 bin
drwxr-xr-x 2 root root 4096 Apr  8 18:30 etc
[ilu@nonpi build-gcc]$
jwt27 commented 1 year ago

You didn't specify what to install, so it doesn't install anything. :)

It's supposed to list available packages/versions though if you don't specify any, but it does count --target=... as one. Will fix.