[SOLVED] Searching source codes

Post new topic   Reply to topic    DD-WRT Forum Index -> General Questions
Goto page 1, 2, 3  Next
Author Message
mwchang
DD-WRT Guru


Joined: 26 Mar 2013
Posts: 1855
Location: Hung Hom, Hong Kong

PostPosted: Wed Aug 24, 2022 4:48    Post subject: [SOLVED] Searching source codes Reply with quote
Could I search the source codes of DD-WRT via https://svn.dd-wrt.com/browser? Do I have to login in order to do so?

If not, how do I download all source codes for reading?


_________________
Router: Asus RT-N18U (rev. A1)

Drink, Blink, Stretch! Live long and prosper! May the Force and farces be with you!

Facebook: https://www.facebook.com/changmanwai
Website: https://sites.google.com/site/changmw
SETI@Home profile: http://setiathome.berkeley.edu/view_profile.php?userid=211832
GitHub: https://github.com/changmw/changmw
Sponsor
the-joker
DD-WRT Developer/Maintainer


Joined: 31 Jul 2021
Posts: 2146
Location: All over YOUR webs

PostPosted: Wed Aug 24, 2022 9:21    Post subject: How to use a search engine instead of... Reply with quote
No you dont need to login to browse, its kinda obvious when you visit https://svn.dd-wrt.com/browser you are presented with a directory list you want the one named src, Click and blabla

You can also browse the GitHub Mirror https://github.com/mirror/dd-wrt -- I use that more often than not when I dont have my dev environment booted its also easier and prettier and searching is also a bit better. Apologies for not teaching you everything, thats what search engines are for.

