Project import generated by Copybara.

GitOrigin-RevId: bc474743e4d9c4fcb7213bb31cb940e44857f631
diff --git a/Android.mk b/Android.mk
index 99f3437..2c3ec83 100644
--- a/Android.mk
+++ b/Android.mk
@@ -9,7 +9,6 @@
 	-pthread \
 	-fexceptions \
 	-DDEBUG=1 \
-	-DDEBUG_eliribble \
 	-DFORCE_PR_LOG \
 	-DHAVE_DLADDR=1 \
 	-DHAVE_FCNTL_FILE_LOCKING=1 \
diff --git a/BUILD.gn b/BUILD.gn
new file mode 100644
index 0000000..cbc8590
--- /dev/null
+++ b/BUILD.gn
@@ -0,0 +1,247 @@
+
+#eurekaroot = rebase_path("//../../")
+#boostroot = rebase_path("//../../external/boost")
+#target_product = getenv("TARGET_PRODUCT")
+
+import("//chromecast/internal/iot_services/iot_nldaemon/configs.gni")
+
+nl_source_set("nspr4") {
+  cflags_c = [
+    "-UHAVE_CVAR_BUILT_ON_SEM",
+    "-UNDEBUG",
+    "-fno-inline",
+    "-fvisibility=hidden",
+    #"-nostdinc++",
+    #"-pthread",
+    #"-fexceptions",
+    "-Wno-implicit-function-declaration",
+    "-Wno-int-conversion",
+    "-Wno-sign-compare",
+    "-Wno-shadow",
+    "-Wno-unused-result",
+    "-DDEBUG=1",
+    "-DDEBUG_eliribble",
+    "-DFORCE_PR_LOG",
+    "-DHAVE_DLADDR=1",
+    "-DHAVE_FCNTL_FILE_LOCKING=1",
+    "-DHAVE_LCHOWN=1",
+    "-DHAVE_SECURE_GETENV=1",
+    "-DHAVE_SETPRIORITY=1",
+    "-DHAVE_STRERROR=1",
+    "-DHAVE_SYSCALL=1",
+    "-DHAVE_VISIBILITY_HIDDEN_ATTRIBUTE=1",
+    "-DHAVE_VISIBILITY_PRAGMA=1",
+    "-DLINUX=1",
+    "-DPACKAGE_BUGREPORT=\"\"",
+    "-DPACKAGE_NAME=\"\"",
+    "-DPACKAGE_STRING=\"\"",
+    "-DPACKAGE_TARNAME=\"\"",
+    "-DPACKAGE_URL=\"\"",
+    "-DPACKAGE_VERSION=\"\"",
+    "-DXP_UNIX=1",
+    "-D_GNU_SOURCE=1",
+    "-D_NSPR_BUILD_",
+    "-D_PR_PTHREADS",
+    "-D_REENTRANT",
+    "-UANDRO",
+  ]
+
+  sources = [
+    #"pr/src/prvrsion.c",
+    "pr/src/io/prfdcach.c",
+    "pr/src/io/prmwait.c",
+    "pr/src/io/prmapopt.c",
+    "pr/src/io/priometh.c",
+    "pr/src/io/pripv6.c",
+    "pr/src/io/prlayer.c",
+    "pr/src/io/prlog.c",
+    "pr/src/io/prmmap.c",
+    "pr/src/io/prpolevt.c",
+    "pr/src/io/prprf.c",
+    "pr/src/io/prscanf.c",
+    "pr/src/io/prstdio.c",
+    "pr/src/threads/prcmon.c",
+    "pr/src/threads/prrwlock.c",
+    "pr/src/threads/prtpd.c",
+    "pr/src/linking/prlink.c",
+    "pr/src/malloc/prmalloc.c",
+    "pr/src/malloc/prmem.c",
+    "pr/src/md/prosdep.c",
+    "pr/src/memory/prshm.c",
+    "pr/src/memory/prshma.c",
+    "pr/src/memory/prseg.c",
+    "pr/src/misc/pralarm.c",
+    "pr/src/misc/pratom.c",
+    "pr/src/misc/prcountr.c",
+    "pr/src/misc/prdtoa.c",
+    "pr/src/misc/prenv.c",
+    "pr/src/misc/prerr.c",
+    "pr/src/misc/prerror.c",
+    "pr/src/misc/prerrortable.c",
+    "pr/src/misc/prinit.c",
+    "pr/src/misc/prinrval.c",
+    "pr/src/misc/pripc.c",
+    "pr/src/misc/prlog2.c",
+    "pr/src/misc/prlong.c",
+    "pr/src/misc/prnetdb.c",
+    "pr/src/misc/praton.c",
+    "pr/src/misc/prolock.c",
+    "pr/src/misc/prrng.c",
+    "pr/src/misc/prsystem.c",
+    "pr/src/misc/prthinfo.c",
+    "pr/src/misc/prtpool.c",
+    "pr/src/misc/prtrace.c",
+    "pr/src/misc/prtime.c",
+    "pr/src/pthreads/ptsynch.c",
+    "pr/src/pthreads/ptio.c",
+    "pr/src/pthreads/ptthread.c",
+    "pr/src/pthreads/ptmisc.c",
+    "pr/src/md/unix/unix.c",
+    "pr/src/md/unix/unix_errors.c",
+    "pr/src/md/unix/uxproces.c",
+    "pr/src/md/unix/uxrng.c",
+    "pr/src/md/unix/uxshm.c",
+    "pr/src/md/unix/uxwrap.c",
+    "pr/src/md/unix/linux.c",
+  ]
+  
+  include_dirs = [
+    "$eurekaroot/external/nspr",
+    "$eurekaroot/external/nspr/dist/include/nspr",
+    "$eurekaroot/external/nspr/pr/include",
+    "$eurekaroot/external/nspr/pr/include/private",
+    "$eurekaroot/frameworks/native/include",
+    "$eurekaroot/hardware/libhardware/include",
+    "$eurekaroot/system/core/base/include",
+    "$eurekaroot/system/core/include",
+  ]
+}
+
+nl_source_set("plc4") {
+  cflags_c = [
+    "-UHAVE_CVAR_BUILT_ON_SEM",
+    "-UNDEBUG",
+    "-fno-inline",
+    "-fvisibility=hidden",
+    "-nostdinc++",
+    "-pthread",
+    "-fexceptions",
+    "-Wno-implicit-function-declaration",
+    "-Wno-int-conversion",
+    "-Wno-sign-compare",
+    "-Wno-shadow",
+    "-Wno-unused-result",
+    "-DDEBUG=1",
+    "-DDEBUG_eliribble",
+    "-DFORCE_PR_LOG",
+    "-DHAVE_DLADDR=1",
+    "-DHAVE_FCNTL_FILE_LOCKING=1",
+    "-DHAVE_LCHOWN=1",
+    "-DHAVE_SECURE_GETENV=1",
+    "-DHAVE_SETPRIORITY=1",
+    "-DHAVE_STRERROR=1",
+    "-DHAVE_SYSCALL=1",
+    "-DHAVE_VISIBILITY_HIDDEN_ATTRIBUTE=1",
+    "-DHAVE_VISIBILITY_PRAGMA=1",
+    "-DLINUX=1",
+    "-DPACKAGE_BUGREPORT=\"\"",
+    "-DPACKAGE_NAME=\"\"",
+    "-DPACKAGE_STRING=\"\"",
+    "-DPACKAGE_TARNAME=\"\"",
+    "-DPACKAGE_URL=\"\"",
+    "-DPACKAGE_VERSION=\"\"",
+    "-DXP_UNIX=1",
+    "-D_GNU_SOURCE=1",
+    "-D_NSPR_BUILD_",
+    "-D_PR_PTHREADS",
+    "-D_REENTRANT",
+    "-UANDRO",
+  ]
+
+  sources = [
+    "lib/libc/src/plvrsion.c",
+    "lib/libc/src/strlen.c",
+    "lib/libc/src/strcpy.c",
+    "lib/libc/src/strdup.c",
+    "lib/libc/src/strcase.c",
+    "lib/libc/src/strcat.c",
+    "lib/libc/src/strcmp.c",
+    "lib/libc/src/strchr.c",
+    "lib/libc/src/strpbrk.c",
+    "lib/libc/src/strstr.c",
+    "lib/libc/src/strtok.c",
+    "lib/libc/src/base64.c",
+    "lib/libc/src/plerror.c",
+    "lib/libc/src/plgetopt.c",
+  ]
+
+  include_dirs = [
+    "$eurekaroot/external/nspr",
+    "$eurekaroot/external/nspr/dist/include/nspr",
+    "$eurekaroot/external/nspr/pr/include",
+    "$eurekaroot/external/nspr/pr/include/private",
+    "$eurekaroot/frameworks/native/include",
+    "$eurekaroot/hardware/libhardware/include",
+    "$eurekaroot/system/core/base/include",
+    "$eurekaroot/system/core/include",
+  ]
+}
+
+nl_source_set("plds4") {
+  cflags_c = [
+    "-UHAVE_CVAR_BUILT_ON_SEM",
+    "-UNDEBUG",
+    "-fno-inline",
+    "-fvisibility=hidden",
+    "-nostdinc++",
+    "-pthread",
+    "-fexceptions",
+    "-Wno-implicit-function-declaration",
+    "-Wno-int-conversion",
+    "-Wno-sign-compare",
+    "-Wno-shadow",
+    "-Wno-unused-result",
+    "-DDEBUG=1",
+    "-DDEBUG_eliribble",
+    "-DFORCE_PR_LOG",
+    "-DHAVE_DLADDR=1",
+    "-DHAVE_FCNTL_FILE_LOCKING=1",
+    "-DHAVE_LCHOWN=1",
+    "-DHAVE_SECURE_GETENV=1",
+    "-DHAVE_SETPRIORITY=1",
+    "-DHAVE_STRERROR=1",
+    "-DHAVE_SYSCALL=1",
+    "-DHAVE_VISIBILITY_HIDDEN_ATTRIBUTE=1",
+    "-DHAVE_VISIBILITY_PRAGMA=1",
+    "-DLINUX=1",
+    "-DPACKAGE_BUGREPORT=\"\"",
+    "-DPACKAGE_NAME=\"\"",
+    "-DPACKAGE_STRING=\"\"",
+    "-DPACKAGE_TARNAME=\"\"",
+    "-DPACKAGE_URL=\"\"",
+    "-DPACKAGE_VERSION=\"\"",
+    "-DXP_UNIX=1",
+    "-D_GNU_SOURCE=1",
+    "-D_NSPR_BUILD_",
+    "-D_PR_PTHREADS",
+    "-D_REENTRANT",
+    "-UANDRO",
+  ]
+
+  sources = [
+    "lib/ds/plarena.c",
+    "lib/ds/plhash.c",
+    #"lib/ds/plvrsion.c",
+  ]
+
+  include_dirs = [
+    "$eurekaroot/external/nspr",
+    "$eurekaroot/external/nspr/dist/include/nspr",
+    "$eurekaroot/external/nspr/pr/include",
+    "$eurekaroot/external/nspr/pr/include/private",
+    "$eurekaroot/frameworks/native/include",
+    "$eurekaroot/hardware/libhardware/include",
+    "$eurekaroot/system/core/base/include",
+    "$eurekaroot/system/core/include",
+  ]
+}
diff --git a/NOTICE b/NOTICE
new file mode 120000
index 0000000..7a694c9
--- /dev/null
+++ b/NOTICE
@@ -0,0 +1 @@
+LICENSE
\ No newline at end of file