Compile GL-X300B firmware

Hi all,

I’m looking for a way to compile the firmware for the GL-X300B (Collie) router.
I followed what’s described here: GitHub - gl-inet/imagebuilder: Warning!Please look at 'GL.iNET Imagebuilder Introduction' section.
I cloned the repository in Ubuntu, but querying the possible devices gives me these:
./gl_image -l
User-defined Profiles:

usb150
b1300
x750
ar750sm16
vixmini
ar750s-agh
ar750
x1200
n300
ar150
e750
s1300
mt300n-v2
ar300m
mv1000-emmc
xe300
ar750s
ap1300
mt300n
mifi
mt300a
ar300m16

The x300b doesn’t seem to be available, right? Any way to compile the firmware?

Thanks for reading my post.

Regards,
Gertjan

How did you go with this? I’d also like to roll my own build for the X300 but I can’t even seem to bring up Luci on it!

Now China is in holiday and cannot update anything.

Maybe you can compile using source code? GitHub - gl-inet/openwrt: This repository is fork from openwrt official repo, we will update the latest tag and release GL.iNet firmware based on it.

I haven’t been able to resolve the issue yet.

Have you been able to solve it ?
I just got my X300 but it seems a closed box…

There is XE300 now.

Thanks for your response.
In my original post, you can see the “xe300” was already in the list of available devices. My inquiry is regarding the “x300b”, which is another device.

+1

I also would love to compile my own for the X300B.

It is there already

Hi @alzhao,

Thanks for your reply. Good to hear that X300B is in.

I am following the openwrt repo to build the image. However, I do not see the “GL.iNet X300B” option in the “Target Profile” of branch openwrt-19.07.7.

Cheers,
Paul

I got compile error for

Target System (Atheros AR7xxx/AR9xxx)  --->
Subtarget (Generic)  --->
Target Profile (GL-AR750)  --->

With this error message by following the repo instruction and on my Ubuntu 18.04:

Collected errors:
 * check_data_file_clashes: Package dnsmasq-full wants to install file /home/pdeng/Workspace/openwrt/build_dir/target-mips_24kc_musl/root-ar71xx/etc/hotplug.d/ntp/25-dnsmasqsec
	But that file is already provided by package  * dnsmasq
 * check_data_file_clashes: Package dnsmasq-full wants to install file /home/pdeng/Workspace/openwrt/build_dir/target-mips_24kc_musl/root-ar71xx/etc/init.d/dnsmasq
	But that file is already provided by package  * dnsmasq
 * check_data_file_clashes: Package dnsmasq-full wants to install file /home/pdeng/Workspace/openwrt/build_dir/target-mips_24kc_musl/root-ar71xx/usr/lib/dnsmasq/dhcp-script.sh
	But that file is already provided by package  * dnsmasq
 * check_data_file_clashes: Package dnsmasq-full wants to install file /home/pdeng/Workspace/openwrt/build_dir/target-mips_24kc_musl/root-ar71xx/usr/sbin/dnsmasq
	But that file is already provided by package  * dnsmasq
 * check_data_file_clashes: Package dnsmasq-full wants to install file /home/pdeng/Workspace/openwrt/build_dir/target-mips_24kc_musl/root-ar71xx/usr/share/acl.d/dnsmasq_acl.json
	But that file is already provided by package  * dnsmasq
 * check_data_file_clashes: Package dnsmasq-full wants to install file /home/pdeng/Workspace/openwrt/build_dir/target-mips_24kc_musl/root-ar71xx/usr/share/dnsmasq/dhcpbogushostname.conf
	But that file is already provided by package  * dnsmasq
 * check_data_file_clashes: Package dnsmasq-full wants to install file /home/pdeng/Workspace/openwrt/build_dir/target-mips_24kc_musl/root-ar71xx/usr/share/dnsmasq/rfc6761.conf
	But that file is already provided by package  * dnsmasq
 * opkg_install_cmd: Cannot install package dnsmasq-full.
 * check_conflicts_for: The following packages conflict with wpad-openssl:
 * check_conflicts_for: 	wpad-basic * 
 * opkg_install_cmd: Cannot install package wpad-openssl.
package/Makefile:65: recipe for target 'package/install' failed
make[2]: *** [package/install] Error 255
make[2]: Leaving directory '/home/pdeng/Workspace/openwrt'
package/Makefile:108: recipe for target '/home/pdeng/Workspace/openwrt/staging_dir/target-mips_24kc_musl/stamp/.package_install' failed
make[1]: *** [/home/pdeng/Workspace/openwrt/staging_dir/target-mips_24kc_musl/stamp/.package_install] Error 2
make[1]: Leaving directory '/home/pdeng/Workspace/openwrt'
/home/pdeng/Workspace/openwrt/include/toplevel.mk:225: recipe for target 'world' failed
make: *** [world] Error 2

Cheers,
Paul

Are you using the source code from GitHub - gl-inet/openwrt: This repository is fork from openwrt official repo, we will update the latest tag and release GL.iNet firmware based on it.

I just tried and all the targets are there

Pls select ath79 and Nand
image

image

Thanks @alzhao.

I successfully compiled it, thanks for your help.

I am new to X300B, can you please tell me what is the difference of NOR and NOR/NAND?

Cheers,
Paul

Nor is 16MByte flash
Nand is 128MByte flash

You can compile two firmwares but it depends on your hardware at hand. If it comes with Nand flash you can use nand firmware. Otherwise you can only use Nor firmware.

I remember that the default is just 16MByte Nor.

Thanks.

Just for clarification.

I have the standard 16MB version, so I should use:

Target System (Atheros ATH79 (DTS))  --->

Subtarget (Generic devices with NAND flash)  --->

Target Profile (GL.iNet GL-X300B (NOR))  --->

And for 128MB version, I need to build:

Target System (Atheros ATH79 (DTS))  --->

Subtarget (Generic devices with NAND flash)  --->

Target Profile (GL.iNet GL-X300B (NOR/NAND))  --->

Is this right?

Cheers,
Paul

The target profiles selected look correct. I am also using nor with the 16MB version. I am able to use the 18.06.5 build with no issues, but on 19.07.7 sometimes the router will not start after reboot. I have not been able to determine the issue.

This should be right.

IS UART a problem because it is connected to RS485. If when boot it receive some input it may break the boot process.

Currently no devices connected to RS485 only LAN. I am now connected to UART to watch for the boot failure.

Can you give the output of the UART>?