To download source via svn (yes its better because you can keep the sourcecode updated with simple commands (with it installed type svn help or whatever), you need a Linux OS and svn installed, once that is done you can simply execute svn checkout https://svn.dd-wrt.com/DD-WRT somereponameherewhateveryoulike. Or something like that, been a while since I used svn.

It needs to be a Linux OS, due to paths lengths and other minutia, if you get errors google them and solutions will popup.

Do not try this on Windows, unless you're some kind of masochist.

_________________
Saving your retinas from the burn!🔥
DD-WRT Inspired themes for routers
DD-WRT Inspired themes for the phpBB Forum
DD-WRT Inspired themes for the SVN Trac & FTP site
Join in for a chat @ #style_it_themes_public:matrix.org or #style_it_themes:discord

DD-WRT UI Themes Bug Reporting and Discussion thread

Router: ANus RT-AC68U E1 (recognized as C1)
mwchang
DD-WRT Guru


Joined: 26 Mar 2013
Posts: 1855
Location: Hung Hom, Hong Kong

PostPosted: Wed Aug 24, 2022 11:20    Post subject: Re: How to use a search engine instead of... Reply with quote
the-joker wrote:
You can also browse the GitHub Mirror https://github.com/mirror/dd-wrt -- I use that more often than not when I dont have my dev environment booted its also easier and prettier and searching is also a bit better. Apologies for not teaching you everything, thats what search engines are for.

Master Joker, too early to apologize! Not before I try downloading ... Wink


_________________
Router: Asus RT-N18U (rev. A1)

Drink, Blink, Stretch! Live long and prosper! May the Force and farces be with you!

Facebook: https://www.facebook.com/changmanwai
Website: https://sites.google.com/site/changmw
SETI@Home profile: http://setiathome.berkeley.edu/view_profile.php?userid=211832
GitHub: https://github.com/changmw/changmw
the-joker
DD-WRT Developer/Maintainer


Joined: 31 Jul 2021
Posts: 2146
Location: All over YOUR webs

PostPosted: Wed Aug 24, 2022 12:00    Post subject: Reply with quote
There are plenty of guides on the internet that you can read on how to use svn.

Last time I used svn was back in the day when I developed stuff for the original and the only xbox (and console) I have ever owned. Its modded both hardware and software side and doing this for others use to be a good money earner. Ah the good old days.

_________________
Saving your retinas from the burn!🔥
DD-WRT Inspired themes for routers
DD-WRT Inspired themes for the phpBB Forum
DD-WRT Inspired themes for the SVN Trac & FTP site
Join in for a chat @ #style_it_themes_public:matrix.org or #style_it_themes:discord

DD-WRT UI Themes Bug Reporting and Discussion thread

Router: ANus RT-AC68U E1 (recognized as C1)
dale_gribble39
DD-WRT Guru


Joined: 11 Jun 2022
Posts: 1899

PostPosted: Wed Aug 24, 2022 14:31    Post subject: Reply with quote
Under source retrieval:

Development - DD-WRT Wiki

Everything below svn and github info is severely outdated and I was told not to create a new thread about how to compile images from source or anything related to development. You don't necessarily want or need to change anything from retrieving via svn from those instructions for fairly obvious reasons. The note about Linux 3.18-rc4.diff only applies if you back-track quite a ways and rather moot on which code retrieval method you use - however, doing a checkout with svn is the safer bet overall.

Code:
svn co svn://svn.dd-wrt.com/DD-WRT

Code:
git clone https://github.com/mirror/dd-wrt.git

_________________
"The woods are lovely, dark and deep,
But I have promises to keep,
And miles to go before I sleep,
And miles to go before I sleep." - Robert Frost

"I am one of the noticeable ones - notice me" - Dale Frances McKenzie Bozzio

<fact>code knows no gender</fact>

This is me, knowing I've ruffled your feathers, and not giving a ****
Some people are still hard-headed.

--------------------------------------
Mac Pro (Mid 2012) - Two 2.4GHz 6-Core Intel Xeon E5645 processors 64GB 1333MHz DDR3 ECC SDRAM OpenSUSE Leap 15.5
mwchang
DD-WRT Guru


Joined: 26 Mar 2013
Posts: 1855
Location: Hung Hom, Hong Kong

PostPosted: Wed Aug 24, 2022 16:15    Post subject: Reply with quote
dale_gribble39 wrote:
Everything below svn and github info is severely outdated and I was told not to create a new thread about how to compile images from source or anything related to development. You don't necessarily want or need to change anything from retrieving via svn from those instructions for fairly obvious reasons. The note about Linux 3.18-rc4.diff only applies if you back-track quite a ways and rather moot on which code retrieval method you use - however, doing a checkout with svn is the safer bet overall.

I don't plan on compiling the source codes. I just wanna read and find out how something works, and hopefully I could suggest some changes to improve it. Wink

For that, I surely want to read and SEARCH the latest committed C codes.

_________________
Router: Asus RT-N18U (rev. A1)

Drink, Blink, Stretch! Live long and prosper! May the Force and farces be with you!

Facebook: https://www.facebook.com/changmanwai
Website: https://sites.google.com/site/changmw
SETI@Home profile: http://setiathome.berkeley.edu/view_profile.php?userid=211832
GitHub: https://github.com/changmw/changmw
the-joker
DD-WRT Developer/Maintainer


Joined: 31 Jul 2021
Posts: 2146
Location: All over YOUR webs

PostPosted: Wed Aug 24, 2022 16:18    Post subject: Reply with quote
Suggestions are great, better than suggestions are patches.

And from experience unless you know git, it is not straight forward clone you will need to resolve many issues, however I never tried cloning with svn so no idea any quirks that side, I work using a git clone of the mirror and update it easily when I'm working on a patch.

Both are good ways to get the source code in a way that you can read and keep updated via simple commands.

There is a lazy way using the GitHub mirror https://github.com/mirror/dd-wrt/archive/refs/heads/master.zip but that will not be up-to-date soon as changes are made and you wont be able to keep it updated unless you download every so often.

_________________
Saving your retinas from the burn!🔥
DD-WRT Inspired themes for routers
DD-WRT Inspired themes for the phpBB Forum
DD-WRT Inspired themes for the SVN Trac & FTP site
Join in for a chat @ #style_it_themes_public:matrix.org or #style_it_themes:discord

DD-WRT UI Themes Bug Reporting and Discussion thread

Router: ANus RT-AC68U E1 (recognized as C1)


Last edited by the-joker on Wed Aug 24, 2022 17:06; edited 2 times in total
egc
DD-WRT Guru


Joined: 18 Mar 2014
Posts: 12834
Location: Netherlands

PostPosted: Wed Aug 24, 2022 16:19    Post subject: Reply with quote
If you are Windows only you can try: TortoiseSVN
https://tortoisesvn.net/

_________________
Routers:Netgear R7000, R6400v1, R6400v2, EA6900 (XvortexCFE), E2000, E1200v1, WRT54GS v1.
Install guide R6400v2, R6700v3,XR300:https://forum.dd-wrt.com/phpBB2/viewtopic.php?t=316399
Install guide R7800/XR500: https://forum.dd-wrt.com/phpBB2/viewtopic.php?t=320614
Forum Guide Lines (important read):https://forum.dd-wrt.com/phpBB2/viewtopic.php?t=324087
mwchang
DD-WRT Guru


Joined: 26 Mar 2013
Posts: 1855
Location: Hung Hom, Hong Kong

PostPosted: Wed Aug 24, 2022 16:21    Post subject: Reply with quote
the-joker wrote:
Suggestions are great, better than suggestions are patches.

That would be *AFTER* I read and understand the C codes found, Master Joker!

_________________
Router: Asus RT-N18U (rev. A1)

Drink, Blink, Stretch! Live long and prosper! May the Force and farces be with you!

Facebook: https://www.facebook.com/changmanwai
Website: https://sites.google.com/site/changmw
SETI@Home profile: http://setiathome.berkeley.edu/view_profile.php?userid=211832
GitHub: https://github.com/changmw/changmw
mwchang
DD-WRT Guru


Joined: 26 Mar 2013
Posts: 1855
Location: Hung Hom, Hong Kong

PostPosted: Wed Aug 24, 2022 16:22    Post subject: Reply with quote
egc wrote:
If you are Windows only you can try: TortoiseSVN
https://tortoisesvn.net/

Thanks! I could also use a Linux VM to download the codes using Linux tools, then access them from some familiar Window$ editors via Samba.

Ddid I forget that Entware of DD-WRT might have those Linux tools to download source codes? Smile

_________________
Router: Asus RT-N18U (rev. A1)

Drink, Blink, Stretch! Live long and prosper! May the Force and farces be with you!

Facebook: https://www.facebook.com/changmanwai
Website: https://sites.google.com/site/changmw
SETI@Home profile: http://setiathome.berkeley.edu/view_profile.php?userid=211832
GitHub: https://github.com/changmw/changmw
the-joker
DD-WRT Developer/Maintainer


Joined: 31 Jul 2021
Posts: 2146
Location: All over YOUR webs

PostPosted: Wed Aug 24, 2022 16:27    Post subject: Reply with quote
egc wrote:
If you are Windows only you can try: TortoiseSVN
https://tortoisesvn.net/


I Dont recommend Windows for the DD-WRT source, path length alone errors will be abound and when it comes to the PCI stuff filenames it will error out more.

Not for the novices, and even myself couldnt do a windows full clone and gave up as it was faster and easier using Linux.

_________________
Saving your retinas from the burn!🔥
DD-WRT Inspired themes for routers
DD-WRT Inspired themes for the phpBB Forum
DD-WRT Inspired themes for the SVN Trac & FTP site
Join in for a chat @ #style_it_themes_public:matrix.org or #style_it_themes:discord

DD-WRT UI Themes Bug Reporting and Discussion thread

Router: ANus RT-AC68U E1 (recognized as C1)
kernel-panic69
DD-WRT Guru


Joined: 08 May 2018
Posts: 14125
Location: Texas, USA

PostPosted: Wed Aug 24, 2022 17:17    Post subject: Reply with quote
The pathname issue seems to no longer exist in both Win10 and newer WSL:

https://www.reddit.com/r/bashonubuntuonwindows/comments/lavqhi/is_anyone_else_using_wsl_to_circumvent_windowss/

I've dabbled in using WSL to test compiling of other things, but not DD-WRT more recently, but I would advise to keep everything Linux, if possible. Less chance of error until WSL has been fully bug-proofed.

_________________
"Life is but a fleeting moment, a vapor that vanishes quickly; All is vanity"
Contribute To DD-WRT
Pogo - A minimal level of ability is expected and needed...
DD-WRT Releases 2023 (PolitePol)
DD-WRT Releases 2023 (RSS Everything)

----------------------
Linux User #377467 counter.li.org / linuxcounter.net
mwchang
DD-WRT Guru


Joined: 26 Mar 2013
Posts: 1855
Location: Hung Hom, Hong Kong

PostPosted: Thu Aug 25, 2022 10:38    Post subject: Reply with quote
kernel-panic69 wrote:
The pathname issue seems to no longer exist in both Win10 and newer WSL:

https://www.reddit.com/r/bashonubuntuonwindows/comments/lavqhi/is_anyone_else_using_wsl_to_circumvent_windowss/

I've dabbled in using WSL to test compiling of other things, but not DD-WRT more recently, but I would advise to keep everything Linux, if possible. Less chance of error until WSL has been fully bug-proofed.


Filename too long in Git for Windows - Stack Overflow
https://stackoverflow.com/questions/22575662/filename-too-long-in-git-for-windows


_________________
Router: Asus RT-N18U (rev. A1)

Drink, Blink, Stretch! Live long and prosper! May the Force and farces be with you!

Facebook: https://www.facebook.com/changmanwai
Website: https://sites.google.com/site/changmw
SETI@Home profile: http://setiathome.berkeley.edu/view_profile.php?userid=211832
GitHub: https://github.com/changmw/changmw
the-joker
DD-WRT Developer/Maintainer


Joined: 31 Jul 2021
Posts: 2146
Location: All over YOUR webs

PostPosted: Thu Aug 25, 2022 10:53    Post subject: Reply with quote
Its not just filenames length, its path length and filenames themselves, in Linux you can have filenames with colons and whatever, DD-WRT source has these -- whatever anyway go find out for yourself when using plain Windows and go bang head on the brick wall.
_________________
Saving your retinas from the burn!🔥
DD-WRT Inspired themes for routers
DD-WRT Inspired themes for the phpBB Forum
DD-WRT Inspired themes for the SVN Trac & FTP site
Join in for a chat @ #style_it_themes_public:matrix.org or #style_it_themes:discord

DD-WRT UI Themes Bug Reporting and Discussion thread

Router: ANus RT-AC68U E1 (recognized as C1)
mwchang
DD-WRT Guru


Joined: 26 Mar 2013
Posts: 1855
Location: Hung Hom, Hong Kong

PostPosted: Thu Aug 25, 2022 12:21    Post subject: Reply with quote
the-joker wrote:
There is a lazy way using the GitHub mirror https://github.com/mirror/dd-wrt/archive/refs/heads/master.zip but that will not be up-to-date soon as changes are made and you wont be able to keep it updated unless you download every so often.

Its not just filenames length, its path length and filenames themselves, in Linux you can have filenames with colons and whatever, DD-WRT source has these -- whatever anyway go find out for yourself when using plain Windows and go bang head on the brick wall.

OK, 7-zip can test master.zip, but decompressing it led to errors. Interesting...

I haven't done the registry hack yet. Smile

_________________
Router: Asus RT-N18U (rev. A1)

Drink, Blink, Stretch! Live long and prosper! May the Force and farces be with you!

Facebook: https://www.facebook.com/changmanwai
Website: https://sites.google.com/site/changmw
SETI@Home profile: http://setiathome.berkeley.edu/view_profile.php?userid=211832
GitHub: https://github.com/changmw/changmw
Goto page 1, 2, 3  Next Display posts from previous:    Page 1 of 3
Post new topic   Reply to topic    DD-WRT Forum Index -> General Questions All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum