Closed rumeysayilmaz closed 1 week ago
changing the default indexes (enabling addressindex and spendindex by default) will likely cause all nodes to resync or reindex after the update
addressindex and spendindex as true are critical for marmara to work: some cc functions require them. Those settings are enabled from the chain start
addressindex and spendindex as true are critical for marmara to work: some cc functions require them. Those settings are enabled from the chain start
You're absolutely right—I just mixed up the launch parameters with another chain. In this case, -addressindex=1 -spentindex=1
has been there from the beginning. I've deleted my initial comment.
btw I managed to build marmara.exe (from fresh repo though) on ubuntu 18.04 and 20.04 (libcc.dll present in the src dir too)
btw I managed to build marmara.exe (from fresh repo though) on ubuntu 18.04 and 20.04
Ubuntu 22.04.5 LTS, (fresh repo clone, developement
branch)
Steps to reproduce:
./zcutil/build.sh -j8
- Ok../zcutil/build-win.sh -j8
- Fail with:
make: *** No rule to make target 'libcc.dll', needed by 'marmarad.exe'. Stop.
And in the logs after (6) we can see:
+ echo Making cclib...
Making cclib...
+ ./makecustom
Linux make: Nothing to be done for 'all'. CUSTOMCC BUILD SUCCESSFUL
So, the reason is make reports `Nothing to be done for 'all'` and even didn't try to build `.dll`.
p.s. Confirmed. The Windows build fails if ./src/cc/customcc.so
exists. The following will work:
rm ./src/cc/customcc.so
./zcutil/build-win.sh -j8
However, the following will not:
touch ./src/cc/customcc.so
./zcutil/build-win.sh -j8
So, if customcc.so
remains from previous builds, the Windows binaries will not be built successfully.
p.p.s. And actually, libcc.dll
is not a PE32+ executable (DLL) (console) x86-64, for MS Windows
. It's an Intel amd64 COFF object file
, meaning it's a Linux binary. It’s linked with the resulting binary through this line: marmarad_LDADD += libcc.dll $(LIBSECP256K1)
. If you check the import sections of the resulting PE executable, you’ll see that it has no dependencies on libcc.dll
, meaning it’s being statically linked anyway. 😉
p.p.s. One more note: It’s better to use your own DNS seeder rather than fixed seed nodes. This way, it will be easier to update A-records if the seed nodes change, rather than modifying hardcoded seed nodes.
@DeckerSU How can we do so? Could you explain how this approach can be implemented in the codebase?
Btw, we were unable to get a successful macOS build for marmara due to gcc
. We would like to create another PR for this. We have noticed the following PRs in the komodo release.
How can we adopt these for marmara? We would appreciate your guidance.
you’ll see that it has no dependencies on libcc.dll, meaning it’s being statically linked anyway.
It's built with -c flag. So it is named incorrectly but I guess still needed to build executable
@DeckerSU How can we do so? Could you explain how this approach can be implemented in the codebase?
Adding a DNS seeder to the Marmara codebase is relatively easy to do. First, add your DNS seeder in sources here:
For example:
vSeeds.push_back(CDNSSeedData("Marmara Super DNS Seeder", "mcl.komodoseeds.com"));
Then, create A-records for mcl.komodoseeds.com
that point to your seed nodes. For example, mcl.komodoseeds.com
already contains the IPv4 addresses of the MCL seed nodes. Here's what you'll see if you check it:
dig mcl.komodoseeds.org @1.1.1.1
; <<>> DiG 9.16.50-Debian <<>> mcl.komodoseeds.org @1.1.1.1
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 18827
;; flags: qr rd ra; QUERY: 1, ANSWER: 3, AUTHORITY: 0, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 1232
;; QUESTION SECTION:
;mcl.komodoseeds.org. IN A
;; ANSWER SECTION:
mcl.komodoseeds.org. 300 IN A 5.189.149.242
mcl.komodoseeds.org. 300 IN A 161.97.146.150
mcl.komodoseeds.org. 300 IN A 149.202.158.145
;; Query time: 12 msec
;; SERVER: 1.1.1.1#53(1.1.1.1)
;; WHEN: Fri Sep 20 14:06:32 UTC 2024
;; MSG SIZE rcvd: 96
Do the same for *.marmara.io
by creating A-records that point to your seed nodes. Then, include these updated DNS seeders in the Marmara codebase.
Btw, we were unable to get a successful macOS build for marmara due to
gcc
.
As you mentioned above, the Komodo codebase uses Clang as the native macOS compiler. Therefore, you can follow the same approach. To achieve this, cherry-pick the necessary commits from the Komodo pull request: https://github.com/KomodoPlatform/komodo/pull/618.
It's built with -c flag. So it is named incorrectly but I guess still needed to build executable
Yes, of course, the custom CC library is necessary to build. However, there's no need to explicitly reference its .dll
since it’s not a dynamically linked library. Instead, it's included as a static dependency in the binaries. We should build the static libcc.a
library, as it’s done in the upstream Komodo codebase. The current method of building CCLib not only results in the errors mentioned but also causes confusion.
This PR includes the changes for s8 NN update. We kindly request @DeckerSU and @dimxy to review the changes. Thank you in advance.
Regarding the changes