diff --git a/libshims/Android.mk b/libshims/Android.mk index 9ad1b89..9de1db1 100644 --- a/libshims/Android.mk +++ b/libshims/Android.mk @@ -24,3 +24,12 @@ LOCAL_MODULE := libshims_get_process_name LOCAL_MODULE_TAGS := optional include $(BUILD_SHARED_LIBRARY) + +include $(CLEAR_VARS) + +LOCAL_SRC_FILES := rild_socket.c + +LOCAL_MODULE := libshims_rild_socket +LOCAL_MODULE_TAGS := optional + +include $(BUILD_SHARED_LIBRARY) diff --git a/libshims/rild_socket.c b/libshims/rild_socket.c new file mode 100644 index 0000000..28c6e44 --- /dev/null +++ b/libshims/rild_socket.c @@ -0,0 +1,19 @@ +/* + * Copyright (C) 2017 The LineageOS Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#define MAX_SOCKET_NAME_LENGTH 6 + +char rild[MAX_SOCKET_NAME_LENGTH] = "rild"; diff --git a/rootdir/etc/init.qcom.rc b/rootdir/etc/init.qcom.rc index 67104ee..9404e72 100644 --- a/rootdir/etc/init.qcom.rc +++ b/rootdir/etc/init.qcom.rc @@ -34,7 +34,7 @@ on early-init chmod 0755 /sys/kernel/debug on init - export LD_SHIM_LIBS /system/lib/libcamera_client.so|libcamera_parameters_shim.so:/system/vendor/lib64/libizat_core.so|libshims_get_process_name.so + export LD_SHIM_LIBS /system/lib/libcamera_client.so|libcamera_parameters_shim.so:/system/vendor/lib64/libizat_core.so|libshims_get_process_name.so:/system/lib64/libsec-ril.so|libshims_rild_socket.so # Support legacy paths symlink /sdcard /storage/sdcard0