AutomationD / esp-alt-sdk

❌This repo is not maintained anymore❌
20 stars 6 forks source link

Tools #4

Closed AutomationD closed 8 years ago

Juppit commented 8 years ago

Hi, do you like some more comments from me? ;-) I made some changes in Makefile:

+GCC_VERSION = 4.9.2

-GCC_DIR = gcc-xtensa
+GCC_DIR = gcc-$(GCC_VERSION)

There are still issues in gcc version 4.8.2, I have no found solutions for. So I use 4.9.2 or 5.1 from https://github.com/jcmvbkbc There is a patch from jcmvbkbc for 5.1 which works for me on cygwin even at version 4.9.2 This patch appends " && 0" at line 41 in following file: gcc-dir/libstdc++-v3/include/std/type_traits, so it looks like this:

# if defined (__UINT_LEAST16_TYPE__) && defined(__UINT_LEAST32_TYPE__) && 0

I hade to uncomment following lines in Makefile:

        # cd $(XTDLP)/$(ESPTOOL_DIR); pyinstaller --onefile esptool.py
        # cd $(XTDLP)/$(ESPTOOL_DIR)/dist; cp esptool.exe $(UTILS_DIR)/

because I miss pyinstaller (and don't need the tools)

Next there are more tools I don't need and I do not have the program mcs:

    # cd $(XTDLP)/$(MEMANALYZER_DIR)/MemAnalyzer/; mcs Program.cs

        # cd $(XTDLP)/$(MEMANALYZER_DIR)/MemAnalyzer/; cp Program.exe $(UTILS_DIR)/memanalyzer.exe

This tool stuff should be configurable.

Last one: After the second or third run I uncommented the untar command for gdb, which is really annoying after a while...

greetings

AutomationD commented 8 years ago

Thanks for your comments. GCC - good point, as soon as I'm done with fully building and packaging (very soon), I'll work on the next gcc version, should be no issue.

All environment should be built by scripts in env/, like env/ubuntu_10.cmd

I introduced some configs like make PREBUILT_TOOLCHAIN which uses toolchain from here. More to come:)

pyinstaller and mcs are just packages, that are very easy to install for all platforms (no need in pyinstaller for windows). Also, should be useful to add certain parameter like make NO_UTILS=y.

Juppit commented 8 years ago

One last:

 # GDB
 $(XTDLP)/$(GDB_DIR)/configure.ac: $(XTDLP)/$(GDB_TAR)
    mkdir -p $(XTDLP)/$(GDB_DIR)
    $(UNTAR) $(XTDLP)/$(GDB_TAR) -C $(XTDLP)/$(GDB_DIR)
    mv $(XTDLP)/$(GDB_DIR)/gdb-*/* $(XTDLP)/$(GDB_DIR)

there is no move needed, and this move builds a new one unneccasary

Juppit commented 8 years ago

I had zero problems with gcc-4.9.2 and 5.1, with this little patch https://github.com/jcmvbkbc/crosstool-NG/blob/b38a1d4cb9f0179a1da5c210e476aa2c9229bb94/local-patches/gcc/5.1.0/0001-WIP-don-t-bring-extra-u-int_least32_t-into-std.patch

AutomationD commented 8 years ago

@Juppit by the way, did you make gdb built this way work? I'm missing some python stuff.

Juppit commented 8 years ago

Gdb compiled fine (you know, simply type make in a cygwin terminal). I also can start gdb in terminal, but I do not know, what I can do with it.

Am 20.12.2015 um 20:26 schrieb Dmitry Kireev:

@Juppit https://github.com/Juppit by the way, did you make gdb built this way work? I'm missing some python stuff.

— Reply to this email directly or view it on GitHub https://github.com/kireevco/esp-alt-sdk/pull/4#issuecomment-166148674.

AutomationD commented 8 years ago

@Juppit it's gdbstub from espressif that is supposed to make it work. You include it in the code, and it exposes stuff to your gdb debugger. Did you build gdb from the same source as I did? (gnu ftp)?

Juppit commented 8 years ago

Once again:

  1. clone your git repo (https://github.com/kireevco/esp-alt-sdk.git)
  2. git submodule add -b call0-4.9.2 https://github.com/jcmvbkbc/gcc-xtensa.git src/gcc-4.9.2 (so got one more submodule)
  3. make some small changes in Makefile as I described:
    • use gcc-4.9.2 instead gcc-xtensa
    • patch this one file type_traits
  4. enter the directory esp-alt-sdk and type make

that's really all (except waaaaaiiiiting)

Am 20.12.2015 um 23:26 schrieb Dmitry Kireev:

@Juppit https://github.com/Juppit it's gdbstub from espressif that is supposed to make it work. Did you build gdb from the same source as I did? (gnu ftp)?

— Reply to this email directly or view it on GitHub https://github.com/kireevco/esp-alt-sdk/pull/4#issuecomment-166159344.

AutomationD commented 8 years ago

@Juppit Oh, so gdb from here works, good.

You could submit a PR, by the way, maybe to https://github.com/kireevco/esp-alt-sdk/tree/gcc-4.9.2 ?

Otherwise I'll do that a little bit later.

Also, keep in mind, that main platform I'm using is mingw, which is most of users, but usually it is much more naughty than cygwin :)

Juppit commented 8 years ago

Yes I try to submit a PR, but I'm not as practiced in GIT and also not in English, so I need my time :-)

Am 20.12.2015 um 23:55 schrieb Dmitry Kireev:

@Juppit https://github.com/Juppit Oh, so gdb from here works, good.

You could submit a PR, by the way, maybe to https://github.com/kireevco/esp-alt-sdk/tree/gcc-4.9.2 ?

Otherwise I'll do that a little bit later.

Also, keep in mind, that main platform I'm using is mingw, which is most of users, but usually it is much more naughty than cygwin :)

— Reply to this email directly or view it on GitHub https://github.com/kireevco/esp-alt-sdk/pull/4#issuecomment-166161309.

AutomationD commented 8 years ago

@Juppit

  1. fork my repo
  2. push changes to your repo
  3. Create pr between your repo and branch gcc-4.9.2 in my repo.

Take your time, and thank you very much for the contribution :)